Added support for per primitive bindings in osg::IndexedGeometry. Added a
convertToIndexedGeometry() method to GeoSet to allow datasets with per primitive bindings to be be mapped to across to osg::IndexedGeometry for testing purposes.
This commit is contained in:
@@ -15,6 +15,7 @@ namespace osg {
|
||||
|
||||
// forward declare so that we don't need to include the header.
|
||||
class Geometry;
|
||||
class IndexedGeometry;
|
||||
|
||||
/** Note, osg::GeoSet is now deprecated, please use osg::Geometry instead.
|
||||
osg::GeoSet will be kept through to the beta release for
|
||||
@@ -338,6 +339,8 @@ class SG_EXPORT GeoSet : public Drawable
|
||||
/** convinience function for converting GeoSet's to equivilant Geometry nodes.*/
|
||||
Geometry* convertToGeometry();
|
||||
|
||||
/** convinience function for converting GeoSet's to equivilant IndexedGeometry nodes.*/
|
||||
IndexedGeometry* convertToIndexedGeometry();
|
||||
|
||||
protected:
|
||||
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
//Distributed under the terms of the GNU Library General Public License (LGPL)
|
||||
//as published by the Free Software Foundation.
|
||||
|
||||
#ifndef OSG_GEOMETRY
|
||||
#define OSG_GEOMETRY 1
|
||||
#ifndef OSG_INDEXEDGEOMETRY
|
||||
#define OSG_INDEXEDGEOMETRY 1
|
||||
|
||||
#include <osg/Drawable>
|
||||
#include <osg/Vec2>
|
||||
@@ -109,7 +109,7 @@ class SG_EXPORT IndexedGeometry : public Drawable
|
||||
Array* getTexCoordArray(unsigned int unit);
|
||||
const Array* getTexCoordArray(unsigned int unit) const;
|
||||
|
||||
void setTexCoordIndices(unsigned int unit,Array*);
|
||||
void setTexCoordIndices(unsigned int unit,IndexArray*);
|
||||
IndexArray* getTexCoordIndices(unsigned int unit);
|
||||
const IndexArray* getTexCoordIndices(unsigned int unit) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user