diff options
author | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-27 00:48:03 +0000 |
---|---|---|
committer | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-27 00:48:03 +0000 |
commit | ae51d195b0e1bfaba2243f005a1aba675395595f (patch) | |
tree | d6990cd30404b49ad0b01db2126f971b601a94d6 /gpu/command_buffer/service/buffer_manager.h | |
parent | 4b3540935a9769fb1634483027b70ee763ee431e (diff) | |
download | chromium_src-ae51d195b0e1bfaba2243f005a1aba675395595f.zip chromium_src-ae51d195b0e1bfaba2243f005a1aba675395595f.tar.gz chromium_src-ae51d195b0e1bfaba2243f005a1aba675395595f.tar.bz2 |
Changes the code to use separate ids namspaces
for buffers, textures, programs, etc.. This is
needed to pass GLES2 conformance tests.
TEST=old unit tests
BUG=none
Review URL: http://codereview.chromium.org/1747013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45654 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/command_buffer/service/buffer_manager.h')
-rw-r--r-- | gpu/command_buffer/service/buffer_manager.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/gpu/command_buffer/service/buffer_manager.h b/gpu/command_buffer/service/buffer_manager.h index c77b5df..7eefd52 100644 --- a/gpu/command_buffer/service/buffer_manager.h +++ b/gpu/command_buffer/service/buffer_manager.h @@ -27,14 +27,14 @@ class BufferManager { public: typedef scoped_refptr<BufferInfo> Ref; - explicit BufferInfo(GLuint buffer_id) - : buffer_id_(buffer_id), + explicit BufferInfo(GLuint service_id) + : service_id_(service_id), target_(0), size_(0) { } - GLuint buffer_id() const { - return buffer_id_; + GLuint service_id() const { + return service_id_; } GLenum target() const { @@ -65,7 +65,7 @@ class BufferManager { GLuint* max_value); bool IsDeleted() { - return buffer_id_ == 0; + return service_id_ == 0; } private: @@ -103,7 +103,7 @@ class BufferManager { ~BufferInfo() { } void MarkAsDeleted() { - buffer_id_ = 0; + service_id_ = 0; shadow_.reset(); ClearCache(); } @@ -112,7 +112,7 @@ class BufferManager { void ClearCache(); // Service side buffer id. - GLuint buffer_id_; + GLuint service_id_; // The type of buffer. 0 = unset, GL_BUFFER_ARRAY = vertex data, // GL_ELEMENT_BUFFER_ARRAY = index data. @@ -134,13 +134,13 @@ class BufferManager { BufferManager() { } // Creates a BufferInfo for the given buffer. - void CreateBufferInfo(GLuint buffer_id); + void CreateBufferInfo(GLuint client_id, GLuint service_id); // Gets the buffer info for the given buffer. - BufferInfo* GetBufferInfo(GLuint buffer_id); + BufferInfo* GetBufferInfo(GLuint client_id); // Removes a buffer info for the given buffer. - void RemoveBufferInfo(GLuint buffer_id); + void RemoveBufferInfo(GLuint client_id); private: // Info for each buffer in the system. |