The asset loading library currently supports GLTF 2.0 format.
GLTF loader uses tiny gltf library and is based on Vulkan-glTF-PBR project by Sascha Willems.
The following features are currently supported:
- ASCII, Binary, and Embedded GLTF specifications
- Draco Mesh Compression (automatically enabled when Draco is included into the project)
- PBR Materials (Metallic-Roughness and Specular-Glossiness workflows)
- Skinning
- Extensions:
The loading functionality is implemented in Diligent::GLTF::Model
class
that initializes all Diligent Engine objects required to render the model.
The following code snippet shows a basic usage of the loader:
GLTF::ModelCreateInfo ModelCI;
ModelCI.FileName = "MyAsset.gltf";
m_Model = std::make_unique<GLTF::Model>(m_pDevice, m_pImmediateContext, ModelCI);
The loader is very flexible and provides multiple ways to customize the loading process. Among others, the following parameters can be specified:
- Texture attribute configuration
- Vertex layout
- Node, Mesh, Primitive, and Material loading callbacks
- GPU resource cache
The loader does have any rendering capabilities. Please see Diligent GLTF PBR Renderer.