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

Unified Diff: webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc

Issue 7669002: Introduction of parameter to readBackFramebuffer set of APIs to allow reading from the currently ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 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: webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc
===================================================================
--- webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc (revision 96380)
+++ webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.cc (working copy)
@@ -843,7 +843,7 @@
if (mustRestoreFBO) {
gl_->BindFramebuffer(GL_FRAMEBUFFER, framebuffer);
}
- gl_->ReadPixels(0, 0, width, height,
+ gl_->ReadPixels(0, 0, width, height,
GL_RGBA, GL_UNSIGNED_BYTE, pixels);
// Swizzle red and blue channels
@@ -867,8 +867,11 @@
bool WebGraphicsContext3DInProcessCommandBufferImpl::readBackFramebuffer(
unsigned char* pixels,
- size_t buffer_size) {
- return readBackFramebuffer(pixels, buffer_size, 0, width(), height());
+ size_t buffer_size, bool bindDefaultBackbuffer) {
+ if (bindDefaultBackbuffer)
+ return readBackFramebuffer(pixels, buffer_size, 0, width(), height());
+
+ return readBackFramebuffer(pixels, buffer_size, bound_fbo_, width(), height());
}
void WebGraphicsContext3DInProcessCommandBufferImpl::synthesizeGLError(
« no previous file with comments | « webkit/gpu/webgraphicscontext3d_in_process_command_buffer_impl.h ('k') | webkit/gpu/webgraphicscontext3d_in_process_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698