Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

osg::CullStack Class Reference

A CullStack class which accumulates the current project, modelview matrices and the CullingSet. More...

Inheritance diagram for osg::CullStack:

Inheritance graph
[legend]
List of all members.

Public Types

typedef std::vector< ShadowVolumeOccluderOccluderList
typedef unsigned int CullingMode
typedef fast_back_stack< ref_ptr<
CullingSet > > 
CullingStack
enum  CullingModeValues {
  NO_CULLING = 0x0, VIEW_FRUSTUM_CULLING = 0x1, NEAR_PLANE_CULLING = 0x2, FAR_PLANE_CULLING = 0x4,
  SMALL_FEATURE_CULLING = 0x8, SHADOW_OCCLUSION_CULLING = 0x10, ENABLE_ALL_CULLING
}

Public Methods

 CullStack ()
 ~CullStack ()
void reset ()
void setOccluderList (const ShadowVolumeOccluderList &svol)
ShadowVolumeOccluderListgetOccluderList ()
const ShadowVolumeOccluderListgetOccluderList () const
void pushViewport (osg::Viewport *viewport)
void popViewport ()
void pushProjectionMatrix (osg::Matrix *matrix)
void popProjectionMatrix ()
void pushModelViewMatrix (osg::Matrix *matrix)
void popModelViewMatrix ()
float getFrustumVolume ()
void setCullingMode (CullingMode mode)
 Sets the current CullingMode.

CullingMode getCullingMode () const
 Returns the current CullingMode.

void setLODBias (const float bias)
const float getLODBias () const
void setSmallFeatureCullingPixelSize (float value)
float getSmallFeatureCullingPixelSize () const
float pixelSize (const Vec3 &v, float radius) const
 Compute the pixel of an object at position v, with specified radius.

float pixelSize (const BoundingSphere &bs) const
 Compute the pixel of an bounding sphere.

void disableAndPushOccludersCurrentMask (NodePath &nodePath)
void popOccludersCurrentMask (NodePath &nodePath)
bool isCulled (const std::vector< Vec3 > &vertices)
bool isCulled (const BoundingBox &bb)
bool isCulled (const BoundingSphere &bs)
bool isCulled (const osg::Node &node)
void pushCurrentMask ()
void popCurrentMask ()
CullingStackgetClipSpaceCullingStack ()
CullingStackgetProjectionCullingStack ()
CullingStackgetModelViewCullingStack ()
CullingSetgetCurrentCullingSet ()
osg::ViewportgetViewport ()
osg::MatrixgetModelViewMatrix ()
osg::MatrixgetProjectionMatrix ()
const osg::Matrix getWindowMatrix ()
const osg::MatrixgetMVPW ()
const osg::Vec3getEyeLocal () const
const osg::Vec3 getUpLocal () const
const osg::Vec3 getLookVectorLocal () const

Protected Types

typedef fast_back_stack< ref_ptr<
Matrix > > 
MatrixStack
typedef fast_back_stack< ref_ptr<
Viewport > > 
ViewportStack
typedef fast_back_stack< Vec3EyePointStack
typedef std::vector< osg::ref_ptr<
osg::Matrix > > 
MatrixList

Protected Methods

void pushCullingSet ()
void popCullingSet ()
void computeFrustumVolume ()
osg::MatrixcreateOrReuseMatrix (const osg::Matrix &value)

Protected Attributes

CullingMode _cullingMode
float _LODBias
float _smallFeatureCullingPixelSize
ShadowVolumeOccluderList _occluderList
MatrixStack _projectionStack
MatrixStack _modelviewStack
MatrixStack _MVPW_Stack
ViewportStack _viewportStack
EyePointStack _eyePointStack
CullingStack _clipspaceCullingStack
CullingStack _projectionCullingStack
CullingStack _modelviewCullingStack
float _frustumVolume
unsigned int _bbCornerNear
unsigned int _bbCornerFar
osg::Matrix _identity
MatrixList _reuseMatrixList
unsigned int _currentReuseMatrixIndex

Detailed Description

A CullStack class which accumulates the current project, modelview matrices and the CullingSet.


Member Typedef Documentation

typedef unsigned int osg::CullStack::CullingMode
 

typedef fast_back_stack<ref_ptr<CullingSet> > osg::CullStack::CullingStack
 

typedef fast_back_stack<Vec3> osg::CullStack::EyePointStack [protected]
 

typedef std::vector< osg::ref_ptr<osg::Matrix> > osg::CullStack::MatrixList [protected]
 

typedef fast_back_stack< ref_ptr<Matrix> > osg::CullStack::MatrixStack [protected]
 

typedef std::vector<ShadowVolumeOccluder> osg::CullStack::OccluderList
 

typedef fast_back_stack<ref_ptr<Viewport> > osg::CullStack::ViewportStack [protected]
 


Member Enumeration Documentation

enum osg::CullStack::CullingModeValues
 

Enumeration values:
NO_CULLING 
VIEW_FRUSTUM_CULLING 
NEAR_PLANE_CULLING 
FAR_PLANE_CULLING 
SMALL_FEATURE_CULLING 
SHADOW_OCCLUSION_CULLING 
ENABLE_ALL_CULLING 


