Skip to content

Visuals and mesh instances

AnvilData modelApplies toRRSWS

A Visual names a graphic object and its instance data. The common path is Visual → LODSelectorInstance → MeshInstanceData; direct MeshInstanceData also occurs. Five instance slots align to five selector descriptors in all 2,839 sampled selector instances. Observed

Visual / StaticDecalComponent bodyvarRR96% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x01u8ManagedObject byteUnknown0 on all
0x11u8ActiveObserved
0x21u8IsAnOptimizedComponentObserved
0x31u8IsPartiallyOptimizedObservedComponent.IsPartiallyOptimized: 0 on nearly all
0x410refobjectObservedwhat it shows: a LODSelector on most, a Mesh on some; or none (03)
0xE1u8instance tagObserved00: an instance object follows; 03: none, the tail follows at 15
0xF8u64instance idObserved
0x174u32instance typeObservedLODSelectorInstance 0x01437462, MeshInstanceData 0x536E963B, LightInstance 0x554C614C (311 bytes, tail included), SplashFXInstanceData 0xB8B08A89
0x1Bvarbytesinstance bodyObservedby its type (the LODSelectorInstance and MeshInstanceData boxes)
var125bytesVisual tailObservedthe Visual tail box (none after a LightInstance)
LODSelectorInstance (after its header)varRR100% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x04u32instance count kObserved
0x464·kmatrix4·kinstance matricesObservedcolumn-major; none: placed once by its owner
4+64k40bytesboundsObservedBoundingVolume
44+64k10bytesInstanceShaderConstants pointer, LODSelector linkObservedthe 10 bytes are GraphicObjectInstanceData.InstanceShaderConstants (a pointer, 03 = null) and LODSelectorInstance.LODSelector (a 9-byte link: tag 01 + the LODSelector's id): (03, 01) on 624,564 of 624,564
54+64kvarbytesfive level slotsObservedeach 03 (empty), or 00 + u64 + u32 type and the slot's body: MeshInstanceData 0x536E963B or ImpostorInstanceData 0xB3F06BC3
MeshInstanceData (after its header)89 + 64n + 41a + 40b bytesRR100% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x04u32instance count nObserved
0x464·nmatrix4·ninstance matricesObservedcolumn-major
4+64n40bytesboundsObservedBoundingVolume
44+64n1u8InstanceShaderConstants pointerObservedGraphicObjectInstanceData.InstanceShaderConstants (a pointer): 03 = null
45+64n1u8IsFakeObservedMeshInstanceData.IsFake (bool): 1 on 2,036 of 2,195
46+64n1u8IsNearFakeObservedMeshInstanceData.IsNearFake (bool): 1 on 0 of 2,195
47+64n4u32FakeMeshIndexObservedMeshInstanceData.FakeMeshIndex (u32): non-zero on 2,034 of 2,195 (e.g. 434 with IsFake)
51+64n1u8CompiledMeshInstance pointer tagObserved00 (present); the pointer's class id is the next u32
52+64n8u64CompiledMeshInstance: object idObserved0
60+64n4u32 = 0x4368101BCompiledMeshInstance typeObserved
64+64n1u8VertexFormatObservedCompiledMeshInstance.VertexFormat (registry byte): 11 2,036, 0 103, 2 46
65+64n4u32Streams countObservedCompiledMeshInstance.Streams (array of CompiledMeshInstanceStream): count 0 2,195
69+64n4u32PlatformVersionObservedCompiledMeshInstance.PlatformVersion: 31 2,195
73+64n8u64MeshHashObservedCompiledMeshInstance.MeshHash (u64): non-zero on 2,195 of 2,195
81+64n4u32material-info count aObserved
85+64n41·abytesmaterial infosObservedthe Material info box
85+64n+41a4u32instance bounds count bObserved
89+64n+41a40·bbytesinstance boundsObservedBoundingVolume per instance
Material info (41 bytes, ×a)41 bytesRR100% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x01u8 = 00tagObserved
0x18u64idObserved
0x94u32 = 0x995BFBF5typeObserved
0xD1u8 = 02tagObserved
0xE8u64ownerObserved
0x161u8 = 00tagObserved
0x178u64source MaterialObserved
0x1F2bytes = 01 01tagObserved
0x218u64replacement MaterialObserved
ImpostorInstanceData (after its header)54 + 64n bytesRR100% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x04u32instance count nObserved
0x464·nmatrix4·ninstance matricesObserved
4+64n40bytesboundsObservedBoundingVolume
44+64n10bytesimpostorObservedkept as stored: 03 00 + an Impostor's ClassID

Material-info entries identify a source Material ClassID and replacement Material ClassID, rather than an ordinal mesh range. Replacement modes 01 01 and 01 04 occur. Observed

The ten bytes after LODSelectorInstance bounds are a null InstanceShaderConstants pointer (03) and nine-byte selector link (01 + id) on 624,564 checked instances. They are not a ten-byte resource reference. Observed

The standard Visual tail is 125 bytes when its optional pointer is null. Its last 32 bytes are VisualShaderConstants data, interpreted by DataLayout; they are not universally a tint color. Material-layout values occur on user-content editor props, while the default view usually ends in four f32 ones. Observed

Visual tail (125 bytes)125 bytesRR81% known

Little-endian. Offsets are relative to this structure.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x01u8CanBeOccluderObservedVisual bool 1 of the 4 stored bools (registry order): see the pattern below
0x11u8HasUnshareContextObservedVisual bool 2
0x21u8OptimizedPackedLODObservedVisual bool 3
0x31u8CopyInstanceDataOnDuplicateObservedVisual bool 4. The four bytes: 01000000 630,674, 00000000 12
0x44u32DisplayOrderObservedVisual.DisplayOrder (a u32 bit field): 0 630,684, 1 2
0x81u8pointer tagObserveda pointer field not in the class list (03 = null on all read)
0x98bytesunaccountedUnknownzero (0000000000000000 630,686)
0x118u64VisualShaderConstants: object idObserved0 on all
0x194u32 = 0xBFF5DF99VisualShaderConstants: class idObserved= 0xBFF5DF99
0x1D4u32DataLayoutObserved0 Default, 1 UI, 2 Skin; values 3 and 4 correspond to Gear and Material views.
0x218u64DefaultLayout: object idObserved0
0x294u32 = 0xD74FA591DefaultLayout: class idObserved= 0xD74FA591 (no stored fields)
0x2D8u64UILayout: object idObserved0
0x354u32 = 0x9FAF160FUILayout: class idObserved= 0x9FAF160F (no stored fields)
0x398u64SkinLayout: object idObserved0
0x414u32 = 0x605001B7SkinLayout: class idObserved= 0x605001B7 (no stored fields)
0x458u6462FA1E14 (GearLayout): object idUnknown0
0x4D4u32 = 0xF54C16B8GearLayout: class idObserved= 0xF54C16B8 (no stored fields)
0x518u642C2D56DE (MaterialLayout): object idUnknown0
0x594u32 = 0xF977AE02MaterialLayout: class idObserved= 0xF977AE02 (no stored fields)
0x5D16u32·4VisualShaderConstants data, first 16 bytesObservedView selected by DataLayout; exact material-view channel mapping unresolved.
0x6D16f32·4VisualShaderConstants data, last 16 bytesObservedFour f32 values; usually (1, 1, 1, 1) in DefaultLayout.
How do all shader-constant views affect rendering?

Registry names and sampled values identify the views, but the material view’s exact channel meanings and non-null optional-pointer variants remain incomplete. Unknown

only in SWS

A Visual component shows one object. In level 01 the shown object is a Mesh on 3,587 Visuals, a LODSelector on 200, a ParticleSystem on 122, an OmniLight on 110, a SpotLight on 79, a RealTreeMesh on 30, an object of class 0xC3120087 on 20 and a DynamicMesh on 7; a further 3,021 name objects of other cells or entries. Of 6,861 entities, 5,797 have at least one Visual. Observed · level 01

A Visual is [component base object][InstanceData pointer][44 unnamed bytes]. The instance data is one of the following. Observed

Instance data Layout Confidence
MeshInstanceData (0x536E963B) [Mesh pointer, external][PRT id][n x inline pointer to SubMeshInstanceData {SubMesh link, AO id}][inline pointer to CompiledMeshInstance] Observed
CompiledMeshInstance [Data byte array][u32 21][u32 32][u64 hash][u32 key] Observed
LightInstance [Light pointer, external][Flare: LightFlare] Observed
LODSelectorInstance as in Assassin’s Creed II Inferred

The Mesh pointer of a MeshInstanceData is always external and the SubMesh pointer is always a link. Observed

LODSelector body100 bytesSWS99% known

Little-endian. Exact on 221 of 221 selectors of level 01.

ProvenObservedSourcedInferredUnknownNot described
OffsetSizeTypeFieldConfidenceNotes
0x09bytesmanaged byte, id, classObserved
0x94u32CategoryObservedenum
0xD1u8GeneratedObserved
0xE85LODDescriptor[5]slotsObservedper slot, 17 bytes: 8 bytes before the object id (first slot's object id is at byte 22 of the body), u32 object id, f32 SwitchDistance, u8 flag
0x631u8trailing byteUnknown

Slot 0 is LOD 0: vertex counts fall with the slot index in 214 of the 214 selectors that reach two or more known meshes. An object id of 0 marks an unused slot. The switch distances are not monotonic across the slots. Observed · level 01