This is the documentation for Enlighten.
class Enlighten MaterialGuids
class Enlighten::MaterialGuids
Storage of mappings between "old" u64 material IDs and "new" instance, mesh and material GUIDs.
This class is optionally included in ClusterAlbedoWorkspaceMaterialData and is used for setting material properties using GUIDs.
Classes
Name | Description |
|---|---|
Stored data for a geometry. | |
Stored data for an instance. | |
Stored data for a material-guid mapping. | |
Stored data for a mesh. |
Functions
Name | Description |
|---|---|
Convert the endian-ness of this MaterialGuids. | |
ConvertIdsAndIdxsToGuids(Geo::u16, Geo::u16, Geo::GeoGuid &, Geo::GeoGuid &) | Converts a given instance ID and mesh index to instance GUID and mesh GUID. |
Converts a given instance ID, mesh index and material ID to instance GUID, mesh GUID and material GUID. | |
Raw access to the geometries array. | |
Raw access to the geometries array. | |
Gets number of instances. If pointer is non-null will fill in the array with their guids. | |
Raw access to the instances array. | |
Raw access to the instances array. | |
Raw access to the material GUID mappings array. | |
Raw access to the material GUID mappings array. | |
GetMaterialGuids(const Geo::GeoGuid &, const Geo::GeoGuid &, Geo::GeoGuid *) | Gets number of materials in the given instance and mesh (or all if GeoGuid::Invalid). If pointer is non-null will fill in the array with their guids. |
Fills in array of material IDs and a 64-bit mask specifying which bits need to mask, given instance, mesh and material GUIDs any of which can be GeoGuid::Invalid for "all". | |
Raw access to the meshes array. | |
Raw access to the meshes array. | |
Gets number of meshes in the given instance (or all if GeoGuid::Invalid). If pointer is non-null will fill in the array with their guids. |
Variables
Name | Description |
|---|---|
Geo::u32 m_GeometriesOffset | Array of GeometryInfo (x m_NumGeometries) |
Geo::u32 m_InstancesOffset | Array of InstanceInfo (x m_NumInstances). Should be sorted by instance Guid to speed up lookups. |
Geo::u32 m_MaterialGuidMappingsOffset | Array of MaterialGuidMapping (x m_NumMaterialGuidMappings). This contains the material guid mappings for all the meshes concatenated together in one big array. Each sub-array (per-mesh) should be sorted by material Guid to speed up lookups. |
Geo::u32 m_MeshesOffset | Array of MeshInfo (x m_NumMeshes). This contains the MeshInfo for all the geometries concatenated together in one big array. Each sub-array (per geometry) should be sorted by mesh guid to speed up lookups. |
Geo::s32 m_NumGeometries | Number of geometries. |
Geo::s32 m_NumInstances | Number of instances. |
Geo::s32 m_NumMaterialGuidMappings | Total number of material Guid -> u32 material id mappings across all meshes. |
Geo::s32 m_NumMaterialInstances | Total uses of materials by all instances. |
Geo::s32 m_NumMeshes | Total number of meshes (summed across all Geometries) |
Geo::u32 m_ObjectSize | Size of this object (in bytes). |