# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NL3D::CLightContribution Class Reference

light contribution on a model. More...

#include <light_contribution.h>

List of all members.

Public Methods

 CLightContribution ()
 Constructor. More...


Public Attributes

CPointLightPointLight [NL3D_MAX_LIGHT_CONTRIBUTION]
 This is the list of Light which influence us. The first NULL means end_of_list. More...

CPointLight::ItTransformList TransformIterator [NL3D_MAX_LIGHT_CONTRIBUTION]
 An iterator on the list of model in the pointLight which owns our transform. More...

uint8 Factor [NL3D_MAX_LIGHT_CONTRIBUTION]
 the factor of influence to apply to each point light. More...

uint8 AttFactor [NL3D_MAX_LIGHT_CONTRIBUTION]
 the Attenuation factor of influence to apply to each point light. Used if the model. More...

NLMISC::CRGBA LocalAmbient
 the Dynamic Local Ambient. If A==0 then full SunAmbient is taken. If A==255, take full LocalAmbient color. More...

bool FrozenStaticLightSetup
 Tells if there is some frozen static light setup. More...

uint8 NumFrozenStaticLight
 if FrozenStaticLightSetup, tells the number of point light setup which are static. More...

uint8 SunContribution
CPointLightFrozenAmbientLight
 if FrozenStaticLightSetup, this is the frozen AmbientLight in ig. More...


Detailed Description

light contribution on a model.

Owned by a CTransform computed by lighting manager. result CLight is computed at render.

if FrozenStaticLightSetup, then the SunContribution won't never be recomputed, and the first NumFrozenStaticLight PointLight are considered always valid and their setup won't be recomputed too. It's means also that CTransform::resetLighting() do not affect those NumFrozenStaticLight.

Typically, FrozenStaticLightSetup is setup for models and lights THAT ARE IN SAME IG, and are deleted together. This last point is important because the first NumFrozenStaticLight PointLight pointers are never updated, so delete a light which is in this setup will cause memory failure.

Author:
Lionel Berenguier , Nevrax France
Date:
2001

Definition at line 63 of file light_contribution.h.


Constructor & Destructor Documentation

NL3D::CLightContribution::CLightContribution  
 

Constructor.

Definition at line 34 of file light_contribution.cpp.

References FrozenAmbientLight, FrozenStaticLightSetup, PointLight, and SunContribution.


Member Data Documentation

uint8 NL3D::CLightContribution::AttFactor[NL3D_MAX_LIGHT_CONTRIBUTION]
 

the Attenuation factor of influence to apply to each point light. Used if the model.

Definition at line 73 of file light_contribution.h.

uint8 NL3D::CLightContribution::Factor[NL3D_MAX_LIGHT_CONTRIBUTION]
 

the factor of influence to apply to each point light.

Definition at line 71 of file light_contribution.h.

CPointLight* NL3D::CLightContribution::FrozenAmbientLight
 

if FrozenStaticLightSetup, this is the frozen AmbientLight in ig.

can't be stored as RGBA, because the ambient color may change. NULL means take full Sun ambient

Definition at line 91 of file light_contribution.h.

Referenced by CLightContribution.

bool NL3D::CLightContribution::FrozenStaticLightSetup
 

Tells if there is some frozen static light setup.

Definition at line 79 of file light_contribution.h.

Referenced by CLightContribution.

NLMISC::CRGBA NL3D::CLightContribution::LocalAmbient
 

the Dynamic Local Ambient. If A==0 then full SunAmbient is taken. If A==255, take full LocalAmbient color.

Definition at line 75 of file light_contribution.h.

uint8 NL3D::CLightContribution::NumFrozenStaticLight
 

if FrozenStaticLightSetup, tells the number of point light setup which are static.

NB: it is possible that FrozenStaticLightSetup==true, and NumFrozenStaticLight==0. it means that the model is not touched by any static pointLight.

Definition at line 84 of file light_contribution.h.

CPointLight* NL3D::CLightContribution::PointLight[NL3D_MAX_LIGHT_CONTRIBUTION]
 

This is the list of Light which influence us. The first NULL means end_of_list.

Definition at line 67 of file light_contribution.h.

Referenced by CLightContribution.

uint8 NL3D::CLightContribution::SunContribution
 

Definition at line 86 of file light_contribution.h.

Referenced by CLightContribution.

CPointLight::ItTransformList NL3D::CLightContribution::TransformIterator[NL3D_MAX_LIGHT_CONTRIBUTION]
 

An iterator on the list of model in the pointLight which owns our transform.

Definition at line 69 of file light_contribution.h.


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