LightInfo

Engine/source/lighting/lightInfo.h

This is the base light information class that will be tracked by the engine.

More...

Public Types

enum
Type {
  Point = 0
  Spot = 1
  Vector = 2
  Ambient = 3
  Count = 4
}

Protected Attributes

The primary light color.

bool

Whether to render debugging visualizations for this light.

The priority of this light used for light and shadow scoring.

A temporary which holds the score used when prioritizing lights for rendering.

Public Functions

addExtended(LightInfoEx * lightInfoEx)

Adds the extended info to the light deleting the existing extended info if it has one.

Delete all registered LightInfoEx instances of the given type.

ExClass *

Helper function for getting the extended light info.

Returns the extended light info for the selected type.

setCastShadows(bool castShadows)
setDynamicRefreshFreq(S32 _dynamicRefreshFreq)
setPriority(F32 priority)
setRange(F32 range)
setScore(F32 score)
setStaticRefreshFreq(S32 _staticRefreshFreq)

Detailed Description

This is the base light information class that will be tracked by the engine.

Should basically contain a bounding volume and methods to interact with the rest of the system (for example, setting GFX fixed function lights).

Public Types

Type

Enumerator

Point = 0
Spot = 1
Vector = 2
Ambient = 3
Count = 4

Protected Attributes

ColorF mAmbient 
F32 mBrightness 
bool mCastShadows 
ColorF mColor 

The primary light color.

bool mDebugRender 

Whether to render debugging visualizations for this light.

S32 mDynamicRefreshFreq 
::Vector< LightInfoEx * > mExtended 
F32 mInnerConeAngle 
F32 mOuterConeAngle 
F32 mPriority 

The priority of this light used for light and shadow scoring.

Point3F mRange 
F32 mScore 

A temporary which holds the score used when prioritizing lights for rendering.

S32 mStaticRefreshFreq 
MatrixF mTransform 
Type mType 

Public Functions

LightInfo()

~LightInfo()

addExtended(LightInfoEx * lightInfoEx)

Adds the extended info to the light deleting the existing extended info if it has one.

deleteAllLightInfoEx()

deleteExtended(const LightInfoExType & type)

Delete all registered LightInfoEx instances of the given type.

enableDebugRendering(bool value)

getAmbient()

getBrightness()

getCastShadows()

getColor()

getDirection()

getDynamicRefreshFreq()

getExtended()

Helper function for getting the extended light info.

getExtended(const LightInfoExType & type)

Returns the extended light info for the selected type.

getInnerConeAngle()

getOuterConeAngle()

getPosition()

getPriority()

getRange()

getScore()

getStaticRefreshFreq()

getTransform()

getType()

getWorldToLightProj(MatrixF * outMatrix)

isDebugRenderingEnabled()

packExtended(BitStream * stream)

set(const LightInfo * light)

setAmbient(const ColorF & val)

setBrightness(F32 val)

setCastShadows(bool castShadows)

setColor(const ColorF & val)

setDirection(const VectorF & val)

setDynamicRefreshFreq(S32 _dynamicRefreshFreq)

setGFXLight(GFXLightInfo * light)

setInnerConeAngle(F32 val)

setOuterConeAngle(F32 val)

setPosition(const Point3F & pos)

setPriority(F32 priority)

setRange(const Point3F & range)

setRange(F32 range)

setScore(F32 score)

setStaticRefreshFreq(S32 _staticRefreshFreq)

setTransform(const MatrixF & xfm)

setType(Type val)

unpackExtended(BitStream * stream)