OpenSceneGraph  3.4.0
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
osgTerrain::SharedGeometry Class Reference
Inheritance diagram for osgTerrain::SharedGeometry:
Inheritance graph
[legend]

List of all members.

Public Types

typedef std::vector< unsigned int > VertexToHeightFieldMapping

Public Member Functions

 SharedGeometry ()
 SharedGeometry (const SharedGeometry &, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
 META_Node (osgTerrain, SharedGeometry)
void setVertexArray (osg::Array *array)
osg::ArraygetVertexArray ()
const osg::ArraygetVertexArray () const
void setNormalArray (osg::Array *array)
osg::ArraygetNormalArray ()
const osg::ArraygetNormalArray () const
void setColorArray (osg::Array *array)
osg::ArraygetColorArray ()
const osg::ArraygetColorArray () const
void setTexCoordArray (osg::Array *array)
osg::ArraygetTexCoordArray ()
const osg::ArraygetTexCoordArray () const
void setDrawElements (osg::DrawElements *array)
osg::DrawElementsgetDrawElements ()
const osg::DrawElementsgetDrawElements () const
void setVertexToHeightFieldMapping (const VertexToHeightFieldMapping &vthfm)
VertexToHeightFieldMappinggetVertexToHeightFieldMapping ()
const VertexToHeightFieldMappinggetVertexToHeightFieldMapping () const
void compileGLObjects (osg::RenderInfo &renderInfo) const
 Immediately compile this Drawable into an OpenGL Display List/VertexBufferObjects.
void drawImplementation (osg::RenderInfo &renderInfo) const
 drawImplementation(RenderInfo&) is a pure virtual method for the actual implementation of OpenGL drawing calls, such as vertex arrays and primitives, that must be implemented in concrete subclasses of the Drawable base class, examples include osg::Geometry and osg::ShapeDrawable.
void resizeGLObjectBuffers (unsigned int maxSize)
 Resize any per context GLObject buffers to specified size.
void releaseGLObjects (osg::State *state) const
 If State is non-zero, this function releases OpenGL objects for the specified graphics context.
virtual bool supports (const osg::Drawable::AttributeFunctor &) const
 Return true if the Drawable subclass supports accept(AttributeFunctor&).
virtual void accept (osg::Drawable::AttributeFunctor &)
 accept an AttributeFunctor and call its methods to tell it about the internal attributes that this Drawable has.
virtual bool supports (const osg::Drawable::ConstAttributeFunctor &) const
 Return true if the Drawable subclass supports accept(ConstAttributeFunctor&).
virtual void accept (osg::Drawable::ConstAttributeFunctor &) const
 Accept an AttributeFunctor and call its methods to tell it about the internal attributes that this Drawable has.
virtual bool supports (const osg::PrimitiveFunctor &) const
 Return true if the Drawable subclass supports accept(PrimitiveFunctor&).
virtual void accept (osg::PrimitiveFunctor &) const
 Accept a PrimitiveFunctor and call its methods to tell it about the internal primitives that this Drawable has.
virtual bool supports (const osg::PrimitiveIndexFunctor &) const
 Return true if the Drawable subclass supports accept(PrimitiveIndexFunctor&).
virtual void accept (osg::PrimitiveIndexFunctor &) const
 Accept a PrimitiveIndexFunctor and call its methods to tell it about the internal primitives that this Drawable has.

Protected Member Functions

virtual ~SharedGeometry ()

Protected Attributes

osg::ref_ptr< osg::Array_vertexArray
osg::ref_ptr< osg::Array_normalArray
osg::ref_ptr< osg::Array_colorArray
osg::ref_ptr< osg::Array_texcoordArray
osg::ref_ptr< osg::DrawElements_drawElements
VertexToHeightFieldMapping _vertexToHeightFieldMapping

Member Typedef Documentation

typedef std::vector<unsigned int> osgTerrain::SharedGeometry::VertexToHeightFieldMapping

Constructor & Destructor Documentation

virtual osgTerrain::SharedGeometry::~SharedGeometry ( ) [protected, virtual]

Member Function Documentation

accept an AttributeFunctor and call its methods to tell it about the internal attributes that this Drawable has.

return true if functor handled by drawable, return false on failure of drawable to generate functor calls.

Reimplemented from osg::Drawable.

Accept an AttributeFunctor and call its methods to tell it about the internal attributes that this Drawable has.

return true if functor handled by drawable, return false on failure of drawable to generate functor calls.

Reimplemented from osg::Drawable.

virtual void osgTerrain::SharedGeometry::accept ( osg::PrimitiveFunctor ) const [virtual]

Accept a PrimitiveFunctor and call its methods to tell it about the internal primitives that this Drawable has.

return true if functor handled by drawable, return false on failure of drawable to generate functor calls. Note, PrimtiveFunctor only provides const access of the primitives, as primitives may be procedurally generated so one cannot modify it.

Reimplemented from osg::Drawable.

virtual void osgTerrain::SharedGeometry::accept ( osg::PrimitiveIndexFunctor ) const [virtual]

Accept a PrimitiveIndexFunctor and call its methods to tell it about the internal primitives that this Drawable has.

return true if functor handled by drawable, return false on failure of drawable to generate functor calls. Note, PrimtiveIndexFunctor only provide const access of the primitives, as primitives may be procedurally generated so one cannot modify it.

Reimplemented from osg::Drawable.

void osgTerrain::SharedGeometry::compileGLObjects ( osg::RenderInfo renderInfo) const [virtual]

Immediately compile this Drawable into an OpenGL Display List/VertexBufferObjects.

Note:
Operation is ignored if _useDisplayList is false or VertexBufferObjects are not used.

Reimplemented from osg::Drawable.

drawImplementation(RenderInfo&) is a pure virtual method for the actual implementation of OpenGL drawing calls, such as vertex arrays and primitives, that must be implemented in concrete subclasses of the Drawable base class, examples include osg::Geometry and osg::ShapeDrawable.

drawImplementation(RenderInfo&) is called from the draw(RenderInfo&) method, with the draw method handling management of OpenGL display lists, and drawImplementation(RenderInfo&) handling the actual drawing itself.

Parameters:
renderInfoThe osg::RenderInfo object that encapsulates the current rendering information including the osg::State OpenGL state for the current graphics context.

Reimplemented from osg::Drawable.

void osgTerrain::SharedGeometry::releaseGLObjects ( osg::State state) const [virtual]

If State is non-zero, this function releases OpenGL objects for the specified graphics context.

Otherwise, releases OpenGL objects for all graphics contexts.

Reimplemented from osg::Drawable.

void osgTerrain::SharedGeometry::resizeGLObjectBuffers ( unsigned int  maxSize) [virtual]

Resize any per context GLObject buffers to specified size.

Reimplemented from osg::Drawable.

virtual bool osgTerrain::SharedGeometry::supports ( const osg::Drawable::AttributeFunctor ) const [inline, virtual]

Return true if the Drawable subclass supports accept(AttributeFunctor&).

Reimplemented from osg::Drawable.

virtual bool osgTerrain::SharedGeometry::supports ( const osg::Drawable::ConstAttributeFunctor ) const [inline, virtual]

Return true if the Drawable subclass supports accept(ConstAttributeFunctor&).

Reimplemented from osg::Drawable.

virtual bool osgTerrain::SharedGeometry::supports ( const osg::PrimitiveFunctor ) const [inline, virtual]

Return true if the Drawable subclass supports accept(PrimitiveFunctor&).

Reimplemented from osg::Drawable.

virtual bool osgTerrain::SharedGeometry::supports ( const osg::PrimitiveIndexFunctor ) const [inline, virtual]

Return true if the Drawable subclass supports accept(PrimitiveIndexFunctor&).

Reimplemented from osg::Drawable.


Member Data Documentation


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

osg logo
Generated at Tue Dec 8 2015 00:14:30 for the OpenSceneGraph by doxygen 1.7.6.1.