diff options
author | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-07 23:35:31 +0000 |
---|---|---|
committer | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-07 23:35:31 +0000 |
commit | 9e64440a70e0a18ff5b6edcbf10652feb2954b39 (patch) | |
tree | c2012f5a29786e7dfd2cdd638bc7f0c1e6da2083 /gpu/GLES2 | |
parent | 891ca0f165421a6d748df275058832d2e9ebecab (diff) | |
download | chromium_src-9e64440a70e0a18ff5b6edcbf10652feb2954b39.zip chromium_src-9e64440a70e0a18ff5b6edcbf10652feb2954b39.tar.gz chromium_src-9e64440a70e0a18ff5b6edcbf10652feb2954b39.tar.bz2 |
This CL adds the option to support buffers that are bound
to more than one target.
We had originally decided that this would be an disallowed.
glBindBuffer(GL_ARRAY_BUFFER, some_buffer_id);
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, some_buffer_id);
Unfortunately the GLES2 conformance tests require this
behavior.
This CL makes this behavior possible but it has to be
turned on because it means all buffers have to have CPU
side backing (not just ELEMENT_ARRAY_BUFFERs) and it
means a slowdown for dynamic vertex related stuff
like skinning because an extra copy has to be made
every time they are updated.
So, by default it will be off but we'll come up with
some way to turn it on. Al's suggestion is to use
eglCreateContext with a custom intialization attribute.
My #1 question: What about the name of the command,
the name of the constant and the filename the constant
is in. Any thoughts?
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/1992008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46756 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/GLES2')
-rw-r--r-- | gpu/GLES2/gles2_command_buffer.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/gpu/GLES2/gles2_command_buffer.h b/gpu/GLES2/gles2_command_buffer.h new file mode 100644 index 0000000..137cd78 --- /dev/null +++ b/gpu/GLES2/gles2_command_buffer.h @@ -0,0 +1,18 @@ +// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// This file defines constants and functions for the Pepper gles2 command +// buffers that fall outside the scope of OpenGL ES 2.0 + +#ifndef GPU_GLES2_GLES2_COMMAND_BUFFER_H_ +#define GPU_GLES2_GLES2_COMMAND_BUFFER_H_ + +// constants for CommandBufferEnable command. +#define GLES2_ALLOW_BUFFERS_ON_MULTIPLE_TARGETS 0x0001 + +#endif // GPU_GLES2_GLES2_COMMAND_BUFFER_H_ + + + + |