cesium-native 0.44.2
Loading...
Searching...
No Matches
NamedObject.h
1#pragma once
2
3#include <CesiumGltf/Library.h>
4#include <CesiumUtility/ExtensibleObject.h>
5
6#include <string>
7
8namespace CesiumGltf {
14struct CESIUMGLTF_API NamedObject : public CesiumUtility::ExtensibleObject {
21 std::string name;
22
28 int64_t getSizeBytes() const {
29 int64_t accum = 0;
30 accum += sizeof(NamedObject);
31 accum +=
32 ExtensibleObject::getSizeBytes() - int64_t(sizeof(ExtensibleObject));
33 accum += this->name.capacity() * sizeof(char);
34 return accum;
35 }
36};
37} // namespace CesiumGltf
Classes for working with glTF models.
The base class for objects in a glTF that have a name.
Definition NamedObject.h:14
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition NamedObject.h:28
std::string name
The user-defined name of this object.
Definition NamedObject.h:21
The base class for objects that have extensions and extras.