AGX Dynamics 2.42.1.1
Loading...
Searching...
No Matches
agxOSG::LightSource Class Reference

#include <LightSource.h>

Public Member Functions

 LightSource (osg::LightSource *lightSource)
 
 ~LightSource ()
 
agx::Vec4f getAmbient () const
 Get the ambient component of the light.
 
float getConstantAttenuation () const
 Get the constant attenuation of the light.
 
agx::Vec4f getDiffuse () const
 Get the diffuse component of the light.
 
agx::Vec3 getDirection () const
 Get the direction of the light.
 
int getLightNum () const
 Get which OpenGL light this osg::Light operates on.
 
float getLinearAttenuation () const
 Get the linear attenuation of the light.
 
agx::Vec4 getPosition () const
 Get the position of the light.
 
float getQuadraticAttenuation () const
 Get the quadratic attenuation of the light.
 
agx::Vec4f getSpecular () const
 Get the specular component of the light.
 
float getSpotCutoff () const
 Get the spot cutoff of the light.
 
float getSpotExponent () const
 Get the spot exponent of the light.
 
void setAmbient (const agx::Vec4f &ambient)
 Set the ambient component of the light.
 
void setConstantAttenuation (float constant_attenuation)
 Set the constant attenuation of the light.
 
void setDiffuse (const agx::Vec4f &diffuse)
 Set the diffuse component of the light.
 
void setDirection (const agx::Vec3 &direction)
 Set the direction of the light.
 
void setLinearAttenuation (float linear_attenuation)
 Set the linear attenuation of the light.
 
void setPosition (const agx::Vec4 &position)
 Set the position of the light.
 
void setQuadraticAttenuation (float quadratic_attenuation)
 Set the quadratic attenuation of the light.
 
void setSpecular (const agx::Vec4f &specular)
 Set the specular component of the light.
 
void setSpotCutoff (float spot_cutoff)
 Set the spot cutoff of the light.
 
void setSpotExponent (float spot_exponent)
 Set the spot exponent of the light.
 

Protected Attributes

osg::ref_ptr< osg::Light > m_light
 

Detailed Description

Definition at line 32 of file LightSource.h.

Constructor & Destructor Documentation

◆ LightSource()

agxOSG::LightSource::LightSource ( osg::LightSource *  lightSource)
inline

Definition at line 36 of file LightSource.h.

◆ ~LightSource()

agxOSG::LightSource::~LightSource ( )
inline

Definition at line 105 of file LightSource.h.

Member Function Documentation

◆ getAmbient()

agx::Vec4f agxOSG::LightSource::getAmbient ( ) const
inline

Get the ambient component of the light.

Definition at line 49 of file LightSource.h.

References OSG_VEC4F_TO_AGX.

◆ getConstantAttenuation()

float agxOSG::LightSource::getConstantAttenuation ( ) const
inline

Get the constant attenuation of the light.

Definition at line 79 of file LightSource.h.

◆ getDiffuse()

agx::Vec4f agxOSG::LightSource::getDiffuse ( ) const
inline

Get the diffuse component of the light.

Definition at line 55 of file LightSource.h.

References OSG_VEC4F_TO_AGX.

◆ getDirection()

agx::Vec3 agxOSG::LightSource::getDirection ( ) const
inline

Get the direction of the light.

Definition at line 73 of file LightSource.h.

References OSG_VEC3_TO_AGX.

◆ getLightNum()

int agxOSG::LightSource::getLightNum ( ) const
inline

Get which OpenGL light this osg::Light operates on.

Definition at line 43 of file LightSource.h.

◆ getLinearAttenuation()

float agxOSG::LightSource::getLinearAttenuation ( ) const
inline

Get the linear attenuation of the light.

Definition at line 85 of file LightSource.h.

◆ getPosition()

agx::Vec4 agxOSG::LightSource::getPosition ( ) const
inline

Get the position of the light.

Definition at line 67 of file LightSource.h.

References OSG_VEC4_TO_AGX.

◆ getQuadraticAttenuation()

float agxOSG::LightSource::getQuadraticAttenuation ( ) const
inline

Get the quadratic attenuation of the light.

Definition at line 91 of file LightSource.h.

◆ getSpecular()

agx::Vec4f agxOSG::LightSource::getSpecular ( ) const
inline

Get the specular component of the light.

Definition at line 61 of file LightSource.h.

References OSG_VEC4F_TO_AGX.

◆ getSpotCutoff()

float agxOSG::LightSource::getSpotCutoff ( ) const
inline

Get the spot cutoff of the light.

Definition at line 103 of file LightSource.h.

◆ getSpotExponent()

float agxOSG::LightSource::getSpotExponent ( ) const
inline

Get the spot exponent of the light.

Definition at line 97 of file LightSource.h.

◆ setAmbient()

void agxOSG::LightSource::setAmbient ( const agx::Vec4f ambient)
inline

Set the ambient component of the light.

Definition at line 46 of file LightSource.h.

References AGX_VEC4_TO_OSG.

◆ setConstantAttenuation()

void agxOSG::LightSource::setConstantAttenuation ( float  constant_attenuation)
inline

Set the constant attenuation of the light.

Definition at line 76 of file LightSource.h.

◆ setDiffuse()

void agxOSG::LightSource::setDiffuse ( const agx::Vec4f diffuse)
inline

Set the diffuse component of the light.

Definition at line 52 of file LightSource.h.

References AGX_VEC4_TO_OSG.

◆ setDirection()

void agxOSG::LightSource::setDirection ( const agx::Vec3 direction)
inline

Set the direction of the light.

Definition at line 70 of file LightSource.h.

References AGX_VEC3_TO_OSG.

◆ setLinearAttenuation()

void agxOSG::LightSource::setLinearAttenuation ( float  linear_attenuation)
inline

Set the linear attenuation of the light.

Definition at line 82 of file LightSource.h.

◆ setPosition()

void agxOSG::LightSource::setPosition ( const agx::Vec4 position)
inline

Set the position of the light.

Definition at line 64 of file LightSource.h.

References AGX_VEC4_TO_OSG.

◆ setQuadraticAttenuation()

void agxOSG::LightSource::setQuadraticAttenuation ( float  quadratic_attenuation)
inline

Set the quadratic attenuation of the light.

Definition at line 88 of file LightSource.h.

◆ setSpecular()

void agxOSG::LightSource::setSpecular ( const agx::Vec4f specular)
inline

Set the specular component of the light.

Definition at line 58 of file LightSource.h.

References AGX_VEC4_TO_OSG.

◆ setSpotCutoff()

void agxOSG::LightSource::setSpotCutoff ( float  spot_cutoff)
inline

Set the spot cutoff of the light.

Definition at line 100 of file LightSource.h.

◆ setSpotExponent()

void agxOSG::LightSource::setSpotExponent ( float  spot_exponent)
inline

Set the spot exponent of the light.

Definition at line 94 of file LightSource.h.

Member Data Documentation

◆ m_light

osg::ref_ptr<osg::Light> agxOSG::LightSource::m_light
protected

Definition at line 108 of file LightSource.h.


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