Diligent Engine
Loading...
Searching...
No Matches
Diligent::GLTF::Document Class Reference

Parsed GLTF document. More...

#include <GLTFDocument.hpp>

Public Member Functions

Uint32 GetTextureCount () const
 Returns the number of textures in the document.
Uint32 GetMaterialCount () const
 Returns the number of materials in the document.
bool GetTextureSourceInfo (Uint32 TextureIndex, TextureSourceInfo &Source) const

Detailed Description

Parsed GLTF document.

Member Function Documentation

◆ GetTextureSourceInfo()

bool Diligent::GLTF::Document::GetTextureSourceInfo ( Uint32 TextureIndex,
TextureSourceInfo & Source ) const

Resolves a GLTF texture to either an external URI or an embedded encoded-data span.

Embedded buffer-view spans are owned by the document buffers. Embedded data URI spans are owned by tinygltf::Image::image. In both cases the returned pointer remains valid only while the document is alive and unchanged.