Class GLBReadData
Helper class that holds all intermediate data produced during GLB loading.
Namespace: Evergine.Runtimes.GLB
Assembly: Evergine.Runtimes.GLB.dll
Syntax
public class GLBReadData
Constructors
GLBReadData(Func<MaterialData, Task<Material>>)
Initializes a new instance of the GLBReadData class.
Declaration
public GLBReadData(Func<MaterialData, Task<Material>> materialAssigner)
Parameters
| Type | Name | Description |
|---|---|---|
| Func<MaterialData, Task<Material>> | materialAssigner | Optional user-supplied function that overrides the default material creation pipeline. |
Fields
AllNodes
All nodes in the glTF file, indexed by their glTF node ID.
Declaration
public NodeContent[] AllNodes
Field Value
| Type | Description |
|---|---|
| NodeContent[] |
Animations
All animation clips found in the file, keyed by animation name.
Declaration
public Dictionary<string, AnimationClip> Animations
Field Value
| Type | Description |
|---|---|
| Dictionary<string, AnimationClip> |
BinaryChunk
The raw binary chunk embedded in the GLB container, used to resolve internal buffer URIs.
Declaration
public byte[] BinaryChunk
Field Value
| Type | Description |
|---|---|
| byte[] |
BufferInfos
Pinned native pointers to each glTF buffer's data, used for zero-copy GPU buffer creation.
Declaration
public BufferInfo[] BufferInfos
Field Value
| Type | Description |
|---|---|
| BufferInfo[] |
DecodedBufferViews
Cache of Draco-decompressed mesh objects keyed by buffer view index, shared across primitives that reference the same compressed view.
Declaration
public Dictionary<int, Draco.Mesh> DecodedBufferViews
Field Value
| Type | Description |
|---|---|
| Dictionary<int, Draco.Mesh> |
DecodedData
Holds the last Draco decompression result so its native memory can be released when the Model is disposed.
Declaration
public Draco.Data? DecodedData
Field Value
| Type | Description |
|---|---|
| Draco.Data? |
GlbModel
The deserialized glTF JSON structure loaded from the GLB file.
Declaration
public Gltf GlbModel
Field Value
| Type | Description |
|---|---|
| Gltf |
Images
Cache of already-loaded textures keyed by glTF image index, to avoid redundant uploads.
Declaration
public Dictionary<int, Texture> Images
Field Value
| Type | Description |
|---|---|
| Dictionary<int, Texture> |
MaterialAssigner
Optional user-supplied function that overrides the default material creation pipeline.
Declaration
public Func<MaterialData, Task<Material>> MaterialAssigner
Field Value
| Type | Description |
|---|---|
| Func<MaterialData, Task<Material>> |
Materials
Maps glTF material index to its resolved name and Evergine Material instance.
Declaration
public Dictionary<int, (string name, Material material)> Materials
Field Value
| Type | Description |
|---|---|
| Dictionary<int, (string name, Material material)> |
MaterialsIds
Ordered list of material indices, used to compute the MaterialIndex for each mesh primitive.
Declaration
public List<int> MaterialsIds
Field Value
| Type | Description |
|---|---|
| List<int> |
MeshContainers
Flat list of all MeshContainers produced during scene traversal, used to populate the final Model.
Declaration
public List<MeshContainer> MeshContainers
Field Value
| Type | Description |
|---|---|
| List<MeshContainer> |
Meshes
Cache of already-built mesh primitive lists keyed by glTF mesh index, so shared meshes are created only once.
Declaration
public Dictionary<int, List<Mesh>> Meshes
Field Value
| Type | Description |
|---|---|
| Dictionary<int, List<Mesh>> |
RootIndices
Node indices of the top-level (root) nodes in the default scene.
Declaration
public List<int> RootIndices
Field Value
| Type | Description |
|---|---|
| List<int> |
Skins
All skin definitions (joint lists and inverse-bind matrices), indexed by glTF skin index.
Declaration
public SkinContent[] Skins
Field Value
| Type | Description |
|---|---|
| SkinContent[] |