1#include "LightComponent.h"
15 TypeDatabase::createType<LightType>().setEnumerators(enums);
18 {
"None", LightingLayers::None },
19 {
"Default", LightingLayers::Default },
20 {
"All", LightingLayers::All },
23 TypeDatabase::createType<LightingLayers>().setEnumerators(layerEnums);
26 {
"Default", ShadowUpdate::Default },
27 {
"Dynamic", ShadowUpdate::Dynamic },
28 {
"Partial", ShadowUpdate::Partial },
29 {
"Static", ShadowUpdate::Static },
30 {
"StaticPartial", ShadowUpdate::StaticPartial },
31 {
"None", ShadowUpdate::None },
34 TypeDatabase::createType<ShadowUpdate>().setEnumerators(shadowUpdateEnums);
37 {
"None", SoftShadows::None },
38 {
"Low", SoftShadows::Low },
39 {
"High", SoftShadows::High },
40 {
"Default", SoftShadows::Default },
43 TypeDatabase::createType<SoftShadows>().setEnumerators(softShadowsEnums);
65 TypeDatabase::createType<LightComponent>().setBase<Component>().setFields(fields);
LightType lightType
The type of light.
float shadowBias
Constant term shadow map rasterization bias.
bool castShadows
If this light should cast shadows.
bool enabled
If the light is enabled.
float shadowBiasClamp
Shadow map bias rasterization clamp.
static void registerType()
Register the type in the type system.
float intensity
Intensity of the light source.
float shadowNearPlane
Shadow near plane. If set to 0 near plane is 1/1000th of the radius.
float shadowSampleBias
Constant term shadow map sampling bias.
std::vector< WeakEntityPtr > cameras
Cameras from which the shadow maps will be used, defaults to main camera.
WeakEntityPtr lodReference
Camera entity of which its z-axis define the shadowmap cascade split axis, defaults to main camera.
float shadowSlopedBias
Linear term of shadow map rasterization bias.
float shadowIntensityOffset
Shadow intensity offset.
bool tightShadowBounds
If the shadows should have tight bounds.
glm::vec4 lightColor
Color contribution of the light.
bool dynamicCascadeCount
Dynamically determine how many cascades should be drawn.
LightingLayers lightingLayer
The lighting layer the light belongs to.
float range
Falloff range.
Field definition describing a single data member of a data structure.
static FieldWrapper< Field, FieldType > create(const Name &name, FieldType ClassType::*field)
Creates a new field instance, returning a wrapper for type safe continuation style setup.
@ Point
Point light source.
@ Directional
Directional light.
Contains reflection support.