Commit be042f19 by Geoff Lang Committed by Commit Bot

Mark RGB HALF_FLOAT_OES as renderable with EXT_color_buffer_half_float and WebGL

The EXT_color_buffer_half_float spec states: If OES_texture_half_float is supported, textures created with: <internalformat> = RGBA <format> = RGBA <type> = HALF_FLOAT_OES are renderable. But WebGL content relies on being able to render to both RGB and RGBA unsized HALF_FLOAT_OES textures. Framebuffers may still return unsupported for this format. BUG=941671 Change-Id: I42d909d26508b9cdf7cda6d1dc025b0e2ed87732 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1523530Reviewed-by: 's avatarYuly Novikov <ynovikov@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org> (cherry picked from commit 979f3bbe) Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1539261Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org>
parent 96ab4909
...@@ -199,7 +199,14 @@ void main() ...@@ -199,7 +199,14 @@ void main()
return; return;
} }
ASSERT_GLENUM_EQ(GL_FRAMEBUFFER_COMPLETE, glCheckFramebufferStatus(GL_FRAMEBUFFER)); GLenum framebufferStatus = glCheckFramebufferStatus(GL_FRAMEBUFFER);
if (framebufferStatus == GL_FRAMEBUFFER_UNSUPPORTED)
{
std::cout << "Framebuffer returned GL_FRAMEBUFFER_UNSUPPORTED, this is legal."
<< std::endl;
return;
}
ASSERT_GLENUM_EQ(GL_FRAMEBUFFER_COMPLETE, framebufferStatus);
ANGLE_GL_PROGRAM(renderingProgram, essl1_shaders::vs::Simple(), ANGLE_GL_PROGRAM(renderingProgram, essl1_shaders::vs::Simple(),
essl1_shaders::fs::UniformColor()); essl1_shaders::fs::UniformColor());
...@@ -3263,7 +3270,9 @@ TEST_P(WebGLCompatibilityTest, RGB16FTextures) ...@@ -3263,7 +3270,9 @@ TEST_P(WebGLCompatibilityTest, RGB16FTextures)
{ {
bool texture = extensionEnabled("GL_OES_texture_half_float"); bool texture = extensionEnabled("GL_OES_texture_half_float");
bool filter = extensionEnabled("GL_OES_texture_half_float_linear"); bool filter = extensionEnabled("GL_OES_texture_half_float_linear");
bool render = false; // WebGL says that Unsized RGB 16F (OES) can be renderable with
// GL_EXT_color_buffer_half_float.
bool render = extensionEnabled("GL_EXT_color_buffer_half_float");
TestFloatTextureFormat(GL_RGB, GL_RGB, GL_HALF_FLOAT_OES, texture, filter, render, TestFloatTextureFormat(GL_RGB, GL_RGB, GL_HALF_FLOAT_OES, texture, filter, render,
textureData, readPixelsData); textureData, readPixelsData);
} }
......
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