Constructor & Destructor Documentation

osg::CullStack::CullStack  
 

osg::CullStack::~CullStack  
 


Member Function Documentation

void osg::CullStack::computeFrustumVolume   [protected]
 

Matrix * osg::CullStack::createOrReuseMatrix const osg::Matrix   value [inline, protected]
 

void osg::CullStack::disableAndPushOccludersCurrentMask NodePath   nodePath [inline]
 

CullingStack& osg::CullStack::getClipSpaceCullingStack   [inline]
 

CullingMode osg::CullStack::getCullingMode   const [inline]
 

Returns the current CullingMode.

CullingSet& osg::CullStack::getCurrentCullingSet   [inline]
 

const osg::Vec3& osg::CullStack::getEyeLocal   const [inline]
 

float osg::CullStack::getFrustumVolume   [inline]
 

const float osg::CullStack::getLODBias   const [inline]
 

const osg::Vec3 osg::CullStack::getLookVectorLocal   const [inline]
 

CullingStack& osg::CullStack::getModelViewCullingStack   [inline]
 

osg::Matrix & osg::CullStack::getModelViewMatrix   [inline]
 

const osg::Matrix & osg::CullStack::getMVPW   [inline]
 

const ShadowVolumeOccluderList& osg::CullStack::getOccluderList   const [inline]
 

ShadowVolumeOccluderList& osg::CullStack::getOccluderList   [inline]
 

CullingStack& osg::CullStack::getProjectionCullingStack   [inline]
 

osg::Matrix & osg::CullStack::getProjectionMatrix   [inline]
 

float osg::CullStack::getSmallFeatureCullingPixelSize   const [inline]
 

const osg::Vec3 osg::CullStack::getUpLocal   const [inline]
 

osg::Viewport * osg::CullStack::getViewport   [inline]
 

const osg::Matrix osg::CullStack::getWindowMatrix   [inline]
 

bool osg::CullStack::isCulled const osg::Node   node [inline]
 

bool osg::CullStack::isCulled const BoundingSphere   bs [inline]
 

bool osg::CullStack::isCulled const BoundingBox   bb [inline]
 

bool osg::CullStack::isCulled const std::vector< Vec3 > &    vertices [inline]
 

float osg::CullStack::pixelSize const BoundingSphere   bs const [inline]
 

Compute the pixel of an bounding sphere.

float osg::CullStack::pixelSize const Vec3   v,
float    radius
const [inline]
 

Compute the pixel of an object at position v, with specified radius.

void osg::CullStack::popCullingSet   [protected]
 

void osg::CullStack::popCurrentMask   [inline]
 

void osg::CullStack::popModelViewMatrix  
 

void osg::CullStack::popOccludersCurrentMask NodePath   nodePath [inline]
 

void osg::CullStack::popProjectionMatrix  
 

Reimplemented in osgUtil::CullVisitor.

void osg::CullStack::popViewport  
 

void osg::CullStack::pushCullingSet   [protected]
 

void osg::CullStack::pushCurrentMask   [inline]
 

void osg::CullStack::pushModelViewMatrix osg::Matrix   matrix
 

void osg::CullStack::pushProjectionMatrix osg::Matrix   matrix
 

void osg::CullStack::pushViewport osg::Viewport   viewport
 

void osg::CullStack::reset  
 

Reimplemented in osg::CollectOccludersVisitor, and osgUtil::CullVisitor.

void osg::CullStack::setCullingMode CullingMode    mode [inline]
 

Sets the current CullingMode.

void osg::CullStack::setLODBias const float    bias [inline]
 

void osg::CullStack::setOccluderList const ShadowVolumeOccluderList   svol [inline]
 

void osg::CullStack::setSmallFeatureCullingPixelSize float    value [inline]
 


Member Data Documentation

unsigned int osg::CullStack::_bbCornerFar [protected]
 

unsigned int osg::CullStack::_bbCornerNear [protected]
 

CullingStack osg::CullStack::_clipspaceCullingStack [protected]
 

CullingMode osg::CullStack::_cullingMode [protected]
 

unsigned int osg::CullStack::_currentReuseMatrixIndex [protected]
 

EyePointStack osg::CullStack::_eyePointStack [protected]
 

float osg::CullStack::_frustumVolume [protected]
 

osg::Matrix osg::CullStack::_identity [protected]
 

float osg::CullStack::_LODBias [protected]
 

CullingStack osg::CullStack::_modelviewCullingStack [protected]
 

MatrixStack osg::CullStack::_modelviewStack [protected]
 

MatrixStack osg::CullStack::_MVPW_Stack [protected]
 

ShadowVolumeOccluderList osg::CullStack::_occluderList [protected]
 

CullingStack osg::CullStack::_projectionCullingStack [protected]
 

MatrixStack osg::CullStack::_projectionStack [protected]
 

MatrixList osg::CullStack::_reuseMatrixList [protected]
 

float osg::CullStack::_smallFeatureCullingPixelSize [protected]
 

ViewportStack osg::CullStack::_viewportStack [protected]
 


The documentation for this class was generated from the following file:
Generated at Wed Sep 18 13:55:27 2002 for the Open Scene Graph by doxygen 1.2.16.