MasterTech.Matter.Editor
Product: Matter
Compiled public/protected signature count: 65.
This reference includes source-authored summaries when available, plus compiled signatures, overloads, parameters, and return types. Where source comments are absent, conservative descriptions are derived from member names, accessors, and signatures. C# aliases are used while namespace qualification is retained for unambiguous lookup.
MasterTech.Matter.Editor.MatterDataPrebuildValidator
Supported integration API. All declared source members have authored documentation.
public class MasterTech.Matter.Editor.MatterDataPrebuildValidator
Prevents malformed Matter substance data from entering a player build and exposes the same deterministic validation to CI.
Properties
| Member | Signature | Description |
|---|---|---|
callbackOrder |
int callbackOrder { get:public; } |
Early build callback order (-1000) so invalid substance data can stop a build before later processing. |
Constructors
MatterDataPrebuildValidator
Creates a new MatterDataPrebuildValidator instance.
Signature
public void .ctor()
Methods
OnPreprocessBuild
Validates substance data and distribution boundaries, failing the build when blocking errors remain.
Signature
public void OnPreprocessBuild(UnityEditor.Build.Reporting.BuildReport report)
Parameters
| Name | Type | Description |
|---|---|---|
report |
UnityEditor.Build.Reporting.BuildReport |
Unity build report supplied to the preprocessing callback. |
ValidateAllSubstanceDatabases
Collects simulation and render-data validation failures across discoverable databases.
Signature
public static System.Collections.Generic.List<string> ValidateAllSubstanceDatabases()
Returns
System.Collections.Generic.List<string>: A list of validation errors; empty when the checks pass.
ValidateFromMenu
Validates installed substance databases and reports results to the Unity Console.
Signature
public static void ValidateFromMenu()
MasterTech.Matter.Editor.MatterDependencyValidator
Supported integration API. All declared source members have authored documentation.
public static class MasterTech.Matter.Editor.MatterDependencyValidator
Editor checks for forbidden core dependencies and installed-package integration boundaries.
Methods
Validate
Collects core dependency violations without modifying assets.
Signature
public static System.Collections.Generic.List<string> Validate()
Returns
System.Collections.Generic.List<string>: A list of dependency errors; empty when the checks pass.
ValidateBatchMode
Batch-mode entry point that fails the Unity process on a boundary violation.
Signature
public static void ValidateBatchMode()
ValidateFromMenu
Runs dependency validation and reports results to the Unity Console.
Signature
public static void ValidateFromMenu()
MasterTech.Matter.Editor.MatterPackagePaths
Supported integration API. All declared source members have authored documentation.
public static class MasterTech.Matter.Editor.MatterPackagePaths
Resolves package and imported-sample locations without assuming whether Matter is installed below Assets, embedded below Packages, or imported from a UPM Samples directory.
Properties
| Member | Signature | Description |
|---|---|---|
BasicSampleRoot |
string BasicSampleRoot { get:public; } |
Located Basic Setup sample source root, with package source fallback. |
BasicSampleScenePath |
string BasicSampleScenePath { get:public; } |
Resolved path to the Basic Setup sample scene. |
BenchmarkSampleScenePath |
string BenchmarkSampleScenePath { get:public; } |
Resolved path to the Benchmark Suite sample scene. |
BenchmarksRoot |
string BenchmarksRoot { get:public; } |
Located Benchmark Suite sample source root; importing the sample is required for executable sample workflows. |
ComputeShaderRoot |
string ComputeShaderRoot { get:public; } |
Compute shader asset root within the URP integration. |
DocumentationRoot |
string DocumentationRoot { get:public; } |
Bundled customer documentation root, including the offline Html output. |
EditorRoot |
string EditorRoot { get:public; } |
Editor source root below the resolved Matter package. |
FeatureShowcaseRoot |
string FeatureShowcaseRoot { get:public; } |
Located Feature Showcase source root, with package source fallback. |
MatterCommonHlslPath |
string MatterCommonHlslPath { get:public; } |
Source path to the shared cell/command shader declarations. |
MatterLightingComputeShaderPath |
string MatterLightingComputeShaderPath { get:public; } |
Asset path to the grid lighting compute shader. |
MatterRendererSourcePath |
string MatterRendererSourcePath { get:public; } |
Source path to the renderer component, for editor tooling rather than runtime resource loading. |
MatterSimulationComputeShaderPath |
string MatterSimulationComputeShaderPath { get:public; } |
Asset path to the standard simulation compute shader. |
MatterSurfaceCpuFallbackShaderPath |
string MatterSurfaceCpuFallbackShaderPath { get:public; } |
Asset path to the compute-free palette presentation shader. |
MatterSurfaceShaderPath |
string MatterSurfaceShaderPath { get:public; } |
Asset path to the full URP surface shader. |
RenderingResourcesRoot |
string RenderingResourcesRoot { get:public; } |
Package rendering resources used by runtime shader lookup. |
RenderingRuntimeRoot |
string RenderingRuntimeRoot { get:public; } |
Runtime rendering component source root. |
RenderingTestsRoot |
string RenderingTestsRoot { get:public; } |
Editor rendering-test source root within the package. |
RenderingUrpRoot |
string RenderingUrpRoot { get:public; } |
URP integration root below the resolved Matter package. |
Root |
string Root { get:public; } |
Resolved installed core package root; callers should not assume an embedded Packages path. |
RuntimeRoot |
string RuntimeRoot { get:public; } |
Runtime source root below the resolved Matter package. |
ShaderRoot |
string ShaderRoot { get:public; } |
Matter shader asset root within the URP integration. |
TerrainMaterialFieldComputeShaderPath |
string TerrainMaterialFieldComputeShaderPath { get:public; } |
Asset path to the terrain reconstruction compute shader. |
TestsRoot |
string TestsRoot { get:public; } |
Installed package test source root for editor automation. |
Methods
BasicSample
Combines relative asset-path fragments below the resolved Basic Setup sample root.
Signature
public static string BasicSample(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
Benchmarks
Combines relative asset-path fragments below the resolved Benchmark Suite sample root.
Signature
public static string Benchmarks(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
Combine
Combines asset-path fragments and normalizes separators to forward slashes.
Signature
public static string Combine(string[] parts)
Parameters
| Name | Type | Description |
|---|---|---|
parts |
string[] |
Path segments to join; separators are normalized. |
Returns
string: A normalized slash-separated Unity asset path.
Documentation
Combines relative asset-path fragments below the resolved customer documentation root.
Signature
public static string Documentation(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
Editor
Combines relative asset-path fragments below the resolved editor source root.
Signature
public static string Editor(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
FeatureShowcase
Combines relative asset-path fragments below the resolved Feature Showcase sample root.
Signature
public static string FeatureShowcase(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
FindAsset
Finds a typed asset using Unity's AssetDatabase and the supplied search scope. This is an Editor-only search.
Signature
public static T FindAsset(string name, string filter, string searchRoot)
Parameters
| Name | Type | Description |
|---|---|---|
name |
string |
Asset name sought by the editor lookup. |
filter |
string |
AssetDatabase search filter, including a type filter when appropriate. |
searchRoot |
string |
Optional AssetDatabase search root; null uses the implementation's default scope. |
Returns
T: The matching loaded asset, or null when none is found.
RenderingUrp
Combines relative asset-path fragments below the resolved URP integration root.
Signature
public static string RenderingUrp(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
Runtime
Combines relative asset-path fragments below the resolved runtime source root.
Signature
public static string Runtime(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
Tests
Combines relative asset-path fragments below the resolved package test root.
Signature
public static string Tests(string[] relativeParts)
Parameters
| Name | Type | Description |
|---|---|---|
relativeParts |
string[] |
Relative path segments below the selected Matter root. |
Returns
string: The combined Unity asset path with normalized separators.
MasterTech.Matter.Editor.MatterWebBuildPipeline
Supported integration API. All declared source members have authored documentation.
public static class MasterTech.Matter.Editor.MatterWebBuildPipeline
Reproducible WebGPU-first build entry points for Matter samples. WebGL2 remains in the player as the compatibility fallback.
Properties
| Member | Signature | Description |
|---|---|---|
WebGpuFirstGraphicsApis |
UnityEngine.Rendering.GraphicsDeviceType[] WebGpuFirstGraphicsApis { get:public; } |
A new graphics API array ordering WebGPU before the WebGL2 compatibility fallback. |
Fields
| Member | Signature | Description |
|---|---|---|
FeatureShowcaseOutputPath |
public static string FeatureShowcaseOutputPath |
Default relative output folder used by the Showcase Web build helper. |
Methods
BuildFeatureShowcase
Builds the located Showcase scene with the Web pipeline; sample resources must be prepared first.
Signature
public static void BuildFeatureShowcase()
BuildWebPlayer
Builds a supplied scene as a Web player and applies the pipeline's loading, compression and hosting setup.
Signature
public static UnityEditor.Build.Reporting.BuildSummary BuildWebPlayer(string scenePath, string relativeOutputPath, string productName, bool compactSampleTextures)
Parameters
| Name | Type | Description |
|---|---|---|
scenePath |
string |
Imported scene asset path to include in the player. |
relativeOutputPath |
string |
Build output path relative to the Unity project. |
productName |
string |
Product name used to configure this player build. |
compactSampleTextures |
bool |
Limit the demo to its genuine 1K, 512 and 256 texture tiers. |
Returns
UnityEditor.Build.Reporting.BuildSummary: Unity's build summary; inspect its result and errors before distributing the output.
ConfigureAutomaticCacheInvalidation
Gives every generated player a unique cache key, emits a no-cache release manifest, and adds a small page bootstrap which reloads stale HTML and clears only this product's Unity Cache API storage. This avoids exposing a CDN API token in client code.
Signature
public static string ConfigureAutomaticCacheInvalidation(string webBuildOutputPath, string buildVersion)
Parameters
| Name | Type | Description |
|---|---|---|
webBuildOutputPath |
string |
Existing Web player output directory to configure. |
buildVersion |
string |
Unique version key for the Web build's cache invalidation manifest. |
Returns
string: The cache-version key written into the generated Web player manifest.
ConfigureBrowserPresentation
Converts Unity's fixed-size default page into an unbranded, viewport-aware 16:10 player. The render buffer starts at 1280x800, while CSS presentation grows up to 1440x900 and still fits smaller browser windows without clipping the footer. Its loading cover remains visible until the showcase reports a rendered frame.
Signature
public static string ConfigureBrowserPresentation(string webBuildOutputPath)
Parameters
| Name | Type | Description |
|---|---|---|
webBuildOutputPath |
string |
Existing Web player output directory to configure. |
Returns
string: The configured player HTML path.
ConfigureFastLoadingPlayer
Removes unused managed and native engine code from the browser player. Matter's public API is preserved by scene and package references; unrelated host-project assemblies no longer inflate WebAssembly startup and download size.
Signature
public static void ConfigureFastLoadingPlayer()
ConfigurePortableBrotliHosting
Configures Brotli output with Unity's loader-side decompressor. Correct Content-Encoding headers remain the faster path, but an omitted .htaccess file no longer makes the player unloadable.
Signature
public static void ConfigurePortableBrotliHosting()
ConfigureUnbrandedPlayer
Disables Unity's engine splash for Matter builds. Unity 6 permits this for Personal projects as well as paid license tiers.
Signature
public static void ConfigureUnbrandedPlayer()
ConfigureWebGpuFirst
Configures WebGPU-first APIs, loading and hosting options in the active project's PlayerSettings.
Signature
public static void ConfigureWebGpuFirst()
WriteApacheHostingConfiguration
Writes the Apache metadata required to serve Unity's pre-compressed Brotli files, including the .unityweb names used by Unity's loader fallback. RemoveLanguage is essential on hosts which otherwise interpret the .br suffix as the Breton language.
Signature
public static string WriteApacheHostingConfiguration(string webBuildOutputPath)
Parameters
| Name | Type | Description |
|---|---|---|
webBuildOutputPath |
string |
Existing Web player output directory to configure. |
Returns
string: The written Build/.htaccess configuration path.
MasterTech.Matter.Editor.SubstanceRenderLibraryBaker
Supported integration API. All declared source members have authored documentation.
public static class MasterTech.Matter.Editor.SubstanceRenderLibraryBaker
Editor-only validation and baking of substance presentation records and texture arrays.
Fields
| Member | Signature | Description |
|---|---|---|
DefaultResolution |
public static int DefaultResolution |
Fallback bake resolution of 512 pixels when the corresponding menu workflow uses its default. |
Methods
Bake
Validates and bakes a database's presentation at the requested resolution into the specified asset path.
Signature
public static MasterTech.Matter.Data.SubstanceRenderLibrary Bake(MasterTech.Matter.Data.SubstanceDatabase database, string libraryPath, int resolution)
Parameters
| Name | Type | Description |
|---|---|---|
database |
MasterTech.Matter.Data.SubstanceDatabase |
Authored substance database with stable ordering and valid presentation inputs. |
libraryPath |
string |
Unity asset path for the generated render library. |
resolution |
int |
Positive source-normalization or texture-array resolution in pixels. |
Returns
MasterTech.Matter.Data.SubstanceRenderLibrary: The created or updated render-library asset.
BakeDefault
Bakes the located default substance database through the editor menu workflow.
Signature
public static void BakeDefault()
BakeTextureArrayLibrary
Bakes one independently loadable binary texture tier. A catalog can provide any combination from 256 through 8K; tiered render metadata and the shared runtime cache keep only selected assets resident.
Signature
public static MasterTech.Matter.Data.SubstanceTextureArrayLibrary BakeTextureArrayLibrary(string assetPath, int resolution, System.Collections.Generic.IReadOnlyList<MasterTech.Matter.Data.SubstanceTextureMaps> baseMaps, System.Collections.Generic.IReadOnlyList<MasterTech.Matter.Data.SubstanceTextureMaps> detailMaps)
Parameters
| Name | Type | Description |
|---|---|---|
assetPath |
string |
Unity asset path at which generated data is created or updated. |
resolution |
int |
Positive source-normalization or texture-array resolution in pixels. |
baseMaps |
System.Collections.Generic.IReadOnlyList<MasterTech.Matter.Data.SubstanceTextureMaps> |
Ordered base texture maps aligned with the texture-set records. |
detailMaps |
System.Collections.Generic.IReadOnlyList<MasterTech.Matter.Data.SubstanceTextureMaps> |
Ordered detail maps aligned with the base texture-set records. |
Returns
MasterTech.Matter.Data.SubstanceTextureArrayLibrary: The created or updated texture-array library asset.
BakeTieredMetadata
Bakes small per-database GPU metadata which references a shared set of Resources texture tiers instead of embedding duplicate arrays. The reference resolution is the 2K tier; optional 4K/8K tiers use the same slice catalog and resource prefix.
Signature
public static MasterTech.Matter.Data.SubstanceRenderLibrary BakeTieredMetadata(MasterTech.Matter.Data.SubstanceDatabase database, string libraryPath, int referenceResolution, string resourcePathPrefix, System.Collections.Generic.IReadOnlyDictionary<string,uint> baseSlices, System.Collections.Generic.IReadOnlyDictionary<string,uint> detailSlices)
Parameters
| Name | Type | Description |
|---|---|---|
database |
MasterTech.Matter.Data.SubstanceDatabase |
Authored substance database with stable ordering and valid presentation inputs. |
libraryPath |
string |
Unity asset path for the generated render library. |
referenceResolution |
int |
Resolution used to normalize metadata for the source texture tier. |
resourcePathPrefix |
string |
Project Resources prefix used to load generated platform texture tiers. |
baseSlices |
System.Collections.Generic.IReadOnlyDictionary<string,uint> |
Base texture-set slice indices used by the baked metadata. |
detailSlices |
System.Collections.Generic.IReadOnlyDictionary<string,uint> |
Detail texture-set slice indices aligned with base slices. |
Returns
MasterTech.Matter.Data.SubstanceRenderLibrary: The created or updated lightweight render-library metadata asset.
EnsureGraphicsBakeSupported
Throws when the active graphics configuration cannot perform the required texture-array bake.
Signature
public static void EnsureGraphicsBakeSupported()
ResolvePackedTextureFormat
Overload 1
Selects the packed color/surface/normal array format for a build target and optional Web texture subtarget.
Signature
public static UnityEngine.TextureFormat ResolvePackedTextureFormat(UnityEditor.BuildTarget target, UnityEditor.WebGLTextureSubtarget webSubtarget)
Parameters
| Name | Type | Description |
|---|---|---|
target |
UnityEditor.BuildTarget |
Unity build target for which texture compression is being chosen. |
webSubtarget |
UnityEditor.WebGLTextureSubtarget |
Selected Web texture compression profile. |
Returns
UnityEngine.TextureFormat: The platform-appropriate packed texture format.
Overload 2
Selects the packed color/surface/normal array format for a build target and optional Web texture subtarget.
Signature
public static UnityEngine.TextureFormat ResolvePackedTextureFormat(UnityEditor.BuildTarget target)
Parameters
| Name | Type | Description |
|---|---|---|
target |
UnityEditor.BuildTarget |
Unity build target for which texture compression is being chosen. |
Returns
UnityEngine.TextureFormat: The platform-appropriate packed texture format.