cesium-native 0.66.0
Loading...
Searching...
No Matches
Asset.h
1// This file was generated by generate-classes.
2// DO NOT EDIT THIS FILE!
3#pragma once
4
5#include <CesiumGltf/Library.h>
6#include <CesiumUtility/ExtensibleObject.h>
7
8#include <cstdint>
9#include <optional>
10#include <string>
11
12namespace CesiumGltf {
16struct CESIUMGLTF_API Asset final : public CesiumUtility::ExtensibleObject {
20 static constexpr const char* TypeName = "Asset";
21
26 std::optional<std::string> copyright;
27
31 std::optional<std::string> generator;
32
38 int32_t thumbnail = -1;
39
44 std::string version;
45
51 std::optional<std::string> minVersion;
52
59 int64_t getSizeBytes() const {
60 int64_t accum = 0;
61 accum += int64_t(sizeof(Asset));
63 int64_t(sizeof(CesiumUtility::ExtensibleObject));
64 if (this->copyright) {
65 accum += int64_t(this->copyright->capacity() * sizeof(char));
66 }
67 if (this->generator) {
68 accum += int64_t(this->generator->capacity() * sizeof(char));
69 }
70 accum += int64_t(this->version.capacity() * sizeof(char));
71 if (this->minVersion) {
72 accum += int64_t(this->minVersion->capacity() * sizeof(char));
73 }
74 return accum;
75 }
76};
77} // namespace CesiumGltf
Classes for working with glTF models.
Metadata about the glTF asset.
Definition Asset.h:16
std::optional< std::string > copyright
A copyright message suitable for display to credit the content creator.
Definition Asset.h:26
std::optional< std::string > generator
Tool that generated this glTF model. Useful for debugging.
Definition Asset.h:31
std::optional< std::string > minVersion
The minimum glTF version in the form of <major>.<minor> that this asset targets. This property MUST N...
Definition Asset.h:51
int32_t thumbnail
The index of the image in the images array to use as a thumbnail for this asset. The image SHOULD be ...
Definition Asset.h:38
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition Asset.h:59
static constexpr const char * TypeName
The original name of this type.
Definition Asset.h:20
std::string version
The glTF version in the form of <major>.<minor> that this asset targets.
Definition Asset.h:44
The base class for objects that have extensions and extras.
int64_t getSizeBytes() const
Calculates the size in bytes of this ExtensibleObject, including all of its extras but NOT including ...