CrystalSpace

Public API Reference

csLightProperties Struct Reference

Light properties, as needed by the attenuation and lighting functors. More...

#include <csgfx/vertexlight.h>

List of all members.

Public Member Functions

 csLightProperties (size_t lightNum, csLightShaderVarCache &svcache, const csShaderVarStack &stacks)
 Convenience constructor to fill the structure from a set of shader variables.
 csLightProperties ()

Public Attributes

csVector3 attenuationConsts
 Attenuation coefficients (for CLQ attenuation).
csLightAttenuationMode attenuationMode
 Light attenuation mode.
csColor color
 Light diffuse color.
csVector3 dirObject
 Light direction (object space).
csVector3 posObject
 Light position (object space).
float spotFalloffInner
 Spotlight inner falloff.
float spotFalloffOuter
 Spotlight outer falloff.
csLightType type
 Light type.


Detailed Description

Light properties, as needed by the attenuation and lighting functors.

Definition at line 41 of file vertexlight.h.


Constructor & Destructor Documentation

csLightProperties::csLightProperties size_t  lightNum,
csLightShaderVarCache svcache,
const csShaderVarStack stacks
[inline]
 

Convenience constructor to fill the structure from a set of shader variables.

Definition at line 69 of file vertexlight.h.

References CS_ATTN_NONE, CS_LIGHT_POINTLIGHT, csLightShaderVarCache::GetLightSVId(), csArray< T, ElementHandler, MemoryAllocator >::Length(), csLightShaderVarCache::lightAttenuation, csLightShaderVarCache::lightAttenuationMode, csLightShaderVarCache::lightDiffuse, csLightShaderVarCache::lightDirection, csLightShaderVarCache::lightInnerFalloff, csLightShaderVarCache::lightOuterFalloff, csLightShaderVarCache::lightPosition, and csLightShaderVarCache::lightType.


Member Data Documentation

csVector3 csLightProperties::attenuationConsts
 

Attenuation coefficients (for CLQ attenuation).

Definition at line 44 of file vertexlight.h.

Referenced by csLinearAttenuation::csLinearAttenuation().

csLightAttenuationMode csLightProperties::attenuationMode
 

Light attenuation mode.

Definition at line 61 of file vertexlight.h.

csColor csLightProperties::color
 

Light diffuse color.

Definition at line 53 of file vertexlight.h.

Referenced by csDirectionalLightProc< AttenuationProc >::csDirectionalLightProc(), csPointLightProc< AttenuationProc >::csPointLightProc(), and csSpotLightProc< AttenuationProc >::csSpotLightProc().

csVector3 csLightProperties::dirObject
 

Light direction (object space).

Remarks:
Should be a unit vector.

Definition at line 51 of file vertexlight.h.

Referenced by csDirectionalLightProc< AttenuationProc >::csDirectionalLightProc(), and csSpotLightProc< AttenuationProc >::csSpotLightProc().

csVector3 csLightProperties::posObject
 

Light position (object space).

Definition at line 46 of file vertexlight.h.

Referenced by csDirectionalLightProc< AttenuationProc >::csDirectionalLightProc(), csPointLightProc< AttenuationProc >::csPointLightProc(), and csSpotLightProc< AttenuationProc >::csSpotLightProc().

float csLightProperties::spotFalloffInner
 

Spotlight inner falloff.

Definition at line 55 of file vertexlight.h.

Referenced by csSpotLightProc< AttenuationProc >::csSpotLightProc().

float csLightProperties::spotFalloffOuter
 

Spotlight outer falloff.

Definition at line 57 of file vertexlight.h.

Referenced by csSpotLightProc< AttenuationProc >::csSpotLightProc().

csLightType csLightProperties::type
 

Light type.

Definition at line 59 of file vertexlight.h.


The documentation for this struct was generated from the following file:
Generated for Crystal Space by doxygen 1.4.6