cesium-native 0.43.0
Loading...
Searching...
No Matches
FeatureId.h
1// This file was generated by generate-classes.
2// DO NOT EDIT THIS FILE!
3#pragma once
4
5#include <CesiumGltf/FeatureIdTexture.h>
6#include <CesiumGltf/Library.h>
7#include <CesiumUtility/ExtensibleObject.h>
8
9#include <cstdint>
10#include <optional>
11#include <string>
12
13namespace CesiumGltf {
17struct CESIUMGLTF_API FeatureId final : public CesiumUtility::ExtensibleObject {
21 static constexpr const char* TypeName = "FeatureId";
22
26 int64_t featureCount = int64_t();
27
32 std::optional<int64_t> nullFeatureId;
33
38 std::optional<std::string> label;
39
46 std::optional<int64_t> attribute;
47
51 std::optional<CesiumGltf::FeatureIdTexture> texture;
52
57 int32_t propertyTable = -1;
58
65 int64_t getSizeBytes() const {
66 int64_t accum = 0;
67 accum += int64_t(sizeof(FeatureId));
69 int64_t(sizeof(CesiumUtility::ExtensibleObject));
70 if (this->label) {
71 accum += int64_t(this->label->capacity() * sizeof(char));
72 }
73 if (this->texture) {
74 accum += this->texture->getSizeBytes() -
75 int64_t(sizeof(CesiumGltf::FeatureIdTexture));
76 }
77 return accum;
78 }
79};
80} // namespace CesiumGltf
Classes for working with glTF models.
A texture containing feature IDs.
Feature IDs stored in an attribute or texture.
Definition FeatureId.h:17
std::optional< std::string > label
A label assigned to this feature ID set. Labels must be alphanumeric identifiers matching the regular...
Definition FeatureId.h:38
std::optional< int64_t > attribute
An integer value used to construct a string in the format _FEATURE_ID_<set index> which is a referenc...
Definition FeatureId.h:46
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition FeatureId.h:65
std::optional< CesiumGltf::FeatureIdTexture > texture
A texture containing feature IDs.
Definition FeatureId.h:51
std::optional< int64_t > nullFeatureId
A value that indicates that no feature is associated with this vertex or texel.
Definition FeatureId.h:32
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 ...