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

Unified Diff: gpu/command_buffer/client/gles2_implementation.cc

Issue 1320093002: Command Buffer: read pixels into pixel pack buffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more unittests Created 5 years 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/client/gles2_implementation.cc
diff --git a/gpu/command_buffer/client/gles2_implementation.cc b/gpu/command_buffer/client/gles2_implementation.cc
index 208a08bd0e05b07209f37756baed96f702ae79b7..c2add507ad49919aa1c4ae52bc868fcac9ac9dcc 100644
--- a/gpu/command_buffer/client/gles2_implementation.cc
+++ b/gpu/command_buffer/client/gles2_implementation.cc
@@ -3485,10 +3485,10 @@ void GLES2Implementation::ReadPixels(
}
if (bound_pixel_pack_buffer_) {
- // TODO(zmo): Need to handle the case of reading into a PIXEL_PACK_BUFFER
- // in ES3. For now, generate a GL error.
- SetGLError(GL_INVALID_OPERATION, "glReadPixels",
- "ReadPixels to a pixel pack buffer isn't implemented");
+ GLuint offset = ToGLuint(pixels);
+ helper_->ReadPixels(
+ xoffset, yoffset, width, height, format, type, 0, offset, 0, 0, false);
+ CheckGLError();
return;
}
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder.cc » ('j') | gpu/command_buffer/service/gles2_cmd_decoder.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698