Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(237)

Unified Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 1308313008: Fix ReadPixels implementation specific read format/type on desktop GL. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clear
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/service/gles2_cmd_decoder.cc
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder.cc b/gpu/command_buffer/service/gles2_cmd_decoder.cc
index 03f87167a04d297bb1826612e44f9736efba132d..3c9f6040e94c21ab4d7296843e15392c45a81d7b 100644
--- a/gpu/command_buffer/service/gles2_cmd_decoder.cc
+++ b/gpu/command_buffer/service/gles2_cmd_decoder.cc
@@ -8752,9 +8752,6 @@ error::Error GLES2DecoderImpl::HandleReadPixels(uint32 immediate_data_size,
std::vector<GLenum> accepted_formats;
std::vector<GLenum> accepted_types;
switch (src_internal_format) {
- case GL_RGB10_A2UI:
- accepted_formats.push_back(GL_RGBA);
- accepted_types.push_back(GL_UNSIGNED_INT_2_10_10_10_REV);
case GL_R8UI:
case GL_R16UI:
case GL_R32UI:
@@ -8763,6 +8760,7 @@ error::Error GLES2DecoderImpl::HandleReadPixels(uint32 immediate_data_size,
case GL_RG32UI:
// All the RGB_INTEGER formats are not renderable.
case GL_RGBA8UI:
+ case GL_RGB10_A2UI:
case GL_RGBA16UI:
case GL_RGBA32UI:
accepted_formats.push_back(GL_RGBA_INTEGER);
@@ -8780,6 +8778,9 @@ error::Error GLES2DecoderImpl::HandleReadPixels(uint32 immediate_data_size,
accepted_formats.push_back(GL_RGBA_INTEGER);
accepted_types.push_back(GL_INT);
break;
+ case GL_RGB10_A2:
+ accepted_formats.push_back(GL_RGBA);
+ accepted_types.push_back(GL_UNSIGNED_INT_2_10_10_10_REV);
default:
accepted_formats.push_back(GL_RGBA);
{

Powered by Google App Engine
This is Rietveld 408576698