Castor3D  ..
Classes | Public Member Functions | Protected Member Functions | Friends | List of all members
Castor3D::LightCategory Class Referenceabstract

Holds light components. More...

+ Inheritance diagram for Castor3D::LightCategory:

Classes

class  BinaryParser
 LightCategory loader. More...
 
class  TextLoader
 LightCategory loader. More...
 

Public Member Functions

C3D_API LightCategory (eLIGHT_TYPE p_lightType)
 The constructor, used by clone function. More...
 
virtual C3D_API ~LightCategory ()
 Destructor. More...
 
virtual C3D_API void Bind (Castor::PxBufferBase &p_texture, uint32_t p_index) const =0
 Puts the light into the given texture. More...
 
void SetColour (Castor::Point3f const &p_colour)
 Sets the light's colour. More...
 
void SetIntensity (Castor::Point3f const &p_intensity)
 Sets the light's intensity values. More...
 
void SetAmbientIntensity (float p_intensity)
 Sets the light's diffuse intensity. More...
 
void SetDiffuseIntensity (float p_intensity)
 Sets the light's diffuse intensity. More...
 
void SetSpecularIntensity (float p_intensity)
 Sets the light's specular intensity. More...
 
eLIGHT_TYPE GetLightType () const
 Retrieves the light type. More...
 
float GetAmbientIntensity () const
 Retrieves the ambient colour. More...
 
float GetDiffuseIntensity () const
 Retrieves the diffuse colour. More...
 
float GetSpecularIntensity () const
 Retrieves the specular colour. More...
 
Castor::Point3f const & GetIntensity () const
 
Castor::Point3f & GetIntensity ()
 
Castor::Point3f const & GetColour () const
 
Castor::Point3f & GetColour ()
 
LightGetLight () const
 Retrieves the parent light. More...
 
void SetLight (Light *val)
 Sets the parent light. More...
 

Protected Member Functions

Castor::Point4f const & GetPositionType () const
 Retrieves the light position and type. More...
 
virtual void SetPositionType (Castor::Point4f const &p_position)
 Sets the light's type and position. More...
 
virtual void SetPositionType (Castor::Point4d const &p_position)
 Sets the light's type and position. More...
 
void DoBindComponent (Castor::Point3f const &p_component, int p_index, int &p_offset, Castor::PxBufferBase &p_data) const
 
void DoBindComponent (Castor::Point4f const &p_component, int p_index, int &p_offset, Castor::PxBufferBase &p_data) const
 
void DoBindComponent (Castor::Coords4f const &p_component, int p_index, int &p_offset, Castor::PxBufferBase &p_data) const
 

Friends

class Light
 

Detailed Description

Holds light components.

Author
Sylvain DOREMUS
Date
14/02/2010
Remarks
Derived into DirectionalLight, PointLight and SpotLight

Constructor & Destructor Documentation

◆ LightCategory()

C3D_API Castor3D::LightCategory::LightCategory ( eLIGHT_TYPE  p_lightType)

The constructor, used by clone function.

Parameters
[in]p_lightTypeThe light category type

◆ ~LightCategory()

virtual C3D_API Castor3D::LightCategory::~LightCategory ( )
virtual

Destructor.

Member Function Documentation

◆ Bind()

virtual C3D_API void Castor3D::LightCategory::Bind ( Castor::PxBufferBase &  p_texture,
uint32_t  p_index 
) const
pure virtual

Puts the light into the given texture.

Parameters
[out]p_textureThe texture that receives the light's data.
[in]p_indexThe light index.

Implemented in Castor3D::DirectionalLight, Castor3D::SpotLight, and Castor3D::PointLight.

◆ DoBindComponent() [1/3]

void Castor3D::LightCategory::DoBindComponent ( Castor::Point3f const &  p_component,
int  p_index,
int &  p_offset,
Castor::PxBufferBase &  p_data 
) const
protected

◆ DoBindComponent() [2/3]

void Castor3D::LightCategory::DoBindComponent ( Castor::Point4f const &  p_component,
int  p_index,
int &  p_offset,
Castor::PxBufferBase &  p_data 
) const
protected

◆ DoBindComponent() [3/3]

void Castor3D::LightCategory::DoBindComponent ( Castor::Coords4f const &  p_component,
int  p_index,
int &  p_offset,
Castor::PxBufferBase &  p_data 
) const
protected

◆ GetAmbientIntensity()

float Castor3D::LightCategory::GetAmbientIntensity ( ) const
inline

Retrieves the ambient colour.

Returns
The value

◆ GetColour() [1/2]

Castor::Point3f const& Castor3D::LightCategory::GetColour ( ) const
inline
Returns
The colour.

◆ GetColour() [2/2]

Castor::Point3f& Castor3D::LightCategory::GetColour ( )
inline
Returns
The colour.

◆ GetDiffuseIntensity()

float Castor3D::LightCategory::GetDiffuseIntensity ( ) const
inline

Retrieves the diffuse colour.

Returns
The value

◆ GetIntensity() [1/2]

Castor::Point3f const& Castor3D::LightCategory::GetIntensity ( ) const
inline
Returns
The intensity values

◆ GetIntensity() [2/2]

Castor::Point3f& Castor3D::LightCategory::GetIntensity ( )
inline
Returns
The intensity values

◆ GetLight()

Light* Castor3D::LightCategory::GetLight ( ) const
inline

Retrieves the parent light.

Returns
The value

◆ GetLightType()

eLIGHT_TYPE Castor3D::LightCategory::GetLightType ( ) const
inline

Retrieves the light type.

Returns
The value

◆ GetPositionType()

Castor::Point4f const& Castor3D::LightCategory::GetPositionType ( ) const
inlineprotected

Retrieves the light position and type.

Returns
The value

◆ GetSpecularIntensity()

float Castor3D::LightCategory::GetSpecularIntensity ( ) const
inline

Retrieves the specular colour.

Returns
The value

◆ SetAmbientIntensity()

void Castor3D::LightCategory::SetAmbientIntensity ( float  p_intensity)
inline

Sets the light's diffuse intensity.

Parameters
[in]p_intensityThe new value

◆ SetColour()

void Castor3D::LightCategory::SetColour ( Castor::Point3f const &  p_colour)
inline

Sets the light's colour.

Parameters
[in]p_colourThe new value.

◆ SetDiffuseIntensity()

void Castor3D::LightCategory::SetDiffuseIntensity ( float  p_intensity)
inline

Sets the light's diffuse intensity.

Parameters
[in]p_intensityThe new value

◆ SetIntensity()

void Castor3D::LightCategory::SetIntensity ( Castor::Point3f const &  p_intensity)
inline

Sets the light's intensity values.

Parameters
[in]p_intensityThe new values.

◆ SetLight()

void Castor3D::LightCategory::SetLight ( Light val)
inline

Sets the parent light.

Returns
The value

◆ SetPositionType() [1/2]

virtual void Castor3D::LightCategory::SetPositionType ( Castor::Point4f const &  p_position)
inlineprotectedvirtual

Sets the light's type and position.

Parameters
[in]p_positionThe new value

◆ SetPositionType() [2/2]

virtual void Castor3D::LightCategory::SetPositionType ( Castor::Point4d const &  p_position)
inlineprotectedvirtual

Sets the light's type and position.

Parameters
[in]p_positionThe new value

◆ SetSpecularIntensity()

void Castor3D::LightCategory::SetSpecularIntensity ( float  p_intensity)
inline

Sets the light's specular intensity.

Parameters
[in]p_intensityThe new value

Friends And Related Function Documentation

◆ Light

friend class Light
friend

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