Home | Download | Screen shots | Discussion | Documentation |
---|
Abstract base class for nodes that represent a bounded volume in the scene graph. More...
#include <openvrml/node.h>
Public Member Functions | |
virtual | ~bounded_volume_node () throw () |
Destroy. | |
const openvrml::bounding_volume & | bounding_volume () const |
Get this node's bounding volume. | |
Protected Member Functions | |
bounded_volume_node (const node_type &type, const boost::shared_ptr< openvrml::scope > &scope) throw () | |
Construct. | |
void | bounding_volume_dirty (bool value) |
Set whether the node's bounding volume needs to be recalculated. | |
bool | bounding_volume_dirty () const |
Whether the node's bounding volume needs to be recalculated. | |
virtual const openvrml::bounding_volume & | do_bounding_volume () const |
Called by bounding_volume . | |
Private Member Functions | |
virtual bounded_volume_node * | to_bounded_volume () throw () |
Cast to an bounded_volume_node . | |
Private Attributes | |
boost::shared_mutex | bounding_volume_dirty_mutex_ |
Mutex protecting bounding_volume_dirty_ . | |
bool | bounding_volume_dirty_ |
Indicate whether the node 's cached bounding volume needs updating. |
Abstract base class for nodes that represent a bounded volume in the scene graph.
openvrml::bounded_volume_node::~bounded_volume_node | ( | ) | throw () [virtual] |
Destroy.
openvrml::bounded_volume_node::bounded_volume_node | ( | const node_type & | type, | |
const boost::shared_ptr< openvrml::scope > & | scope | |||
) | throw () [protected] |
const openvrml::bounding_volume & openvrml::bounded_volume_node::bounding_volume | ( | ) | const |
Get this node's bounding volume.
Nodes that have no bounding volume, or have a difficult to calculate bvolume (like, say, Extrusion or Billboard) can just return an infinite bsphere. Note that returning an infinite bvolume means that all the node's ancestors will also end up with an infinite bvolume, and will never be culled.
Delegates to do_bounding_volume
.
void openvrml::bounded_volume_node::bounding_volume_dirty | ( | bool | value | ) | [protected] |
Set whether the node's bounding volume needs to be recalculated.
Indicate that a node's bounding volume needs to be recalculated (or not). If a node's bounding volume is invalid, then the bounding volumes of all that node's ancestors are also invalid. Normally, the node itself will determine when its bounding volume needs updating.
[in] | value | true if the node's bounding volume should be recalculated; false otherwise. |
bool openvrml::bounded_volume_node::bounding_volume_dirty | ( | ) | const [protected] |
Whether the node's bounding volume needs to be recalculated.
true
if the node's bounding volume needs to be recalculated; false
otherwise. const openvrml::bounding_volume & openvrml::bounded_volume_node::do_bounding_volume | ( | ) | const [protected, virtual] |
Called by bounding_volume
.
openvrml::bounded_volume_node * openvrml::bounded_volume_node::to_bounded_volume | ( | ) | throw () [private, virtual] |
Cast to an bounded_volume_node
.
bounded_volume_node
. Reimplemented from openvrml::node.
boost::shared_mutex openvrml::bounded_volume_node::bounding_volume_dirty_mutex_ [mutable, private] |
bool openvrml::bounded_volume_node::bounding_volume_dirty_ [mutable, private] |