#include <Light.h>


Public Member Functions | |
| Light () | |
| virtual | ~Light () |
| void | setID (const GLint &id) |
| virtual void | initVisual () |
| Initialize the textures, or other graphical resources. | |
| void | init () |
| Initialization method called at graph modification, during bottom-up traversal. | |
| virtual void | drawLight () |
| void | draw () |
| Render internal data of this object, for debugging purposes. | |
| virtual void | reinit () |
| Update method called when variables used in precomputation are modified. | |
| void | update () |
| used to update the model if necessary. | |
Protected Attributes | |
| Data< Vector3 > | color |
| GLint | lightID |
Definition at line 56 of file Light.h.
| void sofa::component::visualmodel::Light::draw | ( | ) | [inline, virtual] |
Render internal data of this object, for debugging purposes.
Reimplemented from sofa::core::objectmodel::BaseObject.
| void sofa::component::visualmodel::Light::drawLight | ( | ) | [virtual] |
| void sofa::component::visualmodel::Light::init | ( | void | ) | [virtual] |
Initialization method called at graph modification, during bottom-up traversal.
Reimplemented from sofa::core::objectmodel::BaseObject.
Definition at line 86 of file Light.cpp.
References sofa::core::objectmodel::BaseObject::getContext(), and sofa::component::visualmodel::LightManager::putLight().
| void sofa::component::visualmodel::Light::initVisual | ( | ) | [virtual] |
Initialize the textures, or other graphical resources.
Called once before the first frame is drawn, and if the graphical context has been recreated.
Reimplemented from sofa::core::VisualModel.
Reimplemented in sofa::component::visualmodel::DirectionalLight, sofa::component::visualmodel::PositionalLight, and sofa::component::visualmodel::SpotLight.
Definition at line 95 of file Light.cpp.
References color, sofa::core::objectmodel::Data< T >::getValue(), and lightID.
Referenced by reinit().
| void sofa::component::visualmodel::Light::reinit | ( | ) | [virtual] |
Update method called when variables used in precomputation are modified.
Reimplemented from sofa::core::objectmodel::BaseObject.
Reimplemented in sofa::component::visualmodel::DirectionalLight, sofa::component::visualmodel::PositionalLight, and sofa::component::visualmodel::SpotLight.
Definition at line 107 of file Light.cpp.
References initVisual().
| void sofa::component::visualmodel::Light::setID | ( | const GLint & | id | ) |
Definition at line 81 of file Light.cpp.
References lightID.
Referenced by sofa::component::visualmodel::LightManager::putLight().
| void sofa::component::visualmodel::Light::update | ( | ) | [inline, virtual] |
used to update the model if necessary.
Reimplemented from sofa::core::VisualModel.
Data<Vector3> sofa::component::visualmodel::Light::color [protected] |
GLint sofa::component::visualmodel::Light::lightID [protected] |
Definition at line 59 of file Light.h.
Referenced by sofa::component::visualmodel::SpotLight::drawLight(), sofa::component::visualmodel::PositionalLight::drawLight(), sofa::component::visualmodel::DirectionalLight::drawLight(), initVisual(), and setID().
1.5.7.1