Moved local Extensions structs into GL2Extensions
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14584 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
@@ -87,59 +87,6 @@ class OSG_EXPORT Point : public StateAttribute
|
||||
|
||||
virtual void apply(State& state) const;
|
||||
|
||||
/** Encapsulates queries of extension availability, obtains extension
|
||||
* function pointers, and provides convenience wrappers for
|
||||
* calling extension functions. */
|
||||
class OSG_EXPORT Extensions : public osg::Referenced
|
||||
{
|
||||
public:
|
||||
Extensions(unsigned int contextID);
|
||||
|
||||
Extensions(const Extensions& rhs);
|
||||
|
||||
void lowestCommonDenominator(const Extensions& rhs);
|
||||
|
||||
void setupGLExtensions(unsigned int contextID);
|
||||
|
||||
void setPointParametersSupported(bool flag) { _isPointParametersSupported=flag; }
|
||||
bool isPointParametersSupported() const { return _isPointParametersSupported; }
|
||||
|
||||
void setPointSpriteCoordOriginSupported(bool flag) { _isPointSpriteCoordOriginSupported=flag; }
|
||||
bool isPointSpriteCoordOriginSupported() const { return _isPointSpriteCoordOriginSupported; }
|
||||
|
||||
void glPointParameteri(GLenum pname, GLint param) const;
|
||||
void glPointParameterf(GLenum pname, GLfloat param) const;
|
||||
void glPointParameterfv(GLenum pname, const GLfloat *params) const;
|
||||
|
||||
protected:
|
||||
|
||||
~Extensions() {}
|
||||
|
||||
bool _isPointParametersSupported;
|
||||
bool _isPointSpriteCoordOriginSupported;
|
||||
|
||||
typedef void (GL_APIENTRY * GLPointParameteriProc) (GLenum pname, GLint param);
|
||||
typedef void (GL_APIENTRY * GLPointParameterfProc) (GLenum pname, GLfloat param);
|
||||
typedef void (GL_APIENTRY * GLPointParameterfvProc) (GLenum pname, const GLfloat *params);
|
||||
|
||||
GLPointParameteriProc _glPointParameteri;
|
||||
GLPointParameterfProc _glPointParameterf;
|
||||
GLPointParameterfvProc _glPointParameterfv;
|
||||
|
||||
};
|
||||
|
||||
/** Returns the Extensions object for the given context.
|
||||
* If createIfNotInitalized is true and the Extensions object doesn't
|
||||
* exist, getExtensions() creates it on the given context.
|
||||
* Returns NULL if createIfNotInitalized is false and the Extensions
|
||||
* object doesn't exist. */
|
||||
static Extensions* getExtensions(unsigned int contextID,bool createIfNotInitalized);
|
||||
|
||||
/** setExtensions() allows users to override the extensions across graphics contexts.
|
||||
* Typically used when you have different extensions supported across graphics pipes,
|
||||
* but need to ensure that they all use the same low common denominator extensions. */
|
||||
static void setExtensions(unsigned int contextID,Extensions* extensions);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Point();
|
||||
|
||||
Reference in New Issue
Block a user