5#include <CesiumGltf/Library.h>
6#include <CesiumGltf/NamedObject.h>
7#include <CesiumGltf/Spotlight.h>
21 static constexpr const char*
TypeName =
"Light";
43 inline static const std::string
point =
"point";
55 inline static const std::string
spot =
"spot";
61 std::vector<double>
color = {1, 1, 1};
73 std::optional<CesiumGltf::Spotlight>
spot;
97 accum += int64_t(
sizeof(
Light));
100 accum += int64_t(
sizeof(
double) * this->color.capacity());
Classes for working with glTF models.
Known values for Specifies the light type.
static const std::string point
Point lights emit light in all directions from their position in space; rotation and scale are ignore...
static const std::string spot
Spot lights emit light in a cone in the direction of the local -z axis. The angle and falloff of the ...
static const std::string directional
Directional lights act as though they are infinitely far away and emit light in the direction of the ...
A directional, point, or spot light.
std::optional< CesiumGltf::Spotlight > spot
spot
std::string type
Specifies the light type.
std::vector< double > color
Color of the light source.
double intensity
Intensity of the light source. point and spot lights use luminous intensity in candela (lm/sr) while ...
static constexpr const char * TypeName
The original name of this type.
std::optional< double > range
A distance cutoff at which the light's intensity may be considered to have reached zero.
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
The base class for objects in a glTF that have a name.
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
KHR_lights_punctual Light Spot Properties.