cesium-native 0.43.0
Loading...
Searching...
No Matches
Content.h
1// This file was generated by generate-classes.
2// DO NOT EDIT THIS FILE!
3#pragma once
4
5#include <Cesium3DTiles/BoundingVolume.h>
6#include <Cesium3DTiles/Library.h>
7#include <Cesium3DTiles/MetadataEntity.h>
8#include <CesiumUtility/ExtensibleObject.h>
9
10#include <cstdint>
11#include <optional>
12#include <string>
13
14namespace Cesium3DTiles {
18struct CESIUM3DTILES_API Content final
23 static constexpr const char* TypeName = "Content";
24
31 std::optional<Cesium3DTiles::BoundingVolume> boundingVolume;
32
37 std::string uri;
38
42 std::optional<Cesium3DTiles::MetadataEntity> metadata;
43
48 std::optional<int64_t> group;
49
56 int64_t getSizeBytes() const {
57 int64_t accum = 0;
58 accum += int64_t(sizeof(Content));
60 int64_t(sizeof(CesiumUtility::ExtensibleObject));
61 if (this->boundingVolume) {
62 accum += this->boundingVolume->getSizeBytes() -
63 int64_t(sizeof(Cesium3DTiles::BoundingVolume));
64 }
65 accum += int64_t(this->uri.capacity() * sizeof(char));
66 if (this->metadata) {
67 accum += this->metadata->getSizeBytes() -
68 int64_t(sizeof(Cesium3DTiles::MetadataEntity));
69 }
70 return accum;
71 }
72};
73} // namespace Cesium3DTiles
Classes for using 3D Tiles.
Definition Buffer.h:7
A bounding volume that encloses a tile or its content. At least one bounding volume property is requi...
Metadata about the tile's content and a link to the content.
Definition Content.h:19
std::optional< int64_t > group
The group this content belongs to. The value is an index into the array of groups that is defined for...
Definition Content.h:48
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition Content.h:56
std::string uri
A uri that points to tile content. When the uri is relative, it is relative to the referring tileset ...
Definition Content.h:37
std::optional< Cesium3DTiles::BoundingVolume > boundingVolume
An optional bounding volume that tightly encloses tile content. tile.boundingVolume provides spatial ...
Definition Content.h:31
std::optional< Cesium3DTiles::MetadataEntity > metadata
Metadata that is associated with this content.
Definition Content.h:42
An object containing a reference to a class from a metadata schema, and property values that conform ...
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 ...