Public Member Functions | |
LightComponent (Entity *parent, const SColorf &color=SColorf(1.0f, 1.0f, 1.0f), f32 radius=100.0f) | |
Constructor (default). | |
~LightComponent () | |
Deconstructor. | |
ILightSceneNode * | getLightSceneNode () |
Returns a direct pointer to the ILightSceneNode. | |
bool | getCastShadow () const |
Returns whether this light casts shadows. | |
E_LIGHT_TYPE | getLightType () const |
Gets the light type. | |
f32 | getRadius () const |
Gets the light's radius of influence. | |
void | setCastShadow (bool shadow=true) |
Sets whether this light casts shadows. | |
void | setLightType (E_LIGHT_TYPE type) |
Sets the light type. | |
void | setRadius (f32 radius) |
Sets the light's radius of influence. | |
Static Public Member Functions | |
static LightComponent * | refFactory (Entity *parent) |
Will be used to instanciate objects of this class. | |
static LightComponent * | refFactory (Entity *parent, const SColor &color, f32 radius) |
Will be used to instanciate objects of this class. |
Definition at line 26 of file LightComponent.h.
LightComponent::LightComponent | ( | Entity * | parent, | |
const SColorf & | color = SColorf(1.0f, 1.0f, 1.0f) , |
|||
f32 | radius = 100.0f | |||
) |
Constructor (default).
parent | The parent entity to which the component should be added. | |
color | Diffuse color of the light. | |
radius | Radius of the light. |
Definition at line 23 of file LightComponent.cpp.
LightComponent::~LightComponent | ( | ) |
bool LightComponent::getCastShadow | ( | ) | const |
ILightSceneNode * LightComponent::getLightSceneNode | ( | ) |
E_LIGHT_TYPE LightComponent::getLightType | ( | ) | const |
f32 LightComponent::getRadius | ( | ) | const |
LightComponent * LightComponent::refFactory | ( | Entity * | parent, | |
const SColor & | color, | |||
f32 | radius | |||
) | [static] |
Will be used to instanciate objects of this class.
Definition at line 53 of file LightComponent.cpp.
LightComponent * LightComponent::refFactory | ( | Entity * | parent | ) | [static] |
Will be used to instanciate objects of this class.
Reimplemented from SceneComponent.
Definition at line 47 of file LightComponent.cpp.
void LightComponent::setCastShadow | ( | bool | shadow = true |
) |
Sets whether this light casts shadows.
shadow | Value to enable or disable this option. |
Definition at line 83 of file LightComponent.cpp.
void LightComponent::setLightType | ( | E_LIGHT_TYPE | type | ) |
Sets the light type.
type | The light type (see: Irrlicht API documentation) |
Definition at line 89 of file LightComponent.cpp.
void LightComponent::setRadius | ( | f32 | radius | ) |
Sets the light's radius of influence.
radius | The new radius. |
Definition at line 95 of file LightComponent.cpp.