Skip to content

Latest commit

 

History

History
63 lines (41 loc) · 2.82 KB

File metadata and controls

63 lines (41 loc) · 2.82 KB

Asset Classification

← Home


How Classification Works

Every AssetNode is assigned an AssetType during the Loading build report phase by BuildReportAdapter's private ClassifyType() method. Classification is by Unity runtime type name only — there is no file-extension fallback. If the runtime type is null, or its name doesn't match a known type, or it's some other unmatched type, the asset is classified as Other.

ScriptableObject is the one exception that isn't a flat name match: ClassifyType() walks the type's base-class chain looking for ScriptableObject, so any subclass — including types BuildLens has never heard of — is correctly classified, not dumped into Other.


Classification Table

AssetType Matched Unity Type Names
Texture Texture2D, RenderTexture, Cubemap, Sprite
Mesh Mesh
Audio AudioClip
Script MonoScript, AssemblyDefinitionAsset
Shader Shader, ComputeShader
AnimationClip AnimationClip, AnimatorController, AnimatorOverrideController
Font Font (exact name match only — see TextMeshPro note below)
ScriptableObject Any subclass of ScriptableObject, checked after the above
Video VideoClip
Other Everything else, including a null type

This list is intentionally short. If you're seeing assets you'd expect to be more specifically classified land in Other, that's almost certainly why — there's no secondary classification pass to catch them.


Shader Variants

Unity packs shader variants as separate BuildReport entries. Each variant is an individual AssetNode with Type = Shader. The treemap shows every variant as a separate rectangle. The total size contribution of a shader in the filter is the sum of all its variant entries.

Shader variant keyword analysis is not currently available.


TextMeshPro Assets

TMP_FontAsset does not match the Font type name check — it's matched on the exact string "Font", and TMP_FontAsset doesn't match that. Since TMP_FontAsset is itself a ScriptableObject subclass, it falls through to the ScriptableObject classification instead. If you're tracking font atlas size, look for it under ScriptableObject, not Font.


The Other Category

Other has its own chip in the filter bar, the same as every other type — there is no special-cased exemption. Unchecking it hides Other assets from the treemap and asset list exactly like any other category, though they still count toward the summary bar's totals and participate fully in the dependency graph.


Related