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

osg::ClearNode Class Reference

A Group node for clearing the color and depth buffers. More...

Inheritance diagram for osg::ClearNode:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 ClearNode ()
 ClearNode (const ClearNode &cs, const CopyOp &copyop=CopyOp::SHALLOW_COPY)
 META_Node (osg, ClearNode)
void setRequiresClear (bool requiresClear)
 Enable/disable clearing via glClear.

bool getRequiresClear () const
 Gets whether clearing is enabled or disabled.

void setClearColor (const Vec4 &color)
 Sets the clear color.

const Vec4getClearColor () const
 Returns the clear color.

void setClearMask (GLbitfield mask)
 Set the clear mask used in glClear(..).

GLbitfield getClearMask () const
 Get the clear mask.


Protected Member Functions

virtual ~ClearNode ()

Protected Attributes

bool _requiresClear
Vec4 _clearColor
GLbitfield _clearMask

Detailed Description

A Group node for clearing the color and depth buffers.

Use setClearColor to change the clear color, and setRequiresClear to disable/enable the call clearing. You might want to disable clearing if you perform your clear by drawing fullscreen geometry. If you do this, add child nodes to perform such drawing. The default StateSet associated with this node places children in render bin -1 to ensure that children are rendered prior to the rest of the scene graph.


Constructor & Destructor Documentation

osg::ClearNode::ClearNode  ) 
 

osg::ClearNode::ClearNode const ClearNode cs,
const CopyOp copyop = CopyOp::SHALLOW_COPY
[inline]
 

virtual osg::ClearNode::~ClearNode  )  [inline, protected, virtual]
 


Member Function Documentation

const Vec4& osg::ClearNode::getClearColor  )  const [inline]
 

Returns the clear color.

GLbitfield osg::ClearNode::getClearMask  )  const [inline]
 

Get the clear mask.

bool osg::ClearNode::getRequiresClear  )  const [inline]
 

Gets whether clearing is enabled or disabled.

osg::ClearNode::META_Node osg  ,
ClearNode 
 

void osg::ClearNode::setClearColor const Vec4 color  )  [inline]
 

Sets the clear color.

void osg::ClearNode::setClearMask GLbitfield  mask  )  [inline]
 

Set the clear mask used in glClear(..).

Defaults to GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT.

void osg::ClearNode::setRequiresClear bool  requiresClear  )  [inline]
 

Enable/disable clearing via glClear.


Member Data Documentation

Vec4 osg::ClearNode::_clearColor [protected]
 

GLbitfield osg::ClearNode::_clearMask [protected]
 

bool osg::ClearNode::_requiresClear [protected]
 


The documentation for this class was generated from the following file:
Generated at Thu Nov 24 16:22:51 2005 for the OpenSceneGraph by doxygen 1.3.6.