7#include "core/reflect.h"
10namespace Vkm::Engine {
37 LightType type = LightType::Directional;
38 glm::vec3 color = {1.0f, 1.0f, 1.0f};
39 float intensity = 1.0f;
51 bool castShadows =
true;
114float flickerWave(
const Light& light,
double seconds, uint32_t slot);
129VKM_ENUM_NAMES(::Vkm::Engine::LightType,
"Directional",
"Point",
"Spot",
"Rect",
"Disk")
131VKM_REFLECT_BEGIN(::Vkm::Engine::Light)
136 VKM_F(innerConeAngle)
137 VKM_F(outerConeAngle)
144 VKM_F(shadowNormalBias)
145 VKM_F(shadowDistance)
146 VKM_F(shadowPriority)
Central registry managing entities and an open set of component types.
Definition scene.h:29
Names one entity of one Scene, for as long as that slot holds it.
Definition entity.h:23
Component representing a light source in the scene.
Definition light.h:36
float areaWidth
Rect width along the local X axis.
Definition light.h:46
float radius
Attenuation cutoff (point/spot/area)
Definition light.h:41
float shadowDistance
Directional only: world distance the cascades cover.
Definition light.h:69
float areaHeight
Rect height along the local Y axis.
Definition light.h:47
float areaRadius
Disk radius.
Definition light.h:48
float flicker
How deep the light wavers, as a fire's does: 0 holds it steady, 1 dips it to dark.
Definition light.h:96
float sourceRadius
How large the light's source is, which is how soft its shadows are.
Definition light.h:87
float shadowNormalBias
How far the point moves off the surface before the compare, in shadow texels (0..4).
Definition light.h:68
float outerConeAngle
Spot: falloff edge, radians.
Definition light.h:44
bool twoSided
Area lights: emit from both faces.
Definition light.h:49
float innerConeAngle
Spot: full-brightness cone, radians.
Definition light.h:43
float shadowBias
How far the depth compare slides toward the light, in shadow texels (0..4).
Definition light.h:60
int shadowPriority
Which lights keep a shadow when more cast than the atlas holds; higher first.
Definition light.h:77