diff --git a/include/osg/GL2Extensions b/include/osg/GL2Extensions index d051a30e3..af46e7e73 100644 --- a/include/osg/GL2Extensions +++ b/include/osg/GL2Extensions @@ -552,6 +552,24 @@ typedef char GLchar; #define GL_TIMEOUT_IGNORED 0xFFFFFFFFFFFFFFFFull #endif +#ifndef GL_TEXTURE_2D_ARRAY_EXT + #define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A + #define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A + #define GL_PROXY_TEXTURE_2D_ARRAY_EXT 0x8C1B + #define GL_TEXTURE_BINDING_2D_ARRAY_EXT 0x8C1D + #define GL_MAX_ARRAY_TEXTURE_LAYERS_EXT 0x88FF + #define GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT 0x884E + #define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 + #define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 + #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 +#endif + +#ifndef GL_MAX_3D_TEXTURE_SIZE + #define GL_MAX_3D_TEXTURE_SIZE 0x8073 +#endif + +typedef struct __GLsync *GLsync; + // for compatibility with gl.h headers that don't support VBO, //GL_VERSION_1_5 and GL_ARB_vertex_buffer_object provide these types for OpenGL //all ES versions except GL_OES_VERSION_1_0 provide these types for OpenGL ES diff --git a/include/osg/GraphicsContext b/include/osg/GraphicsContext index 65ea3eae4..894c5d61a 100644 --- a/include/osg/GraphicsContext +++ b/include/osg/GraphicsContext @@ -541,8 +541,6 @@ public: virtual void swapBuffersImplementation(GraphicsContext* gc); - typedef struct __GLsync *GLsync; - GLsync _previousSync; }; diff --git a/include/osg/Texture b/include/osg/Texture index 2e898235d..2513f7ccd 100644 --- a/include/osg/Texture +++ b/include/osg/Texture @@ -188,17 +188,6 @@ #define GL_TEXTURE_3D 0x806F #endif -#ifndef GL_TEXTURE_2D_ARRAY_EXT - #define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A - #define GL_TEXTURE_2D_ARRAY_EXT 0x8C1A - #define GL_PROXY_TEXTURE_2D_ARRAY_EXT 0x8C1B - #define GL_TEXTURE_BINDING_2D_ARRAY_EXT 0x8C1D - #define GL_MAX_ARRAY_TEXTURE_LAYERS_EXT 0x88FF - #define GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT 0x884E - #define GL_SAMPLER_2D_ARRAY_EXT 0x8DC1 - #define GL_SAMPLER_2D_ARRAY_SHADOW_EXT 0x8DC4 - #define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT 0x8CD4 -#endif #ifndef GL_TEXTURE_CUBE_MAP #define GL_TEXTURE_CUBE_MAP 0x8513 diff --git a/include/osg/Texture3D b/include/osg/Texture3D index 391072154..b3d1d5d0a 100644 --- a/include/osg/Texture3D +++ b/include/osg/Texture3D @@ -16,10 +16,6 @@ #include -#ifndef GL_MAX_3D_TEXTURE_SIZE - #define GL_MAX_3D_TEXTURE_SIZE 0x8073 -#endif - namespace osg { /** Encapsulates OpenGL 3D texture functionality. Doesn't support cube maps, diff --git a/src/osg/Texture.cpp b/src/osg/Texture.cpp index b759c35cf..a528095ad 100644 --- a/src/osg/Texture.cpp +++ b/src/osg/Texture.cpp @@ -2695,7 +2695,7 @@ Texture::GenerateMipmapMode Texture::mipmapBeforeTexImage(const State& state, bo #else const GL2Extensions* extensions = state.get(); - bool useGenerateMipMap = extensions->glGenerateMipmap; + bool useGenerateMipMap = extensions->glGenerateMipmap!=0; if (useGenerateMipMap) {