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

Side by Side Diff: gpu/command_buffer/common/gles2_cmd_format.h

Issue 549201: Implements glGetVertexAttribPointerv (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 10 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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 // This file defines the GLES2 command buffer commands. 5 // This file defines the GLES2 command buffer commands.
6 6
7 #ifndef GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_ 7 #ifndef GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_
8 #define GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_ 8 #define GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_
9 9
10 // This is here because service side code must include the system's version of 10 // This is here because service side code must include the system's version of
(...skipping 14 matching lines...) Expand all
25 #include "gpu/command_buffer/common/types.h" 25 #include "gpu/command_buffer/common/types.h"
26 #include "gpu/command_buffer/common/bitfield_helpers.h" 26 #include "gpu/command_buffer/common/bitfield_helpers.h"
27 #include "gpu/command_buffer/common/cmd_buffer_common.h" 27 #include "gpu/command_buffer/common/cmd_buffer_common.h"
28 #include "gpu/command_buffer/common/gles2_cmd_ids.h" 28 #include "gpu/command_buffer/common/gles2_cmd_ids.h"
29 29
30 namespace gpu { 30 namespace gpu {
31 namespace gles2 { 31 namespace gles2 {
32 32
33 #pragma pack(push, 1) 33 #pragma pack(push, 1)
34 34
35 // Used for some glGetXXX commands that return a result through a pointer. We
36 // need to know if the command succeeded or not and the size of the result. If
37 // the command failed its result size will 0.
38 struct SizedResult {
39 template <typename T>
40 T GetDataAs() {
41 return static_cast<T>(static_cast<void*>(&data));
42 }
43 uint32 size; // in bytes.
44 int32 data; // this is just here to get an offset.
45 };
46
35 #include "gpu/command_buffer/common/gles2_cmd_format_autogen.h" 47 #include "gpu/command_buffer/common/gles2_cmd_format_autogen.h"
36 48
37 // These are hand written commands. 49 // These are hand written commands.
38 // TODO(gman): Attempt to make these auto-generated. 50 // TODO(gman): Attempt to make these auto-generated.
39 51
40 struct GetAttribLocation { 52 struct GetAttribLocation {
41 typedef GetAttribLocation ValueType; 53 typedef GetAttribLocation ValueType;
42 static const CommandId kCmdId = kGetAttribLocation; 54 static const CommandId kCmdId = kGetAttribLocation;
43 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 55 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
44 56
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
278 COMPILE_ASSERT(offsetof(GetUniformLocationImmediate, data_size) == 16, 290 COMPILE_ASSERT(offsetof(GetUniformLocationImmediate, data_size) == 16,
279 OffsetOf_GetUniformLocationImmediate_data_size_not_16); 291 OffsetOf_GetUniformLocationImmediate_data_size_not_16);
280 292
281 #pragma pack(pop) 293 #pragma pack(pop)
282 294
283 } // namespace gles2 295 } // namespace gles2
284 } // namespace gpu 296 } // namespace gpu
285 297
286 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_ 298 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_H_
287 299
OLDNEW
« no previous file with comments | « gpu/command_buffer/client/gles2_implementation_gen.h ('k') | gpu/command_buffer/service/gles2_cmd_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698