Panda3D
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties
Public Types | Public Member Functions | Static Public Member Functions
PolylightEffect Class Reference

A PolylightEffect can be used on a node to define a LightGroup for that node. More...

Inheritance diagram for PolylightEffect:
RenderEffect TypedWritableReferenceCount TypedWritable ReferenceCount TypedObject

List of all members.

Public Types

enum  ContribType { CTProximal = 0, CTAll = 1 }

Public Member Functions

RenderEffect const addLight (NodePath const newlight)
 Add a PolylightNode object to this effect and return a new effect.
ContribType getContrib ()
 Returns CT_all or CT_proximal.
Point3 getEffectCenter ()
 Return the value of the _effect_center.
float getWeight ()
 Get the weight value.
bool hasLight (NodePath const light)
 Returns true if the indicated light is listed in the PolylightEffect, false otherwise.
RenderEffect const removeLight (NodePath const newlight)
 Remove a light from this effect.
RenderEffect const setContrib (ContribType c)
 Set Contrib Type and return a new effect...
RenderEffect const setEffectCenter (Point3 const ec)
 Set weight and return a new effect...
RenderEffect const setWeight (float w)
 Set weight and return a new effect...

Static Public Member Functions

static TypeHandle getClassType ()
static RenderEffect const make ()
 Constructs a new PolylightEffect object.
static RenderEffect const make (float weight, ContribType contrib, Point3 const effect_center)
 Constructs a new PolylightEffect object.
static RenderEffect const make (float weight, ContribType contrib, Point3 const effect_center, vectorNodePath const lights)
 Constructs a new PolylightEffect object.

Detailed Description

A PolylightEffect can be used on a node to define a LightGroup for that node.

A LightGroup contains PolylightNodes which are essentially nodes that add color to the polygons of a model based on distance. PolylightNode is a cheap way to get lighting effects specially for night scenes


Member Enumeration Documentation

Enumerator:
CTProximal 
CTAll 

Member Function Documentation

RenderEffect const addLight ( NodePath const  newlight)

Add a PolylightNode object to this effect and return a new effect.

static TypeHandle getClassType ( ) [static]

Reimplemented from RenderEffect.

Returns CT_all or CT_proximal.

Return the value of the _effect_center.

float getWeight ( )

Get the weight value.

bool hasLight ( NodePath const  light)

Returns true if the indicated light is listed in the PolylightEffect, false otherwise.

static RenderEffect const make ( ) [static]

Constructs a new PolylightEffect object.

static RenderEffect const make ( float  weight,
ContribType  contrib,
Point3 const  effect_center 
) [static]

Constructs a new PolylightEffect object.

static RenderEffect const make ( float  weight,
ContribType  contrib,
Point3 const  effect_center,
vectorNodePath const  lights 
) [static]

Constructs a new PolylightEffect object.

RenderEffect const removeLight ( NodePath const  newlight)

Remove a light from this effect.

Return the new updated effect

Set Contrib Type and return a new effect...

the reason this couldnt be done through make was because that would return a new effect without the lightgroup which is static and cant be accessed Here, we just pass that to the make

RenderEffect const setEffectCenter ( Point3 const  ec)

Set weight and return a new effect...

the reason this couldnt be done through make was because that would return a new effect without the lightgroup which is static and cant be accessed Here, we just pass that to the make

RenderEffect const setWeight ( float  w)

Set weight and return a new effect...

the reason this couldnt be done through make was because that would return a new effect without the lightgroup which is static and cant be accessed Here, we just pass that to the make

 All Classes Namespaces Functions Variables Enumerations Enumerator Properties