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

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

Issue 14456004: GPU client side changes for GpuMemoryBuffers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@glapi
Patch Set: Uploading again Created 7 years, 8 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/client/gles2_implementation.h
diff --git a/gpu/command_buffer/client/gles2_implementation.h b/gpu/command_buffer/client/gles2_implementation.h
index e176c8b20a2ca761346d004833caa93ba7ccc452..1d66151b3e52d0efefb6ac048336e7a6686a41b9 100644
--- a/gpu/command_buffer/client/gles2_implementation.h
+++ b/gpu/command_buffer/client/gles2_implementation.h
@@ -102,6 +102,7 @@ class TransferBufferInterface;
namespace gles2 {
+class GpuMemoryBufferTracker;
class VertexArrayObjectManager;
// This class emulates GLES2 over command buffers. It can be used by a client
@@ -435,6 +436,10 @@ class GLES2_IMPL_EXPORT GLES2Implementation : public GLES2Interface {
GLenum target, GLintptr offset, GLsizeiptr size, const void* data,
ScopedTransferBufferPtr* buffer);
+ // Helper for ImageBufferData
+ void ImageBufferDataCHROMIUMHelper(
+ GLenum target, GLsizei width, GLsizei height);
+
// Helper for GetVertexAttrib
bool GetVertexAttribHelper(GLuint index, GLenum pname, uint32* param);
@@ -498,6 +503,10 @@ class GLES2_IMPL_EXPORT GLES2Implementation : public GLES2Interface {
void FailGLError(GLenum /* error */) { }
#endif
+ bool GetBoundGpuMemoryBuffer(const char* function_name, GLuint* buffer_id);
+ void* GetNativeHandleForBoundGpuMemoryBuffer();
+ bool GetPointervCHROMIUMHelper(GLenum pname, GLvoid** pointer);
greggman 2013/04/29 19:58:33 confused. Your last comment said you didn't need G
kaanb 2013/04/30 03:40:10 Removed.
+
GLES2Util util_;
GLES2CmdHelper* helper_;
TransferBufferInterface* transfer_buffer_;
@@ -554,6 +563,9 @@ class GLES2_IMPL_EXPORT GLES2Implementation : public GLES2Interface {
GLuint bound_pixel_pack_transfer_buffer_id_;
GLuint bound_pixel_unpack_transfer_buffer_id_;
+ // The currently bound GPU memory buffer
+ GLuint bound_gpu_memory_buffer_id_;
+
// Client side management for vertex array objects. Needed to correctly
// track client side arrays.
scoped_ptr<VertexArrayObjectManager> vertex_array_object_manager_;
@@ -600,6 +612,8 @@ class GLES2_IMPL_EXPORT GLES2Implementation : public GLES2Interface {
scoped_ptr<BufferTracker> buffer_tracker_;
+ scoped_ptr<GpuMemoryBufferTracker> gpu_memory_buffer_tracker_;
+
ErrorMessageCallback* error_message_callback_;
scoped_ptr<std::string> current_trace_name_;

Powered by Google App Engine
This is Rietveld 408576698