C4 Engine
C4 Engine API Documentation

class LightObject

Defined in:  C4LightObjects.h
The LightObject class encapsulates data pertaining to a light source.
Definition

class LightObject : public Object

Member Functions
LightObject::GetLightType Returns the specific type of a light.
LightObject::GetBaseLightType Returns the base type of a light.
LightObject::GetLightColor Returns the light color.
LightObject::SetLightColor Sets the light color.
LightObject::GetLightFlags Returns the light flags.
LightObject::SetLightFlags Sets the light flags.
Constructor

LightObject(LightType type, LightType base, const ColorRGB& color);

Parameters
type The type of the light source. See below for a list of possible types.
base The base type of the light source. This should be kLightInfinite or kLightPoint.
color The color of light emitted by the light source.
Description
The LightObject class is the base class for all types of light objects, and it stores data that is common to all of them. Each specific type of light has an associated object that is a subclass of the LightObject class.

A light object can have one of the following types.
kLightInfinite Infinite light with parallel rays and no attenuation.
kLightPoint Point light with omnidirectional rays and distance attenuation.
kLightCube Point light with a projected cube texture.
kLightSpot Spot light with a projected 2D texture.
Base Classes
Object A LightObject is an object that can be shared by multiple light nodes.
See Also

Light

Wiki Articles

Lights