3#include "pixelbullet/filesystem/virtual_path.h"
4#include "pixelbullet/filesystem/virtual_path_serialization.h"
5#include "pixelbullet/serialization/node.h"
16 float background_intensity = 1.0f;
17 float ambient_intensity = 0.15f;
18 float specular_intensity = 1.0f;
19 float exposure = 1.0f;
23 return enabled == other.enabled && environment_asset.LogicalPath() == other.environment_asset.LogicalPath() &&
24 background_intensity == other.background_intensity && ambient_intensity == other.ambient_intensity &&
25 specular_intensity == other.specular_intensity && exposure == other.exposure;
30 return !(*
this == other);
34inline constexpr std::array<std::string_view, 6> k_scene_environment_cubemap_faces = {
35 "Right",
"Left",
"Top",
"Bottom",
"Front",
"Back",
38inline Node& operator<<(Node& node,
const SceneEnvironmentSettings& settings)
40 node[
"enabled"] << settings.enabled;
41 node[
"environmentAsset"] << settings.environment_asset;
42 node[
"backgroundIntensity"] << settings.background_intensity;
43 node[
"ambientIntensity"] << settings.ambient_intensity;
44 node[
"specularIntensity"] << settings.specular_intensity;
45 node[
"exposure"] << settings.exposure;
51 if (node.HasProperty(
"enabled"))
53 node[
"enabled"] >> settings.enabled;
55 if (node.HasProperty(
"environmentAsset"))
57 node[
"environmentAsset"] >> settings.environment_asset;
59 if (node.HasProperty(
"backgroundIntensity"))
61 node[
"backgroundIntensity"] >> settings.background_intensity;
63 if (node.HasProperty(
"ambientIntensity"))
65 node[
"ambientIntensity"] >> settings.ambient_intensity;
67 if (node.HasProperty(
"specularIntensity"))
69 node[
"specularIntensity"] >> settings.specular_intensity;
71 if (node.HasProperty(
"exposure"))
73 node[
"exposure"] >> settings.exposure;
Represents a hierarchical node capable of storing various data types and supporting YAML serializatio...
Definition node.h:45
Definition virtual_path.h:10
Definition scene_environment_settings.h:13