Nameless Engine
Loading...
Searching...
No Matches
ne::SpotlightNode::SpotlightShaderData Struct Reference

Public Attributes

glm::mat4 viewProjectionMatrix = glm::identity<glm::mat4>()
 
glm::vec4 position = glm::vec4(0.0F, 0.0F, 0.0F, 1.0F)
 
glm::vec4 direction = glm::vec4(0.0F, 0.0F, 0.0F, 0.0F)
 
glm::vec4 color = glm::vec4(1.0F, 1.0F, 1.0F, 1.0F)
 
float intensity = 1.0F
 
float distance = 1.0F
 
float cosInnerConeAngle = 0.0F
 
float cosOuterConeAngle = 0.0F
 
float coneBottomRadius = 0.0F
 
unsigned int iShadowMapIndex = 0
 

Detailed Description

Data that will be directly copied into shaders.

Member Data Documentation

◆ color

glm::vec4 ne::SpotlightNode::SpotlightShaderData::color = glm::vec4(1.0F, 1.0F, 1.0F, 1.0F)

Light color. 4th component is not used.

◆ coneBottomRadius

float ne::SpotlightNode::SpotlightShaderData::coneBottomRadius = 0.0F

Radius of cone's bottom part.

◆ cosInnerConeAngle

float ne::SpotlightNode::SpotlightShaderData::cosInnerConeAngle = 0.0F

Cosine of the spotlight's inner cone angle (cutoff).

Remarks
Represents cosine of the cutoff angle on one side from the light direction (not both sides), i.e. this is a cosine of value [0-90] degrees.

◆ cosOuterConeAngle

float ne::SpotlightNode::SpotlightShaderData::cosOuterConeAngle = 0.0F

Cosine of the spotlight's outer cone angle (cutoff).

Remarks
Represents cosine of the cutoff angle on one side from the light direction (not both sides), i.e. this is a cosine of value [0-90] degrees.

◆ direction

glm::vec4 ne::SpotlightNode::SpotlightShaderData::direction = glm::vec4(0.0F, 0.0F, 0.0F, 0.0F)

Light forward unit vector (direction). 4th component is not used.

◆ distance

float ne::SpotlightNode::SpotlightShaderData::distance = 1.0F

Lit distance.

◆ intensity

float ne::SpotlightNode::SpotlightShaderData::intensity = 1.0F

Light intensity.

◆ iShadowMapIndex

unsigned int ne::SpotlightNode::SpotlightShaderData::iShadowMapIndex = 0

Index in the spot shadow map array where shadow map of this light source is stored.

◆ position

glm::vec4 ne::SpotlightNode::SpotlightShaderData::position = glm::vec4(0.0F, 0.0F, 0.0F, 1.0F)

Light position in world space. 4th component is not used.

◆ viewProjectionMatrix

glm::mat4 ne::SpotlightNode::SpotlightShaderData::viewProjectionMatrix = glm::identity<glm::mat4>()

Matrix that transforms data (such as positions) to clip (projection) space of the light source (used for shadow mapping).


The documentation for this struct was generated from the following file: