Introduced usage of OSG_GLES*_AVAILABLE macros to headers and .cpp's to enable building against OpenGL ES 1.x and 2.x headers

This commit is contained in:
Robert Osfield
2009-10-25 11:52:01 +00:00
parent 488d108ae0
commit 37ee16403a
37 changed files with 538 additions and 209 deletions

View File

@@ -85,14 +85,22 @@ class OSG_EXPORT ArrayDispatchers : public osg::Referenced
void Begin(GLenum mode)
{
#ifdef OSG_GL1_AVAILABLE
if (_useGLBeginEndAdapter) _glBeginEndAdapter->Begin(mode);
else ::glBegin(mode);
#else
_glBeginEndAdapter->Begin(mode);
#endif
}
void End()
{
#ifdef OSG_GL1_AVAILABLE
if (_useGLBeginEndAdapter) _glBeginEndAdapter->End();
else ::glEnd();
#else
_glBeginEndAdapter->End();
#endif
}
protected: