#include <OSGVolume.h>
Inheritance diagram for osg::Volume:

Public Member Functions | |
| bool | operator== (const Volume &other) const |
| bool | operator!= (const Volume &other) const |
Destructor | |
| *virtual | ~Volume (void) |
State | |
| *void | setValid (const bool value=true) |
| bool | isValid (void) const |
| void | setEmpty (const bool value=true) |
| bool | isEmpty (void) const |
| void | setStatic (const bool value=true) |
| bool | isStatic (void) const |
| void | setInfinite (const bool value=true) |
| bool | isInfinite (void) const |
| bool | isUntouchable (void) const |
| UInt16 | getState (void) const |
| void | setState (UInt16 state) |
Get Values | |
| *virtual void | getCenter (Pnt3f ¢er) const =0 |
| virtual float | getScalarVolume (void) const =0 |
| virtual void | getBounds (Pnt3f &min, Pnt3f &max) const =0 |
| Pnt3f | getMin (void) const |
| Pnt3f | getMax (void) const |
Extending | |
| *virtual void | extendBy (const Pnt3f &pt)=0 |
| virtual void | extendBy (const Volume &volume)=0 |
Intersection | |
| *virtual bool | intersect (const Pnt3f &point) const =0 |
| virtual bool | intersect (const Line &line) const =0 |
| virtual bool | intersect (const Line &line, Real32 &enter, Real32 &exit) const =0 |
| virtual bool | intersect (const Volume &volume) const =0 |
| virtual bool | isOnSurface (const Pnt3f &point) const =0 |
Transformation | |
| *virtual void | transform (const Matrix &matrix)=0 |
Output | |
| *virtual void | dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const =0 |
Protected Member Functions | |
Constructors | |
| * | Volume (void) |
| Volume (const Volume &obj) | |
Protected Attributes | |
| UInt16 | _state |
Private Types | |
| enum | State { OSGVALID = 1, OSGEMPTY = 2, OSGSTATIC = 4, OSGINFINITE = 8 } |
Definition at line 55 of file OSGVolume.h.
|
|
Definition at line 163 of file OSGVolume.h. 00164 { 00165 OSGVALID = 1, 00166 OSGEMPTY = 2, 00167 OSGSTATIC = 4, 00168 OSGINFINITE = 8 00169 };
|
|
|
Definition at line 54 of file OSGVolume.inl.
|
|
|
Definition at line 210 of file OSGVolume.inl.
|
|
|
Definition at line 216 of file OSGVolume.inl.
|
|
|
set the volume to be valid Definition at line 82 of file OSGVolume.inl. References _state, isStatic(), and OSGVALID. Referenced by osg::Surface::adjustVolume(), osg::Slices::adjustVolume(), osg::ProxyGroup::adjustVolume(), osg::Particles::adjustVolume(), osg::Geometry::adjustVolume(), osg::DVRVolume::adjustVolume(), osg::Node::invalidateVolume(), osg::BoxVolume::setBounds(), and osg::BoxVolume::setBoundsByCenterAndSize(). 00083 { 00084 if(!isStatic()) 00085 { 00086 if(value == true) 00087 _state |= OSGVALID; 00088 else 00089 _state &= ~OSGVALID; 00090 } 00091 }
|
|
|
Checks if the volume is valid Definition at line 96 of file OSGVolume.inl. References _state, and OSGVALID. Referenced by osg::Group::intersect(), osg::Geometry::intersect(), osg::DVRVolume::intersect(), and osg::Node::invalidateVolume().
|
|
|
set the volume to contain nothing Definition at line 104 of file OSGVolume.inl. References _state, OSGEMPTY, OSGINFINITE, and OSGVALID. Referenced by osg::Surface::adjustVolume(), osg::Slices::adjustVolume(), osg::ProxyGroup::adjustVolume(), osg::Particles::adjustVolume(), osg::Geometry::adjustVolume(), osg::DVRVolume::adjustVolume(), osg::BoxVolume::BoxVolume(), osg::CylinderVolume::CylinderVolume(), osg::ParticleBSPTree::doBuild(), osg::SphereVolume::extendBy(), osg::BoxVolume::extendBy(), osg::BoxVolume::setBounds(), osg::BoxVolume::setBoundsByCenterAndSize(), osg::SphereVolume::setValue(), osg::SphereVolume::SphereVolume(), and osg::Node::updateVolume(). 00105 { 00106 if(value == true) 00107 { 00108 _state |= OSGEMPTY; 00109 _state |= OSGVALID; 00110 _state &= ~OSGINFINITE; 00111 } 00112 else 00113 { 00114 _state &= ~OSGEMPTY; 00115 } 00116 }
|
|
|
Checks if the volume is empty Definition at line 121 of file OSGVolume.inl. References _state, and OSGEMPTY. Referenced by osg::SphereVolume::extendBy(), osg::BoxVolume::extendBy(), osg::BoxVolume::getCenter(), osg::SphereVolume::getScalarVolume(), osg::CylinderVolume::getScalarVolume(), osg::BoxVolume::getScalarVolume(), osg::BoxVolume::intersect(), and osg::BoxVolume::transform().
|
|
|
set the volume to be static Definition at line 63 of file OSGVolume.inl. References _state, and OSGSTATIC. 00064 { 00065 if(value == true) 00066 _state |= OSGSTATIC; 00067 else 00068 _state &= ~OSGSTATIC; 00069 }
|
|
|
Checks if the volume is static Definition at line 74 of file OSGVolume.inl. References _state, and OSGSTATIC. Referenced by osg::Node::invalidateVolume(), and setValid().
|
|
|
set the volume to be infinite Definition at line 129 of file OSGVolume.inl. References _state, OSGEMPTY, OSGINFINITE, and OSGVALID. Referenced by osg::BoxVolume::setBounds(), and osg::BoxVolume::setBoundsByCenterAndSize(). 00130 { 00131 if(value == true) 00132 { 00133 _state |= OSGINFINITE; 00134 _state |= OSGVALID; 00135 _state &= ~OSGEMPTY; 00136 } 00137 else 00138 { 00139 _state &= ~OSGINFINITE; 00140 } 00141 }
|
|
|
Checks if the volume is infinite Definition at line 146 of file OSGVolume.inl. References _state, and OSGINFINITE. 00147 { 00148 return (_state & OSGINFINITE) ? true : false; 00149 }
|
|
|
Checks if the volume is untouchable, i.e. it's values should not be changed. Mainly used internally to speed up early outs in extendBy(). Definition at line 157 of file OSGVolume.inl. References _state, OSGINFINITE, OSGSTATIC, and OSGVALID. Referenced by osg::SphereVolume::extendBy(), and osg::BoxVolume::extendBy(). 00158 { 00159 return (_state & (OSGINFINITE | OSGVALID | OSGSTATIC)) != OSGVALID; 00160 }
|
|
|
get the volume's state Definition at line 166 of file OSGVolume.inl. References _state. Referenced by osg::FieldDataTraits< DynamicVolume >::copyToBin(), and osg::DynamicVolume::instanceChanged(). 00167 { 00168 return _state; 00169 }
|
|
|
set the volume's state Definition at line 174 of file OSGVolume.inl. References _state. Referenced by osg::FieldDataTraits< DynamicVolume >::copyFromBin(). 00175 { 00176 _state = val; 00177 }
|
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::DynamicVolume::getCenter(). |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::DynamicVolume::getScalarVolume(). |
|
||||||||||||
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::Billboard::adjustVolume(), osg::DynamicVolume::getBounds(), getMax(), getMin(), and osg::intersect(). |
|
|
Return the lowest point of the volume. Just a convience wrapper for getBounds() Reimplemented in osg::BoxVolume. Definition at line 184 of file OSGVolume.inl. References getBounds(). 00185 { 00186 Pnt3f pmin; 00187 Pnt3f pmax; 00188 00189 getBounds(pmin, pmax); 00190 00191 return pmin; 00192 }
|
|
|
Return the highest point of the volume. Just a convience wrapper for getBounds() Reimplemented in osg::BoxVolume. Definition at line 199 of file OSGVolume.inl. References getBounds(). 00200 { 00201 Pnt3f pmin; 00202 Pnt3f pmax; 00203 00204 getBounds(pmin, pmax); 00205 00206 return pmax; 00207 }
|
|
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::DynamicVolume::intersect(). |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. |
|
||||||||||||||||
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::DynamicVolume::isOnSurface(). |
|
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::Transform::adjustVolume(), osg::InverseTransform::adjustVolume(), and osg::DynamicVolume::transform(). |
|
||||||||||||
|
Implemented in osg::BoxVolume, osg::CylinderVolume, osg::DynamicVolume, osg::FrustumVolume, osg::PolytopeVolume, and osg::SphereVolume. Referenced by osg::DynamicVolume::dump(), and osg::volDump(). |
|
|
Definition at line 53 of file OSGVolume.cpp. References _state. 00054 { 00055 return _state == other._state; 00056 }
|
|
|
Definition at line 58 of file OSGVolume.cpp.
|
|
|
Definition at line 149 of file OSGVolume.h. Referenced by getState(), osg::DynamicVolume::instanceChanged(), isEmpty(), isInfinite(), isStatic(), isUntouchable(), isValid(), osg::FrustumVolume::operator=(), osg::BoxVolume::operator=(), operator==(), setEmpty(), setInfinite(), setState(), setStatic(), and setValid(). |
1.4.3