VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtLightScreenSpaceData Class Reference

Screen space light data, set up per frame and re-used multiple times while adding lights to light buckets.

Public Member Functions

 DtLightScreenSpaceData ()
 
void calculate (const DtLight &, const DtLightScreenSpacePerViewData &perView, int viewMatrix)
 
bool intersect (const DtScreenRect &rect) const
 
uint32 area () const
 
const DtScreenRectscreenRect () const
 

Protected Member Functions

bool insideEllipse (float xDiff, float yDiff) const
 
bool insideSpot (const Vector2_32 &relPos) const
 

Protected Attributes

DtScreenRect myScreenRect
 
Vector2_32 myPositionUnclipped
 
Vector2_32 myRadiusSquared
 
Vector3_32 mySpotCenterProj
 
float mySpotAngleMin
 
bool mySpotEllipseProjection
 
uint32 myArea
 
const DtLightmyLight
 

Constructor & Destructor Documentation

makVrv::DtLightScreenSpaceData::DtLightScreenSpaceData ( )
inline

Member Function Documentation

void makVrv::DtLightScreenSpaceData::calculate ( const DtLight ,
const DtLightScreenSpacePerViewData perView,
int  viewMatrix 
)

Calculate screen space light parameters. This is called from a subthread in DtTileSpaceLightGrid to calculate per-light screenspace parameters that can be re-used whilst adding lights to many light bins.

bool makVrv::DtLightScreenSpaceData::intersect ( const DtScreenRect rect) const

true if we intersect the given screen area

uint32 makVrv::DtLightScreenSpaceData::area ( ) const
inline

Return screenspace area.

const DtScreenRect& makVrv::DtLightScreenSpaceData::screenRect ( ) const
inline

Return screenspace bounding rectangle.

bool makVrv::DtLightScreenSpaceData::insideEllipse ( float  xDiff,
float  yDiff 
) const
protected

True if given point lies inside screen space projected point light ellipse.

bool makVrv::DtLightScreenSpaceData::insideSpot ( const Vector2_32 relPos) const
protected

True if given point lies inside screen space projected spot light cone.

Member Data Documentation

DtScreenRect makVrv::DtLightScreenSpaceData::myScreenRect
protected
Vector2_32 makVrv::DtLightScreenSpaceData::myPositionUnclipped
protected
Vector2_32 makVrv::DtLightScreenSpaceData::myRadiusSquared
protected
Vector3_32 makVrv::DtLightScreenSpaceData::mySpotCenterProj
protected
float makVrv::DtLightScreenSpaceData::mySpotAngleMin
protected
bool makVrv::DtLightScreenSpaceData::mySpotEllipseProjection
protected
uint32 makVrv::DtLightScreenSpaceData::myArea
protected
const DtLight* makVrv::DtLightScreenSpaceData::myLight
protected

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

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)