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

Side by Side Diff: content/renderer/gpu/webgraphicscontext3d_command_buffer_impl.h

Issue 7566046: Add WebGraphicsContext support for readbacks from any framebuffer. (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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 5 #ifndef CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
6 #define CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 6 #define CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
7 #pragma once 7 #pragma once
8 8
9 #if defined(ENABLE_GPU) 9 #if defined(ENABLE_GPU)
10 10
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 virtual int width(); 62 virtual int width();
63 virtual int height(); 63 virtual int height();
64 64
65 virtual bool isGLES2Compliant(); 65 virtual bool isGLES2Compliant();
66 66
67 virtual bool setParentContext(WebGraphicsContext3D* parent_context); 67 virtual bool setParentContext(WebGraphicsContext3D* parent_context);
68 68
69 virtual void reshape(int width, int height); 69 virtual void reshape(int width, int height);
70 70
71 virtual bool readBackFramebuffer(unsigned char* pixels, size_t buffer_size); 71 virtual bool readBackFramebuffer(unsigned char* pixels, size_t buffer_size);
72 virtual bool readBackFramebuffer(unsigned char* pixels, int width, int height,
73 size_t buffer_size, WebGLId framebuffer);
Ken Russell (switch to Gerrit) 2011/08/04 22:55:07 I would have organized these arguments differently
jbauman 2011/08/04 23:20:21 Yeah, I guess that organization makes more sense.
72 74
73 virtual WebGLId getPlatformTextureId(); 75 virtual WebGLId getPlatformTextureId();
74 virtual void prepareTexture(); 76 virtual void prepareTexture();
75 77
76 virtual void activeTexture(WGC3Denum texture); 78 virtual void activeTexture(WGC3Denum texture);
77 virtual void attachShader(WebGLId program, WebGLId shader); 79 virtual void attachShader(WebGLId program, WebGLId shader);
78 virtual void bindAttribLocation(WebGLId program, WGC3Duint index, 80 virtual void bindAttribLocation(WebGLId program, WGC3Duint index,
79 const WGC3Dchar* name); 81 const WGC3Dchar* name);
80 virtual void bindBuffer(WGC3Denum target, WebGLId buffer); 82 virtual void bindBuffer(WGC3Denum target, WebGLId buffer);
81 virtual void bindFramebuffer(WGC3Denum target, WebGLId framebuffer); 83 virtual void bindFramebuffer(WGC3Denum target, WebGLId framebuffer);
(...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
462 #ifdef FLIP_FRAMEBUFFER_VERTICALLY 464 #ifdef FLIP_FRAMEBUFFER_VERTICALLY
463 scoped_array<uint8> scanline_; 465 scoped_array<uint8> scanline_;
464 void FlipVertically(uint8* framebuffer, 466 void FlipVertically(uint8* framebuffer,
465 unsigned int width, 467 unsigned int width,
466 unsigned int height); 468 unsigned int height);
467 #endif 469 #endif
468 }; 470 };
469 471
470 #endif // defined(ENABLE_GPU) 472 #endif // defined(ENABLE_GPU)
471 #endif // CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_ 473 #endif // CONTENT_RENDERER_GPU_WEBGRAPHICSCONTEXT3D_COMMAND_BUFFER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698