Split the floating point texture queries into individual methods and mark all support methods as const.
TRAC #22972
Signed-off-by: Jamie Madill
Signed-off-by: Nicolas Capens
Author: Geoff Lang
git-svn-id: https://angleproject.googlecode.com/svn/branches/es3proto@2312 736b8ea6-26fd-11df-bfd4-992fa37f6226
diff --git a/src/libGLESv2/Texture.cpp b/src/libGLESv2/Texture.cpp
index 127fdbc..f580127 100644
--- a/src/libGLESv2/Texture.cpp
+++ b/src/libGLESv2/Texture.cpp
@@ -628,10 +628,9 @@
}
bool mipmapping = isMipmapFiltered();
- bool filtering, renderable;
- if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
- (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
+ if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport()) ||
+ (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport()))
{
if (mSamplerState.magFilter != GL_NEAREST ||
(mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))
@@ -1075,10 +1074,9 @@
int size = mImageArray[0][0]->getWidth();
bool mipmapping = isMipmapFiltered();
- bool filtering, renderable;
- if ((gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0)) == GL_FLOAT && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
- (gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0) == GL_HALF_FLOAT_OES) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
+ if ((gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0)) == GL_FLOAT && !mRenderer->getFloat32TextureSupport()) ||
+ (gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0) == GL_HALF_FLOAT_OES) && !mRenderer->getFloat16TextureSupport()))
{
if (mSamplerState.magFilter != GL_NEAREST ||
(mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))
@@ -1741,10 +1739,9 @@
}
bool mipmapping = isMipmapFiltered();
- bool filtering, renderable;
- if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
- (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
+ if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport()) ||
+ (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport()))
{
if (mSamplerState.magFilter != GL_NEAREST ||
(mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))
@@ -2231,10 +2228,9 @@
}
bool mipmapping = isMipmapFiltered();
- bool filtering, renderable;
- if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
- (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
+ if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport()) ||
+ (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport()))
{
if (mSamplerState.magFilter != GL_NEAREST ||
(mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))