Commit 2f113e3e by Alexis Hetu Committed by Alexis Hétu

GL_CHROMIUM_color_buffer_float_rgba extension support

GL_CHROMIUM_color_buffer_float_rgba (OpenGL ES 2.0) is a subset of GL_EXT_color_buffer_float (OpenGL ES 3.0), which SwiftShader already supports. Fixes 1 webgl conformance tests: conformance/extensions/oes-texture-float.html Change-Id: Ic1451187db219af74ba41fa7634bd5bcb6fb0b44 Reviewed-on: https://swiftshader-review.googlesource.com/16470Tested-by: 's avatarAlexis Hétu <sugoi@google.com> Reviewed-by: 's avatarNicolas Capens <nicolascapens@google.com>
parent f9b80fe1
...@@ -4400,6 +4400,7 @@ const GLubyte *Context::getExtensions(GLuint index, GLuint *numExt) const ...@@ -4400,6 +4400,7 @@ const GLubyte *Context::getExtensions(GLuint index, GLuint *numExt) const
"GL_ANGLE_texture_compression_dxt3", "GL_ANGLE_texture_compression_dxt3",
"GL_ANGLE_texture_compression_dxt5", "GL_ANGLE_texture_compression_dxt5",
"GL_APPLE_texture_format_BGRA8888", "GL_APPLE_texture_format_BGRA8888",
"GL_CHROMIUM_color_buffer_float_rgba", // A subset of EXT_color_buffer_float on top of OpenGL ES 2.0
"GL_CHROMIUM_texture_filtering_hint", "GL_CHROMIUM_texture_filtering_hint",
"GL_NV_fence", "GL_NV_fence",
"GL_NV_framebuffer_blit", "GL_NV_framebuffer_blit",
......
...@@ -4964,7 +4964,8 @@ void TexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, ...@@ -4964,7 +4964,8 @@ void TexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width,
GLint clientVersion = context->getClientVersion(); GLint clientVersion = context->getClientVersion();
if(clientVersion < 3) if(clientVersion < 3)
{ {
if(internalformat != (GLint)format) if((internalformat != (GLint)format) &&
!((type == GL_FLOAT) && (format == GL_RGBA) && (internalformat == GL_RGBA32F))) // CHROMIUM_color_buffer_float_rgba
{ {
return error(GL_INVALID_OPERATION); return error(GL_INVALID_OPERATION);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment