cesium-native 0.43.0
Loading...
Searching...
No Matches
Animation.h
1// This file was generated by generate-classes.
2// DO NOT EDIT THIS FILE!
3#pragma once
4
5#include <CesiumGltf/AnimationChannel.h>
6#include <CesiumGltf/AnimationSampler.h>
7#include <CesiumGltf/Library.h>
8#include <CesiumGltf/NamedObject.h>
9
10#include <vector>
11
12namespace CesiumGltf {
16struct CESIUMGLTF_API Animation final : public CesiumGltf::NamedObject {
20 static constexpr const char* TypeName = "Animation";
21
27 std::vector<CesiumGltf::AnimationChannel> channels;
28
34 std::vector<CesiumGltf::AnimationSampler> samplers;
35
42 int64_t getSizeBytes() const {
43 int64_t accum = 0;
44 accum += int64_t(sizeof(Animation));
46 int64_t(sizeof(CesiumGltf::NamedObject));
47 accum += int64_t(
48 sizeof(CesiumGltf::AnimationChannel) * this->channels.capacity());
49 for (const CesiumGltf::AnimationChannel& value : this->channels) {
50 accum +=
51 value.getSizeBytes() - int64_t(sizeof(CesiumGltf::AnimationChannel));
52 }
53 accum += int64_t(
54 sizeof(CesiumGltf::AnimationSampler) * this->samplers.capacity());
55 for (const CesiumGltf::AnimationSampler& value : this->samplers) {
56 accum +=
57 value.getSizeBytes() - int64_t(sizeof(CesiumGltf::AnimationSampler));
58 }
59 return accum;
60 }
61};
62} // namespace CesiumGltf
Classes for working with glTF models.
An animation channel combines an animation sampler with a target property being animated.
An animation sampler combines timestamps with a sequence of output values and defines an interpolatio...
A keyframe animation.
Definition Animation.h:16
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition Animation.h:42
std::vector< CesiumGltf::AnimationSampler > samplers
An array of animation samplers. An animation sampler combines timestamps with a sequence of output va...
Definition Animation.h:34
std::vector< CesiumGltf::AnimationChannel > channels
An array of animation channels. An animation channel combines an animation sampler with a target prop...
Definition Animation.h:27
The base class for objects in a glTF that have a name.
Definition NamedObject.h:15
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
Definition NamedObject.h:29