Home | Download | Screen shots | Discussion | Documentation |
---|
Public Member Functions | |
point_light_node (const node_type &type, const boost::shared_ptr< openvrml::scope > &scope) | |
Construct. | |
virtual | ~point_light_node () throw () |
Destroy. | |
virtual point_light_node * | to_point_light () const |
Cast to a point_light_node. | |
virtual void | renderScoped (openvrml::viewer &viewer) |
Render the scoped light. | |
Private Member Functions | |
virtual void | do_initialize (double timestamp) throw (std::bad_alloc) |
Initialize. | |
virtual void | do_shutdown (double timestamp) throw () |
Shut down. | |
Private Attributes | |
exposedfield< sfvec3f > | attenuation_ |
attenuation exposedField. | |
exposedfield< sfvec3f > | location_ |
location exposedField. | |
exposedfield< sffloat > | radius_ |
radius exposedField. | |
Friends | |
class | point_light_class |
Class object for PointLight instances. |
openvrml::vrml97_node::point_light_node::point_light_node | ( | const node_type & | type, | |
const boost::shared_ptr< openvrml::scope > & | scope | |||
) |
Construct.
type | the node_type associated with the node instance. | |
scope | the scope to which the node belongs. |
openvrml::vrml97_node::point_light_node::~point_light_node | ( | ) | throw () [virtual] |
Destroy.
point_light_node * openvrml::vrml97_node::point_light_node::to_point_light | ( | ) | const [virtual] |
Cast to a point_light_node.
Reimplemented from openvrml::node.
void openvrml::vrml97_node::point_light_node::renderScoped | ( | openvrml::viewer & | viewer | ) | [virtual] |
Render the scoped light.
This should be called before rendering any geometry nodes in the scene. Since this is called from Scene::render() before traversing the scene graph, the proper transformation matrix hasn't been set up. Somehow it needs to figure out the accumulated xforms of its parents and apply them before rendering. This is not easy with DEF/USEd nodes...
viewer | a viewer. |
Reimplemented from openvrml::vrml97_node::abstract_light_node.
void openvrml::vrml97_node::point_light_node::do_initialize | ( | double | timestamp | ) | throw (std::bad_alloc) [private, virtual] |
Initialize.
timestamp | the current time. |
std::bad_alloc | if memory allocation fails. |
Reimplemented from openvrml::node.
void openvrml::vrml97_node::point_light_node::do_shutdown | ( | double | timestamp | ) | throw () [private, virtual] |
openvrml::vrml97_node::point_light_node::point_light_class [friend] |
Class object for PointLight instances.
attenuation exposedField.
location exposedField.
radius exposedField.