OpenSceneGraph  3.0.1
Public Member Functions | Protected Member Functions
osgFX::Outline Class Reference

Outline effect. More...

Inheritance diagram for osgFX::Outline:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Outline ()
 Constructor.
 Outline (const Outline &copy, const osg::CopyOp &op=osg::CopyOp::SHALLOW_COPY)
 Copy constructor.
 META_Effect (osgFX, Outline,"Outline","Stencil buffer based object outline effect.\n""This effect needs a properly setup stencil buffer.","Ulrich Hertlein")
void setWidth (float w)
 Set outline width.
float getWidth () const
 Get outline width.
void setColor (const osg::Vec4 &color)
 Set outline color.
const osg::Vec4getColor () const
 Get outline color.

Protected Member Functions

virtual ~Outline ()
 Destructor.
bool define_techniques ()
 Define available techniques.

Detailed Description

Outline effect.

This effect draws a stencil buffer-based outline around an object. Color and width of the outline can be modified. To function correctly the context must be setup with a stencil buffer and the stencil buffer must be cleared to zero before each render.

osg::DisplaySettings::instance()->setMinimumNumStencilBits(1); camera->setClearMask(clearMask | GL_STENCIL_BUFFER_BIT); camera->setClearStencil(0);


Constructor & Destructor Documentation

osgFX::Outline::Outline ( )

Constructor.

osgFX::Outline::Outline ( const Outline copy,
const osg::CopyOp op = osg::CopyOp::SHALLOW_COPY 
) [inline]

Copy constructor.

virtual osgFX::Outline::~Outline ( ) [inline, protected, virtual]

Destructor.


Member Function Documentation

bool osgFX::Outline::define_techniques ( ) [protected, virtual]

Define available techniques.

Implements osgFX::Effect.

const osg::Vec4& osgFX::Outline::getColor ( ) const [inline]

Get outline color.

float osgFX::Outline::getWidth ( ) const [inline]

Get outline width.

osgFX::Outline::META_Effect ( osgFX  ,
Outline  ,
"Outline"  ,
"Stencil buffer based object outline effect.\n""This effect needs a properly setup stencil buffer."  ,
"Ulrich Hertlein"   
)
void osgFX::Outline::setColor ( const osg::Vec4 color)

Set outline color.

void osgFX::Outline::setWidth ( float  w)

Set outline width.


The documentation for this class was generated from the following file:

osg logo
Generated at Mon Oct 3 2011 12:39:47 for the OpenSceneGraph by doxygen 1.7.5.