From Alexander Irion, "Texture borders are not supported in ES.

_isTextureBorderClampSupported is set to "TRUE" in Texture.cpp, because of the version number check (GL VERSION >= 1.3).

This leads to an invalid enum error, when GL_TEXTURE_BORDER_COLOR is tried to set.
"
This commit is contained in:
Robert Osfield
2011-07-22 09:27:41 +00:00
parent 6128300bc5
commit 8d77126e2e

View File

@@ -94,7 +94,7 @@ void Texture::TextureObject::setAllocated(GLint numMipmapLevels,
// Update texture pool size
_set->getParent()->getCurrTexturePoolSize() -= previousSize;
_set->getParent()->getCurrTexturePoolSize() += _profile._size;
}
}
}
}
@@ -2479,7 +2479,9 @@ Texture::Extensions::Extensions(unsigned int contextID)
isGLExtensionOrVersionSupported(contextID,"GL_EXT_texture_edge_clamp", 1.2f) ||
isGLExtensionOrVersionSupported(contextID,"GL_SGIS_texture_edge_clamp", 1.2f);
_isTextureBorderClampSupported = OSG_GL3_FEATURES || isGLExtensionOrVersionSupported(contextID,"GL_ARB_texture_border_clamp", 1.3f);
_isTextureBorderClampSupported = OSG_GL3_FEATURES ||
((OSG_GL1_FEATURES || OSG_GL2_FEATURES) && isGLExtensionOrVersionSupported(contextID,"GL_ARB_texture_border_clamp", 1.3f));
_isGenerateMipMapSupported = builtInSupport || isGLExtensionOrVersionSupported(contextID,"GL_SGIS_generate_mipmap", 1.4f);