diff options
author | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-29 04:21:36 +0000 |
---|---|---|
committer | gman@chromium.org <gman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-29 04:21:36 +0000 |
commit | 8bf5a3eff3ae66eb2f4dae5feb1ae58dd240b4f3 (patch) | |
tree | 71919c02268fd8a8d462cccd5d3f211c3da57d81 /gpu/command_buffer/common/gles2_cmd_format.h | |
parent | a8125d2a01d5d1f12f6dc23881b457804c904509 (diff) | |
download | chromium_src-8bf5a3eff3ae66eb2f4dae5feb1ae58dd240b4f3.zip chromium_src-8bf5a3eff3ae66eb2f4dae5feb1ae58dd240b4f3.tar.gz chromium_src-8bf5a3eff3ae66eb2f4dae5feb1ae58dd240b4f3.tar.bz2 |
Implements glGetVertexAttribPointerv
TEST=none
BUG=none
Review URL: http://codereview.chromium.org/549201
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37496 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu/command_buffer/common/gles2_cmd_format.h')
-rw-r--r-- | gpu/command_buffer/common/gles2_cmd_format.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/gpu/command_buffer/common/gles2_cmd_format.h b/gpu/command_buffer/common/gles2_cmd_format.h index 931b709..7598318 100644 --- a/gpu/command_buffer/common/gles2_cmd_format.h +++ b/gpu/command_buffer/common/gles2_cmd_format.h @@ -32,6 +32,18 @@ namespace gles2 { #pragma pack(push, 1) +// Used for some glGetXXX commands that return a result through a pointer. We +// need to know if the command succeeded or not and the size of the result. If +// the command failed its result size will 0. +struct SizedResult { + template <typename T> + T GetDataAs() { + return static_cast<T>(static_cast<void*>(&data)); + } + uint32 size; // in bytes. + int32 data; // this is just here to get an offset. +}; + #include "gpu/command_buffer/common/gles2_cmd_format_autogen.h" // These are hand written commands. |