Public Member Functions | |
| LightingContext () | |
| LightingContext (I3DExRaytracer *raytracer, const IllumSettings &illum, const RendEnv &rendEnv, const RTLevelInfo &level, const uint32 seed) | |
| void | Init (I3DExRaytracer *raytracer, const IllumSettings &illum, const RendEnv &rendEnv, const RTLevelInfo &level, const uint32 seed) |
| const TMCColorRGBA & | GetAmbientLight () const |
| void | CalcReflectDir (const TVector3 &rayDir, const TVector3 &normal) const |
Public Attributes | |
| FirstHitInfo * | fFirstHitInfo |
| TVector2 | fScreenCoordinates |
| LightingFlags | fLightingFlags |
| const IllumSettings * | fIllumSettings |
| lighting flags | |
| const RendEnv * | fRendEnv |
| I3DExRaytracer * | fRaytracer |
| const RTLevelInfo * | fLevel |
| const Ray3D * | fIncomingRay |
| RayHit3D * | fHit |
| boolean | fNormalFlipped |
| if the normal has been flipped | |
| boolean | fCalculateTransparency |
| TVector3 | fNormal |
| normal on current point after bump is applied (in global coord) | |
| TVector3 | fReflectDir |
| RendContext | fRendContext |
Info about the point being shaded and the lighting of the scene. Used for shaders that implement their own lighting.
| LightingContext::LightingContext | ( | ) | [inline] |
| LightingContext::LightingContext | ( | I3DExRaytracer * | raytracer, | |
| const IllumSettings & | illum, | |||
| const RendEnv & | rendEnv, | |||
| const RTLevelInfo & | level, | |||
| const uint32 | seed | |||
| ) | [inline] |
| void LightingContext::CalcReflectDir | ( | const TVector3 & | rayDir, | |
| const TVector3 & | normal | |||
| ) | const [inline] |
Computes the direction in which a ray reflects on a surface. The result is stored in fReflectDir
| rayDir | is the direction of the incomming ray | |
| normal | is the normal at the intersection point between ray and surface |
| const TMCColorRGBA& LightingContext::GetAmbientLight | ( | ) | const [inline] |
Returns the intensity of the ambient light in the scene
| void LightingContext::Init | ( | I3DExRaytracer * | raytracer, | |
| const IllumSettings & | illum, | |||
| const RendEnv & | rendEnv, | |||
| const RTLevelInfo & | level, | |||
| const uint32 | seed | |||
| ) | [inline] |
Inits the lighting context
If fCalculateTransparency is true, the lighting model must calculate the alpha channel and the straight transparency (by opposition to refracted transparency)
lighting flags
TVector3 LightingContext::fNormal [mutable] |
normal on current point after bump is applied (in global coord)
if the normal has been flipped
TVector3 LightingContext::fReflectDir [mutable] |
RendContext LightingContext::fRendContext [mutable] |
| const RendEnv* LightingContext::fRendEnv |
1.6.3