cesium-native 0.43.0
|
The root object for a glTF asset. More...
#include <CesiumGltf/ModelSpec.h>
Public Member Functions | |
int64_t | getSizeBytes () const |
Calculates the size in bytes of this object, including the contents of all collections, pointers, and strings. This will NOT include the size of any extensions attached to the object. Calling this method may be slow as it requires traversing the object's entire structure. | |
Public Member Functions inherited from CesiumUtility::ExtensibleObject | |
template<typename T > | |
bool | hasExtension () const noexcept |
Checks if an extension exists given its static type. | |
template<typename T > | |
const T * | getExtension () const noexcept |
Gets an extension given its static type. | |
template<typename T > | |
T * | getExtension () noexcept |
Gets an extension given its static type. | |
const JsonValue * | getGenericExtension (const std::string &extensionName) const noexcept |
Gets a generic extension with the given name as a CesiumUtility::JsonValue . | |
JsonValue * | getGenericExtension (const std::string &extensionName) noexcept |
Gets a generic extension with the given name as a CesiumUtility::JsonValue . | |
template<typename T , typename... ConstructorArgumentTypes> | |
T & | addExtension (ConstructorArgumentTypes &&... constructorArguments) |
Adds a statically-typed extension to this object. | |
template<typename T > | |
void | removeExtension () |
Removes a statically-typed extension from this object. | |
int64_t | getSizeBytes () const |
Calculates the size in bytes of this ExtensibleObject, including all of its extras but NOT including its extensions. Calling this method may be slow as it requires traversing the entire object. | |
Public Attributes | |
std::vector< std::string > | extensionsUsed |
Names of glTF extensions used in this asset. | |
std::vector< std::string > | extensionsRequired |
Names of glTF extensions required to properly load this asset. | |
std::vector< CesiumGltf::Accessor > | accessors |
An array of accessors. | |
std::vector< CesiumGltf::Animation > | animations |
An array of keyframe animations. | |
CesiumGltf::Asset | asset |
Metadata about the glTF asset. | |
std::vector< CesiumGltf::Buffer > | buffers |
An array of buffers. | |
std::vector< CesiumGltf::BufferView > | bufferViews |
An array of bufferViews. | |
std::vector< CesiumGltf::Camera > | cameras |
An array of cameras. | |
std::vector< CesiumGltf::Image > | images |
An array of images. | |
std::vector< CesiumGltf::Material > | materials |
An array of materials. | |
std::vector< CesiumGltf::Mesh > | meshes |
An array of meshes. | |
std::vector< CesiumGltf::Node > | nodes |
An array of nodes. | |
std::vector< CesiumGltf::Sampler > | samplers |
An array of samplers. | |
int32_t | scene = -1 |
The index of the default scene. | |
std::vector< CesiumGltf::Scene > | scenes |
An array of scenes. | |
std::vector< CesiumGltf::Skin > | skins |
An array of skins. | |
std::vector< CesiumGltf::Texture > | textures |
An array of textures. | |
Public Attributes inherited from CesiumUtility::ExtensibleObject | |
std::unordered_map< std::string, std::any > | extensions |
The extensions attached to this object. | |
JsonValue::Object | extras |
Application-specific data. | |
JsonValue::Object | unknownProperties |
Unknown properties that exist on this object but do not have any representation in the statically-typed classes. | |
Static Public Attributes | |
static constexpr const char * | TypeName = "Model" |
The original name of this type. | |
Protected Member Functions | |
ModelSpec ()=default | |
This class is not meant to be instantiated directly. Use Model instead. | |
Friends | |
struct | Model |
The root object for a glTF asset.
Definition at line 30 of file ModelSpec.h.
|
inline |
Calculates the size in bytes of this object, including the contents of all collections, pointers, and strings. This will NOT include the size of any extensions attached to the object. Calling this method may be slow as it requires traversing the object's entire structure.
Definition at line 148 of file ModelSpec.h.
|
friend |
Definition at line 218 of file ModelSpec.h.
std::vector<CesiumGltf::Accessor> CesiumGltf::ModelSpec::accessors |
An array of accessors.
An accessor is a typed view into a bufferView.
Definition at line 51 of file ModelSpec.h.
std::vector<CesiumGltf::Animation> CesiumGltf::ModelSpec::animations |
An array of keyframe animations.
Definition at line 56 of file ModelSpec.h.
CesiumGltf::Asset CesiumGltf::ModelSpec::asset |
Metadata about the glTF asset.
Definition at line 61 of file ModelSpec.h.
std::vector<CesiumGltf::Buffer> CesiumGltf::ModelSpec::buffers |
An array of buffers.
A buffer points to binary geometry, animation, or skins.
Definition at line 68 of file ModelSpec.h.
std::vector<CesiumGltf::BufferView> CesiumGltf::ModelSpec::bufferViews |
An array of bufferViews.
A bufferView is a view into a buffer generally representing a subset of the buffer.
Definition at line 76 of file ModelSpec.h.
std::vector<CesiumGltf::Camera> CesiumGltf::ModelSpec::cameras |
An array of cameras.
A camera defines a projection matrix.
Definition at line 83 of file ModelSpec.h.
std::vector<std::string> CesiumGltf::ModelSpec::extensionsRequired |
Names of glTF extensions required to properly load this asset.
Definition at line 44 of file ModelSpec.h.
std::vector<std::string> CesiumGltf::ModelSpec::extensionsUsed |
Names of glTF extensions used in this asset.
Definition at line 39 of file ModelSpec.h.
std::vector<CesiumGltf::Image> CesiumGltf::ModelSpec::images |
An array of images.
An image defines data used to create a texture.
Definition at line 90 of file ModelSpec.h.
std::vector<CesiumGltf::Material> CesiumGltf::ModelSpec::materials |
An array of materials.
A material defines the appearance of a primitive.
Definition at line 97 of file ModelSpec.h.
std::vector<CesiumGltf::Mesh> CesiumGltf::ModelSpec::meshes |
An array of meshes.
A mesh is a set of primitives to be rendered.
Definition at line 104 of file ModelSpec.h.
std::vector<CesiumGltf::Node> CesiumGltf::ModelSpec::nodes |
An array of nodes.
Definition at line 109 of file ModelSpec.h.
std::vector<CesiumGltf::Sampler> CesiumGltf::ModelSpec::samplers |
An array of samplers.
A sampler contains properties for texture filtering and wrapping modes.
Definition at line 116 of file ModelSpec.h.
int32_t CesiumGltf::ModelSpec::scene = -1 |
The index of the default scene.
This property MUST NOT be defined, when scenes
is undefined.
Definition at line 123 of file ModelSpec.h.
std::vector<CesiumGltf::Scene> CesiumGltf::ModelSpec::scenes |
An array of scenes.
Definition at line 128 of file ModelSpec.h.
std::vector<CesiumGltf::Skin> CesiumGltf::ModelSpec::skins |
An array of skins.
A skin is defined by joints and matrices.
Definition at line 135 of file ModelSpec.h.
std::vector<CesiumGltf::Texture> CesiumGltf::ModelSpec::textures |
An array of textures.
Definition at line 140 of file ModelSpec.h.
|
staticconstexpr |
The original name of this type.
Definition at line 34 of file ModelSpec.h.