
Public Types | |
| typedef std::vector < osg::Vec3 > | Vec3List |
| typedef std::vector < GLuint > | UIntList |
Public Member Functions | |
| OccluderGeometry () | |
| OccluderGeometry (const OccluderGeometry &oc, const osg::CopyOp ©op=osg::CopyOp::SHALLOW_COPY) | |
| virtual Object * | cloneType () const |
| Clone the type of an object, with Object* return type. | |
| virtual Object * | clone (const osg::CopyOp ©op) const |
| Clone an object, with Object* return type. | |
| virtual bool | isSameKindAs (const osg::Object *obj) const |
| virtual const char * | libraryName () const |
| return the name of the object's library. | |
| virtual const char * | className () const |
| return the name of the object's class type. | |
| void | computeOccluderGeometry (osg::Node *subgraph, osg::Matrix *matrix=0, float sampleRatio=1.0f) |
| Compute an occluder geometry containing all the geometry in specified subgraph. | |
| void | computeOccluderGeometry (osg::Drawable *drawable, osg::Matrix *matrix=0, float sampleRatio=1.0f) |
| Compute an occluder geometry containing the geometry in specified drawable. | |
| void | computeShadowVolumeGeometry (const osg::Vec4 &lightpos, ShadowVolumeGeometry &svg) const |
| Compute ShadowVolumeGeometry. | |
| void | setBoundingPolytope (const osg::Polytope &polytope) |
| Set the bounding polytope of the OccluderGeometry. | |
| osg::Polytope & | getBoundingPolytope () |
| Get the bounding polytope of the OccluderGeometry. | |
| const osg::Polytope & | getBoundingPolytope () const |
| Get the const bounding polytope of the OccluderGeometry. | |
| virtual void | drawImplementation (osg::RenderInfo &renderInfo) const |
| Render the occluder geometry. | |
| virtual osg::BoundingBox | computeBound () const |
| Compute the bounding box around occluder geometry. | |
| void | processGeometry (osg::Drawable *drawable, osg::Matrix *matrix=0, float sampleRatio=1.0f) |
Protected Types | |
| typedef std::vector < Edge > | EdgeList |
Protected Member Functions | |
| virtual | ~OccluderGeometry () |
| bool | isLightPointSilhouetteEdge (const osg::Vec3 &lightpos, const Edge &edge) const |
| bool | isLightDirectionSilhouetteEdge (const osg::Vec3 &lightdirection, const Edge &edge) const |
| void | setUpInternalStructures () |
| void | removeDuplicateVertices () |
| void | removeNullTriangles () |
| void | computeNormals () |
| void | buildEdgeMaps () |
| void | computeLightDirectionSilhouetteEdges (const osg::Vec3 &lightdirection, UIntList &silhouetteIndices) const |
| void | computeLightPositionSilhouetteEdges (const osg::Vec3 &lightpos, UIntList &silhouetteIndices) const |
Protected Attributes | |
| osg::Polytope | _boundingPolytope |
| Vec3List | _vertices |
| Vec3List | _normals |
| Vec3List | _triangleNormals |
| UIntList | _triangleIndices |
| EdgeList | _edges |
Classes | |
| struct | Edge |
OccluderGeometry supports the computation of silhouette edges and shadow volume geometries, as well as use as geometry that one can rendering into a shadow map or end caps for the ZP+ algorithm. OccluderGeometry may be of the same resolution as an underlying geometry that it represents, or can be of lower resolution and combine manager seperate geometries together into a single shadow casting object. OccluderGeometry may be attached as UserData to Nodes or to Drawables.
| typedef std::vector<osg::Vec3> osgShadow::OccluderGeometry::Vec3List |
| typedef std::vector<GLuint> osgShadow::OccluderGeometry::UIntList |
typedef std::vector<Edge> osgShadow::OccluderGeometry::EdgeList [protected] |
| osgShadow::OccluderGeometry::OccluderGeometry | ( | ) |
| osgShadow::OccluderGeometry::OccluderGeometry | ( | const OccluderGeometry & | oc, | |
| const osg::CopyOp & | copyop = osg::CopyOp::SHALLOW_COPY | |||
| ) |
| virtual osgShadow::OccluderGeometry::~OccluderGeometry | ( | ) | [inline, protected, virtual] |
| virtual Object* osgShadow::OccluderGeometry::cloneType | ( | ) | const [inline, virtual] |
Clone the type of an object, with Object* return type.
Must be defined by derived classes.
Implements osg::Object.
| virtual Object* osgShadow::OccluderGeometry::clone | ( | const osg::CopyOp & | ) | const [inline, virtual] |
Clone an object, with Object* return type.
Must be defined by derived classes.
Implements osg::Object.
| virtual bool osgShadow::OccluderGeometry::isSameKindAs | ( | const osg::Object * | obj | ) | const [inline, virtual] |
Reimplemented from osg::Drawable.
| virtual const char* osgShadow::OccluderGeometry::libraryName | ( | ) | const [inline, virtual] |
return the name of the object's library.
Must be defined by derived classes. The OpenSceneGraph convention is that the namespace of a library is the same as the library name.
Reimplemented from osg::Drawable.
| virtual const char* osgShadow::OccluderGeometry::className | ( | ) | const [inline, virtual] |
return the name of the object's class type.
Must be defined by derived classes.
Reimplemented from osg::Drawable.
| void osgShadow::OccluderGeometry::computeOccluderGeometry | ( | osg::Node * | subgraph, | |
| osg::Matrix * | matrix = 0, |
|||
| float | sampleRatio = 1.0f | |||
| ) |
Compute an occluder geometry containing all the geometry in specified subgraph.
| void osgShadow::OccluderGeometry::computeOccluderGeometry | ( | osg::Drawable * | drawable, | |
| osg::Matrix * | matrix = 0, |
|||
| float | sampleRatio = 1.0f | |||
| ) |
Compute an occluder geometry containing the geometry in specified drawable.
| void osgShadow::OccluderGeometry::computeShadowVolumeGeometry | ( | const osg::Vec4 & | lightpos, | |
| ShadowVolumeGeometry & | svg | |||
| ) | const |
Compute ShadowVolumeGeometry.
| void osgShadow::OccluderGeometry::setBoundingPolytope | ( | const osg::Polytope & | polytope | ) | [inline] |
Set the bounding polytope of the OccluderGeometry.
| osg::Polytope& osgShadow::OccluderGeometry::getBoundingPolytope | ( | ) | [inline] |
Get the bounding polytope of the OccluderGeometry.
| const osg::Polytope& osgShadow::OccluderGeometry::getBoundingPolytope | ( | ) | const [inline] |
Get the const bounding polytope of the OccluderGeometry.
| virtual void osgShadow::OccluderGeometry::drawImplementation | ( | osg::RenderInfo & | renderInfo | ) | const [virtual] |
| virtual osg::BoundingBox osgShadow::OccluderGeometry::computeBound | ( | ) | const [virtual] |
| void osgShadow::OccluderGeometry::processGeometry | ( | osg::Drawable * | drawable, | |
| osg::Matrix * | matrix = 0, |
|||
| float | sampleRatio = 1.0f | |||
| ) |
| bool osgShadow::OccluderGeometry::isLightPointSilhouetteEdge | ( | const osg::Vec3 & | lightpos, | |
| const Edge & | edge | |||
| ) | const [inline, protected] |
| bool osgShadow::OccluderGeometry::isLightDirectionSilhouetteEdge | ( | const osg::Vec3 & | lightdirection, | |
| const Edge & | edge | |||
| ) | const [inline, protected] |
| void osgShadow::OccluderGeometry::setUpInternalStructures | ( | ) | [protected] |
| void osgShadow::OccluderGeometry::removeDuplicateVertices | ( | ) | [protected] |
| void osgShadow::OccluderGeometry::removeNullTriangles | ( | ) | [protected] |
| void osgShadow::OccluderGeometry::computeNormals | ( | ) | [protected] |
| void osgShadow::OccluderGeometry::buildEdgeMaps | ( | ) | [protected] |
| void osgShadow::OccluderGeometry::computeLightDirectionSilhouetteEdges | ( | const osg::Vec3 & | lightdirection, | |
| UIntList & | silhouetteIndices | |||
| ) | const [protected] |
| void osgShadow::OccluderGeometry::computeLightPositionSilhouetteEdges | ( | const osg::Vec3 & | lightpos, | |
| UIntList & | silhouetteIndices | |||
| ) | const [protected] |
Vec3List osgShadow::OccluderGeometry::_vertices [protected] |
Vec3List osgShadow::OccluderGeometry::_normals [protected] |
EdgeList osgShadow::OccluderGeometry::_edges [protected] |