1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // This file is auto-generated from
6 // gpu/command_buffer/build_gles2_cmd_buffer.py
7 // It's formatted by clang-format using chromium coding style:
8 // clang-format -i -style=chromium filename
11 #ifndef GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_
12 #define GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_
14 #define GL_SYNC_FLUSH_COMMANDS_BIT 0x00000001
15 #define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117
17 struct ActiveTexture
{
18 typedef ActiveTexture ValueType
;
19 static const CommandId kCmdId
= kActiveTexture
;
20 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
21 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
23 static uint32_t ComputeSize() {
24 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
27 void SetHeader() { header
.SetCmd
<ValueType
>(); }
29 void Init(GLenum _texture
) {
34 void* Set(void* cmd
, GLenum _texture
) {
35 static_cast<ValueType
*>(cmd
)->Init(_texture
);
36 return NextCmdAddress
<ValueType
>(cmd
);
39 gpu::CommandHeader header
;
43 static_assert(sizeof(ActiveTexture
) == 8, "size of ActiveTexture should be 8");
44 static_assert(offsetof(ActiveTexture
, header
) == 0,
45 "offset of ActiveTexture header should be 0");
46 static_assert(offsetof(ActiveTexture
, texture
) == 4,
47 "offset of ActiveTexture texture should be 4");
50 typedef AttachShader ValueType
;
51 static const CommandId kCmdId
= kAttachShader
;
52 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
53 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
55 static uint32_t ComputeSize() {
56 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
59 void SetHeader() { header
.SetCmd
<ValueType
>(); }
61 void Init(GLuint _program
, GLuint _shader
) {
67 void* Set(void* cmd
, GLuint _program
, GLuint _shader
) {
68 static_cast<ValueType
*>(cmd
)->Init(_program
, _shader
);
69 return NextCmdAddress
<ValueType
>(cmd
);
72 gpu::CommandHeader header
;
77 static_assert(sizeof(AttachShader
) == 12, "size of AttachShader should be 12");
78 static_assert(offsetof(AttachShader
, header
) == 0,
79 "offset of AttachShader header should be 0");
80 static_assert(offsetof(AttachShader
, program
) == 4,
81 "offset of AttachShader program should be 4");
82 static_assert(offsetof(AttachShader
, shader
) == 8,
83 "offset of AttachShader shader should be 8");
85 struct BindAttribLocationBucket
{
86 typedef BindAttribLocationBucket ValueType
;
87 static const CommandId kCmdId
= kBindAttribLocationBucket
;
88 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
89 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
91 static uint32_t ComputeSize() {
92 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
95 void SetHeader() { header
.SetCmd
<ValueType
>(); }
97 void Init(GLuint _program
, GLuint _index
, uint32_t _name_bucket_id
) {
101 name_bucket_id
= _name_bucket_id
;
107 uint32_t _name_bucket_id
) {
108 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _name_bucket_id
);
109 return NextCmdAddress
<ValueType
>(cmd
);
112 gpu::CommandHeader header
;
115 uint32_t name_bucket_id
;
118 static_assert(sizeof(BindAttribLocationBucket
) == 16,
119 "size of BindAttribLocationBucket should be 16");
120 static_assert(offsetof(BindAttribLocationBucket
, header
) == 0,
121 "offset of BindAttribLocationBucket header should be 0");
122 static_assert(offsetof(BindAttribLocationBucket
, program
) == 4,
123 "offset of BindAttribLocationBucket program should be 4");
124 static_assert(offsetof(BindAttribLocationBucket
, index
) == 8,
125 "offset of BindAttribLocationBucket index should be 8");
126 static_assert(offsetof(BindAttribLocationBucket
, name_bucket_id
) == 12,
127 "offset of BindAttribLocationBucket name_bucket_id should be 12");
130 typedef BindBuffer ValueType
;
131 static const CommandId kCmdId
= kBindBuffer
;
132 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
133 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
135 static uint32_t ComputeSize() {
136 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
139 void SetHeader() { header
.SetCmd
<ValueType
>(); }
141 void Init(GLenum _target
, GLuint _buffer
) {
147 void* Set(void* cmd
, GLenum _target
, GLuint _buffer
) {
148 static_cast<ValueType
*>(cmd
)->Init(_target
, _buffer
);
149 return NextCmdAddress
<ValueType
>(cmd
);
152 gpu::CommandHeader header
;
157 static_assert(sizeof(BindBuffer
) == 12, "size of BindBuffer should be 12");
158 static_assert(offsetof(BindBuffer
, header
) == 0,
159 "offset of BindBuffer header should be 0");
160 static_assert(offsetof(BindBuffer
, target
) == 4,
161 "offset of BindBuffer target should be 4");
162 static_assert(offsetof(BindBuffer
, buffer
) == 8,
163 "offset of BindBuffer buffer should be 8");
165 struct BindBufferBase
{
166 typedef BindBufferBase ValueType
;
167 static const CommandId kCmdId
= kBindBufferBase
;
168 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
169 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
171 static uint32_t ComputeSize() {
172 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
175 void SetHeader() { header
.SetCmd
<ValueType
>(); }
177 void Init(GLenum _target
, GLuint _index
, GLuint _buffer
) {
184 void* Set(void* cmd
, GLenum _target
, GLuint _index
, GLuint _buffer
) {
185 static_cast<ValueType
*>(cmd
)->Init(_target
, _index
, _buffer
);
186 return NextCmdAddress
<ValueType
>(cmd
);
189 gpu::CommandHeader header
;
195 static_assert(sizeof(BindBufferBase
) == 16,
196 "size of BindBufferBase should be 16");
197 static_assert(offsetof(BindBufferBase
, header
) == 0,
198 "offset of BindBufferBase header should be 0");
199 static_assert(offsetof(BindBufferBase
, target
) == 4,
200 "offset of BindBufferBase target should be 4");
201 static_assert(offsetof(BindBufferBase
, index
) == 8,
202 "offset of BindBufferBase index should be 8");
203 static_assert(offsetof(BindBufferBase
, buffer
) == 12,
204 "offset of BindBufferBase buffer should be 12");
206 struct BindBufferRange
{
207 typedef BindBufferRange ValueType
;
208 static const CommandId kCmdId
= kBindBufferRange
;
209 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
210 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
212 static uint32_t ComputeSize() {
213 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
216 void SetHeader() { header
.SetCmd
<ValueType
>(); }
218 void Init(GLenum _target
,
237 static_cast<ValueType
*>(cmd
)
238 ->Init(_target
, _index
, _buffer
, _offset
, _size
);
239 return NextCmdAddress
<ValueType
>(cmd
);
242 gpu::CommandHeader header
;
250 static_assert(sizeof(BindBufferRange
) == 24,
251 "size of BindBufferRange should be 24");
252 static_assert(offsetof(BindBufferRange
, header
) == 0,
253 "offset of BindBufferRange header should be 0");
254 static_assert(offsetof(BindBufferRange
, target
) == 4,
255 "offset of BindBufferRange target should be 4");
256 static_assert(offsetof(BindBufferRange
, index
) == 8,
257 "offset of BindBufferRange index should be 8");
258 static_assert(offsetof(BindBufferRange
, buffer
) == 12,
259 "offset of BindBufferRange buffer should be 12");
260 static_assert(offsetof(BindBufferRange
, offset
) == 16,
261 "offset of BindBufferRange offset should be 16");
262 static_assert(offsetof(BindBufferRange
, size
) == 20,
263 "offset of BindBufferRange size should be 20");
265 struct BindFramebuffer
{
266 typedef BindFramebuffer ValueType
;
267 static const CommandId kCmdId
= kBindFramebuffer
;
268 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
269 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
271 static uint32_t ComputeSize() {
272 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
275 void SetHeader() { header
.SetCmd
<ValueType
>(); }
277 void Init(GLenum _target
, GLuint _framebuffer
) {
280 framebuffer
= _framebuffer
;
283 void* Set(void* cmd
, GLenum _target
, GLuint _framebuffer
) {
284 static_cast<ValueType
*>(cmd
)->Init(_target
, _framebuffer
);
285 return NextCmdAddress
<ValueType
>(cmd
);
288 gpu::CommandHeader header
;
290 uint32_t framebuffer
;
293 static_assert(sizeof(BindFramebuffer
) == 12,
294 "size of BindFramebuffer should be 12");
295 static_assert(offsetof(BindFramebuffer
, header
) == 0,
296 "offset of BindFramebuffer header should be 0");
297 static_assert(offsetof(BindFramebuffer
, target
) == 4,
298 "offset of BindFramebuffer target should be 4");
299 static_assert(offsetof(BindFramebuffer
, framebuffer
) == 8,
300 "offset of BindFramebuffer framebuffer should be 8");
302 struct BindRenderbuffer
{
303 typedef BindRenderbuffer ValueType
;
304 static const CommandId kCmdId
= kBindRenderbuffer
;
305 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
306 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
308 static uint32_t ComputeSize() {
309 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
312 void SetHeader() { header
.SetCmd
<ValueType
>(); }
314 void Init(GLenum _target
, GLuint _renderbuffer
) {
317 renderbuffer
= _renderbuffer
;
320 void* Set(void* cmd
, GLenum _target
, GLuint _renderbuffer
) {
321 static_cast<ValueType
*>(cmd
)->Init(_target
, _renderbuffer
);
322 return NextCmdAddress
<ValueType
>(cmd
);
325 gpu::CommandHeader header
;
327 uint32_t renderbuffer
;
330 static_assert(sizeof(BindRenderbuffer
) == 12,
331 "size of BindRenderbuffer should be 12");
332 static_assert(offsetof(BindRenderbuffer
, header
) == 0,
333 "offset of BindRenderbuffer header should be 0");
334 static_assert(offsetof(BindRenderbuffer
, target
) == 4,
335 "offset of BindRenderbuffer target should be 4");
336 static_assert(offsetof(BindRenderbuffer
, renderbuffer
) == 8,
337 "offset of BindRenderbuffer renderbuffer should be 8");
340 typedef BindSampler ValueType
;
341 static const CommandId kCmdId
= kBindSampler
;
342 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
343 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
345 static uint32_t ComputeSize() {
346 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
349 void SetHeader() { header
.SetCmd
<ValueType
>(); }
351 void Init(GLuint _unit
, GLuint _sampler
) {
357 void* Set(void* cmd
, GLuint _unit
, GLuint _sampler
) {
358 static_cast<ValueType
*>(cmd
)->Init(_unit
, _sampler
);
359 return NextCmdAddress
<ValueType
>(cmd
);
362 gpu::CommandHeader header
;
367 static_assert(sizeof(BindSampler
) == 12, "size of BindSampler should be 12");
368 static_assert(offsetof(BindSampler
, header
) == 0,
369 "offset of BindSampler header should be 0");
370 static_assert(offsetof(BindSampler
, unit
) == 4,
371 "offset of BindSampler unit should be 4");
372 static_assert(offsetof(BindSampler
, sampler
) == 8,
373 "offset of BindSampler sampler should be 8");
376 typedef BindTexture ValueType
;
377 static const CommandId kCmdId
= kBindTexture
;
378 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
379 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
381 static uint32_t ComputeSize() {
382 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
385 void SetHeader() { header
.SetCmd
<ValueType
>(); }
387 void Init(GLenum _target
, GLuint _texture
) {
393 void* Set(void* cmd
, GLenum _target
, GLuint _texture
) {
394 static_cast<ValueType
*>(cmd
)->Init(_target
, _texture
);
395 return NextCmdAddress
<ValueType
>(cmd
);
398 gpu::CommandHeader header
;
403 static_assert(sizeof(BindTexture
) == 12, "size of BindTexture should be 12");
404 static_assert(offsetof(BindTexture
, header
) == 0,
405 "offset of BindTexture header should be 0");
406 static_assert(offsetof(BindTexture
, target
) == 4,
407 "offset of BindTexture target should be 4");
408 static_assert(offsetof(BindTexture
, texture
) == 8,
409 "offset of BindTexture texture should be 8");
411 struct BindTransformFeedback
{
412 typedef BindTransformFeedback ValueType
;
413 static const CommandId kCmdId
= kBindTransformFeedback
;
414 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
415 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
417 static uint32_t ComputeSize() {
418 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
421 void SetHeader() { header
.SetCmd
<ValueType
>(); }
423 void Init(GLenum _target
, GLuint _transformfeedback
) {
426 transformfeedback
= _transformfeedback
;
429 void* Set(void* cmd
, GLenum _target
, GLuint _transformfeedback
) {
430 static_cast<ValueType
*>(cmd
)->Init(_target
, _transformfeedback
);
431 return NextCmdAddress
<ValueType
>(cmd
);
434 gpu::CommandHeader header
;
436 uint32_t transformfeedback
;
439 static_assert(sizeof(BindTransformFeedback
) == 12,
440 "size of BindTransformFeedback should be 12");
441 static_assert(offsetof(BindTransformFeedback
, header
) == 0,
442 "offset of BindTransformFeedback header should be 0");
443 static_assert(offsetof(BindTransformFeedback
, target
) == 4,
444 "offset of BindTransformFeedback target should be 4");
445 static_assert(offsetof(BindTransformFeedback
, transformfeedback
) == 8,
446 "offset of BindTransformFeedback transformfeedback should be 8");
449 typedef BlendColor ValueType
;
450 static const CommandId kCmdId
= kBlendColor
;
451 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
452 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
454 static uint32_t ComputeSize() {
455 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
458 void SetHeader() { header
.SetCmd
<ValueType
>(); }
460 void Init(GLclampf _red
, GLclampf _green
, GLclampf _blue
, GLclampf _alpha
) {
473 static_cast<ValueType
*>(cmd
)->Init(_red
, _green
, _blue
, _alpha
);
474 return NextCmdAddress
<ValueType
>(cmd
);
477 gpu::CommandHeader header
;
484 static_assert(sizeof(BlendColor
) == 20, "size of BlendColor should be 20");
485 static_assert(offsetof(BlendColor
, header
) == 0,
486 "offset of BlendColor header should be 0");
487 static_assert(offsetof(BlendColor
, red
) == 4,
488 "offset of BlendColor red should be 4");
489 static_assert(offsetof(BlendColor
, green
) == 8,
490 "offset of BlendColor green should be 8");
491 static_assert(offsetof(BlendColor
, blue
) == 12,
492 "offset of BlendColor blue should be 12");
493 static_assert(offsetof(BlendColor
, alpha
) == 16,
494 "offset of BlendColor alpha should be 16");
496 struct BlendEquation
{
497 typedef BlendEquation ValueType
;
498 static const CommandId kCmdId
= kBlendEquation
;
499 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
500 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
502 static uint32_t ComputeSize() {
503 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
506 void SetHeader() { header
.SetCmd
<ValueType
>(); }
508 void Init(GLenum _mode
) {
513 void* Set(void* cmd
, GLenum _mode
) {
514 static_cast<ValueType
*>(cmd
)->Init(_mode
);
515 return NextCmdAddress
<ValueType
>(cmd
);
518 gpu::CommandHeader header
;
522 static_assert(sizeof(BlendEquation
) == 8, "size of BlendEquation should be 8");
523 static_assert(offsetof(BlendEquation
, header
) == 0,
524 "offset of BlendEquation header should be 0");
525 static_assert(offsetof(BlendEquation
, mode
) == 4,
526 "offset of BlendEquation mode should be 4");
528 struct BlendEquationSeparate
{
529 typedef BlendEquationSeparate ValueType
;
530 static const CommandId kCmdId
= kBlendEquationSeparate
;
531 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
532 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
534 static uint32_t ComputeSize() {
535 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
538 void SetHeader() { header
.SetCmd
<ValueType
>(); }
540 void Init(GLenum _modeRGB
, GLenum _modeAlpha
) {
543 modeAlpha
= _modeAlpha
;
546 void* Set(void* cmd
, GLenum _modeRGB
, GLenum _modeAlpha
) {
547 static_cast<ValueType
*>(cmd
)->Init(_modeRGB
, _modeAlpha
);
548 return NextCmdAddress
<ValueType
>(cmd
);
551 gpu::CommandHeader header
;
556 static_assert(sizeof(BlendEquationSeparate
) == 12,
557 "size of BlendEquationSeparate should be 12");
558 static_assert(offsetof(BlendEquationSeparate
, header
) == 0,
559 "offset of BlendEquationSeparate header should be 0");
560 static_assert(offsetof(BlendEquationSeparate
, modeRGB
) == 4,
561 "offset of BlendEquationSeparate modeRGB should be 4");
562 static_assert(offsetof(BlendEquationSeparate
, modeAlpha
) == 8,
563 "offset of BlendEquationSeparate modeAlpha should be 8");
566 typedef BlendFunc ValueType
;
567 static const CommandId kCmdId
= kBlendFunc
;
568 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
569 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
571 static uint32_t ComputeSize() {
572 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
575 void SetHeader() { header
.SetCmd
<ValueType
>(); }
577 void Init(GLenum _sfactor
, GLenum _dfactor
) {
583 void* Set(void* cmd
, GLenum _sfactor
, GLenum _dfactor
) {
584 static_cast<ValueType
*>(cmd
)->Init(_sfactor
, _dfactor
);
585 return NextCmdAddress
<ValueType
>(cmd
);
588 gpu::CommandHeader header
;
593 static_assert(sizeof(BlendFunc
) == 12, "size of BlendFunc should be 12");
594 static_assert(offsetof(BlendFunc
, header
) == 0,
595 "offset of BlendFunc header should be 0");
596 static_assert(offsetof(BlendFunc
, sfactor
) == 4,
597 "offset of BlendFunc sfactor should be 4");
598 static_assert(offsetof(BlendFunc
, dfactor
) == 8,
599 "offset of BlendFunc dfactor should be 8");
601 struct BlendFuncSeparate
{
602 typedef BlendFuncSeparate ValueType
;
603 static const CommandId kCmdId
= kBlendFuncSeparate
;
604 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
605 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
607 static uint32_t ComputeSize() {
608 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
611 void SetHeader() { header
.SetCmd
<ValueType
>(); }
613 void Init(GLenum _srcRGB
,
620 srcAlpha
= _srcAlpha
;
621 dstAlpha
= _dstAlpha
;
629 static_cast<ValueType
*>(cmd
)->Init(_srcRGB
, _dstRGB
, _srcAlpha
, _dstAlpha
);
630 return NextCmdAddress
<ValueType
>(cmd
);
633 gpu::CommandHeader header
;
640 static_assert(sizeof(BlendFuncSeparate
) == 20,
641 "size of BlendFuncSeparate should be 20");
642 static_assert(offsetof(BlendFuncSeparate
, header
) == 0,
643 "offset of BlendFuncSeparate header should be 0");
644 static_assert(offsetof(BlendFuncSeparate
, srcRGB
) == 4,
645 "offset of BlendFuncSeparate srcRGB should be 4");
646 static_assert(offsetof(BlendFuncSeparate
, dstRGB
) == 8,
647 "offset of BlendFuncSeparate dstRGB should be 8");
648 static_assert(offsetof(BlendFuncSeparate
, srcAlpha
) == 12,
649 "offset of BlendFuncSeparate srcAlpha should be 12");
650 static_assert(offsetof(BlendFuncSeparate
, dstAlpha
) == 16,
651 "offset of BlendFuncSeparate dstAlpha should be 16");
654 typedef BufferData ValueType
;
655 static const CommandId kCmdId
= kBufferData
;
656 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
657 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
659 static uint32_t ComputeSize() {
660 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
663 void SetHeader() { header
.SetCmd
<ValueType
>(); }
665 void Init(GLenum _target
,
667 uint32_t _data_shm_id
,
668 uint32_t _data_shm_offset
,
673 data_shm_id
= _data_shm_id
;
674 data_shm_offset
= _data_shm_offset
;
681 uint32_t _data_shm_id
,
682 uint32_t _data_shm_offset
,
684 static_cast<ValueType
*>(cmd
)
685 ->Init(_target
, _size
, _data_shm_id
, _data_shm_offset
, _usage
);
686 return NextCmdAddress
<ValueType
>(cmd
);
689 gpu::CommandHeader header
;
692 uint32_t data_shm_id
;
693 uint32_t data_shm_offset
;
697 static_assert(sizeof(BufferData
) == 24, "size of BufferData should be 24");
698 static_assert(offsetof(BufferData
, header
) == 0,
699 "offset of BufferData header should be 0");
700 static_assert(offsetof(BufferData
, target
) == 4,
701 "offset of BufferData target should be 4");
702 static_assert(offsetof(BufferData
, size
) == 8,
703 "offset of BufferData size should be 8");
704 static_assert(offsetof(BufferData
, data_shm_id
) == 12,
705 "offset of BufferData data_shm_id should be 12");
706 static_assert(offsetof(BufferData
, data_shm_offset
) == 16,
707 "offset of BufferData data_shm_offset should be 16");
708 static_assert(offsetof(BufferData
, usage
) == 20,
709 "offset of BufferData usage should be 20");
711 struct BufferSubData
{
712 typedef BufferSubData ValueType
;
713 static const CommandId kCmdId
= kBufferSubData
;
714 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
715 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
717 static uint32_t ComputeSize() {
718 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
721 void SetHeader() { header
.SetCmd
<ValueType
>(); }
723 void Init(GLenum _target
,
726 uint32_t _data_shm_id
,
727 uint32_t _data_shm_offset
) {
732 data_shm_id
= _data_shm_id
;
733 data_shm_offset
= _data_shm_offset
;
740 uint32_t _data_shm_id
,
741 uint32_t _data_shm_offset
) {
742 static_cast<ValueType
*>(cmd
)
743 ->Init(_target
, _offset
, _size
, _data_shm_id
, _data_shm_offset
);
744 return NextCmdAddress
<ValueType
>(cmd
);
747 gpu::CommandHeader header
;
751 uint32_t data_shm_id
;
752 uint32_t data_shm_offset
;
755 static_assert(sizeof(BufferSubData
) == 24,
756 "size of BufferSubData should be 24");
757 static_assert(offsetof(BufferSubData
, header
) == 0,
758 "offset of BufferSubData header should be 0");
759 static_assert(offsetof(BufferSubData
, target
) == 4,
760 "offset of BufferSubData target should be 4");
761 static_assert(offsetof(BufferSubData
, offset
) == 8,
762 "offset of BufferSubData offset should be 8");
763 static_assert(offsetof(BufferSubData
, size
) == 12,
764 "offset of BufferSubData size should be 12");
765 static_assert(offsetof(BufferSubData
, data_shm_id
) == 16,
766 "offset of BufferSubData data_shm_id should be 16");
767 static_assert(offsetof(BufferSubData
, data_shm_offset
) == 20,
768 "offset of BufferSubData data_shm_offset should be 20");
770 struct CheckFramebufferStatus
{
771 typedef CheckFramebufferStatus ValueType
;
772 static const CommandId kCmdId
= kCheckFramebufferStatus
;
773 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
774 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
776 typedef GLenum Result
;
778 static uint32_t ComputeSize() {
779 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
782 void SetHeader() { header
.SetCmd
<ValueType
>(); }
784 void Init(GLenum _target
,
785 uint32_t _result_shm_id
,
786 uint32_t _result_shm_offset
) {
789 result_shm_id
= _result_shm_id
;
790 result_shm_offset
= _result_shm_offset
;
795 uint32_t _result_shm_id
,
796 uint32_t _result_shm_offset
) {
797 static_cast<ValueType
*>(cmd
)
798 ->Init(_target
, _result_shm_id
, _result_shm_offset
);
799 return NextCmdAddress
<ValueType
>(cmd
);
802 gpu::CommandHeader header
;
804 uint32_t result_shm_id
;
805 uint32_t result_shm_offset
;
808 static_assert(sizeof(CheckFramebufferStatus
) == 16,
809 "size of CheckFramebufferStatus should be 16");
810 static_assert(offsetof(CheckFramebufferStatus
, header
) == 0,
811 "offset of CheckFramebufferStatus header should be 0");
812 static_assert(offsetof(CheckFramebufferStatus
, target
) == 4,
813 "offset of CheckFramebufferStatus target should be 4");
814 static_assert(offsetof(CheckFramebufferStatus
, result_shm_id
) == 8,
815 "offset of CheckFramebufferStatus result_shm_id should be 8");
817 offsetof(CheckFramebufferStatus
, result_shm_offset
) == 12,
818 "offset of CheckFramebufferStatus result_shm_offset should be 12");
821 typedef Clear ValueType
;
822 static const CommandId kCmdId
= kClear
;
823 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
824 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
826 static uint32_t ComputeSize() {
827 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
830 void SetHeader() { header
.SetCmd
<ValueType
>(); }
832 void Init(GLbitfield _mask
) {
837 void* Set(void* cmd
, GLbitfield _mask
) {
838 static_cast<ValueType
*>(cmd
)->Init(_mask
);
839 return NextCmdAddress
<ValueType
>(cmd
);
842 gpu::CommandHeader header
;
846 static_assert(sizeof(Clear
) == 8, "size of Clear should be 8");
847 static_assert(offsetof(Clear
, header
) == 0,
848 "offset of Clear header should be 0");
849 static_assert(offsetof(Clear
, mask
) == 4, "offset of Clear mask should be 4");
851 struct ClearBufferfi
{
852 typedef ClearBufferfi ValueType
;
853 static const CommandId kCmdId
= kClearBufferfi
;
854 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
855 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
857 static uint32_t ComputeSize() {
858 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
861 void SetHeader() { header
.SetCmd
<ValueType
>(); }
863 void Init(GLenum _buffer
,
869 drawbuffers
= _drawbuffers
;
879 static_cast<ValueType
*>(cmd
)->Init(_buffer
, _drawbuffers
, _depth
, _stencil
);
880 return NextCmdAddress
<ValueType
>(cmd
);
883 gpu::CommandHeader header
;
890 static_assert(sizeof(ClearBufferfi
) == 20,
891 "size of ClearBufferfi should be 20");
892 static_assert(offsetof(ClearBufferfi
, header
) == 0,
893 "offset of ClearBufferfi header should be 0");
894 static_assert(offsetof(ClearBufferfi
, buffer
) == 4,
895 "offset of ClearBufferfi buffer should be 4");
896 static_assert(offsetof(ClearBufferfi
, drawbuffers
) == 8,
897 "offset of ClearBufferfi drawbuffers should be 8");
898 static_assert(offsetof(ClearBufferfi
, depth
) == 12,
899 "offset of ClearBufferfi depth should be 12");
900 static_assert(offsetof(ClearBufferfi
, stencil
) == 16,
901 "offset of ClearBufferfi stencil should be 16");
903 struct ClearBufferfvImmediate
{
904 typedef ClearBufferfvImmediate ValueType
;
905 static const CommandId kCmdId
= kClearBufferfvImmediate
;
906 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
907 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
909 static uint32_t ComputeDataSize() {
910 return static_cast<uint32_t>(sizeof(GLfloat
) * 4);
913 static uint32_t ComputeEffectiveDataSize(GLenum buffer
) {
914 return static_cast<uint32_t>(sizeof(GLfloat
) *
915 GLES2Util::CalcClearBufferfvDataCount(buffer
));
918 static uint32_t ComputeSize() {
919 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
922 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
924 void Init(GLenum _buffer
, GLint _drawbuffers
, const GLfloat
* _value
) {
927 drawbuffers
= _drawbuffers
;
928 memcpy(ImmediateDataAddress(this), _value
,
929 ComputeEffectiveDataSize(buffer
));
930 DCHECK_GE(ComputeDataSize(), ComputeEffectiveDataSize(buffer
));
931 char* pointer
= reinterpret_cast<char*>(ImmediateDataAddress(this)) +
932 ComputeEffectiveDataSize(buffer
);
933 memset(pointer
, 0, ComputeDataSize() - ComputeEffectiveDataSize(buffer
));
939 const GLfloat
* _value
) {
940 static_cast<ValueType
*>(cmd
)->Init(_buffer
, _drawbuffers
, _value
);
941 const uint32_t size
= ComputeSize();
942 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
945 gpu::CommandHeader header
;
950 static_assert(sizeof(ClearBufferfvImmediate
) == 12,
951 "size of ClearBufferfvImmediate should be 12");
952 static_assert(offsetof(ClearBufferfvImmediate
, header
) == 0,
953 "offset of ClearBufferfvImmediate header should be 0");
954 static_assert(offsetof(ClearBufferfvImmediate
, buffer
) == 4,
955 "offset of ClearBufferfvImmediate buffer should be 4");
956 static_assert(offsetof(ClearBufferfvImmediate
, drawbuffers
) == 8,
957 "offset of ClearBufferfvImmediate drawbuffers should be 8");
959 struct ClearBufferivImmediate
{
960 typedef ClearBufferivImmediate ValueType
;
961 static const CommandId kCmdId
= kClearBufferivImmediate
;
962 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
963 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
965 static uint32_t ComputeDataSize() {
966 return static_cast<uint32_t>(sizeof(GLint
) * 4);
969 static uint32_t ComputeEffectiveDataSize(GLenum buffer
) {
970 return static_cast<uint32_t>(sizeof(GLint
) *
971 GLES2Util::CalcClearBufferivDataCount(buffer
));
974 static uint32_t ComputeSize() {
975 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
978 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
980 void Init(GLenum _buffer
, GLint _drawbuffers
, const GLint
* _value
) {
983 drawbuffers
= _drawbuffers
;
984 memcpy(ImmediateDataAddress(this), _value
,
985 ComputeEffectiveDataSize(buffer
));
986 DCHECK_GE(ComputeDataSize(), ComputeEffectiveDataSize(buffer
));
987 char* pointer
= reinterpret_cast<char*>(ImmediateDataAddress(this)) +
988 ComputeEffectiveDataSize(buffer
);
989 memset(pointer
, 0, ComputeDataSize() - ComputeEffectiveDataSize(buffer
));
995 const GLint
* _value
) {
996 static_cast<ValueType
*>(cmd
)->Init(_buffer
, _drawbuffers
, _value
);
997 const uint32_t size
= ComputeSize();
998 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
1001 gpu::CommandHeader header
;
1003 int32_t drawbuffers
;
1006 static_assert(sizeof(ClearBufferivImmediate
) == 12,
1007 "size of ClearBufferivImmediate should be 12");
1008 static_assert(offsetof(ClearBufferivImmediate
, header
) == 0,
1009 "offset of ClearBufferivImmediate header should be 0");
1010 static_assert(offsetof(ClearBufferivImmediate
, buffer
) == 4,
1011 "offset of ClearBufferivImmediate buffer should be 4");
1012 static_assert(offsetof(ClearBufferivImmediate
, drawbuffers
) == 8,
1013 "offset of ClearBufferivImmediate drawbuffers should be 8");
1015 struct ClearBufferuivImmediate
{
1016 typedef ClearBufferuivImmediate ValueType
;
1017 static const CommandId kCmdId
= kClearBufferuivImmediate
;
1018 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
1019 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
1021 static uint32_t ComputeDataSize() {
1022 return static_cast<uint32_t>(sizeof(GLuint
) * 4);
1025 static uint32_t ComputeSize() {
1026 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
1029 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
1031 void Init(GLenum _buffer
, GLint _drawbuffers
, const GLuint
* _value
) {
1034 drawbuffers
= _drawbuffers
;
1035 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize());
1038 void* Set(void* cmd
,
1041 const GLuint
* _value
) {
1042 static_cast<ValueType
*>(cmd
)->Init(_buffer
, _drawbuffers
, _value
);
1043 const uint32_t size
= ComputeSize();
1044 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
1047 gpu::CommandHeader header
;
1049 int32_t drawbuffers
;
1052 static_assert(sizeof(ClearBufferuivImmediate
) == 12,
1053 "size of ClearBufferuivImmediate should be 12");
1054 static_assert(offsetof(ClearBufferuivImmediate
, header
) == 0,
1055 "offset of ClearBufferuivImmediate header should be 0");
1056 static_assert(offsetof(ClearBufferuivImmediate
, buffer
) == 4,
1057 "offset of ClearBufferuivImmediate buffer should be 4");
1058 static_assert(offsetof(ClearBufferuivImmediate
, drawbuffers
) == 8,
1059 "offset of ClearBufferuivImmediate drawbuffers should be 8");
1062 typedef ClearColor ValueType
;
1063 static const CommandId kCmdId
= kClearColor
;
1064 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1065 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1067 static uint32_t ComputeSize() {
1068 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1071 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1073 void Init(GLclampf _red
, GLclampf _green
, GLclampf _blue
, GLclampf _alpha
) {
1081 void* Set(void* cmd
,
1086 static_cast<ValueType
*>(cmd
)->Init(_red
, _green
, _blue
, _alpha
);
1087 return NextCmdAddress
<ValueType
>(cmd
);
1090 gpu::CommandHeader header
;
1097 static_assert(sizeof(ClearColor
) == 20, "size of ClearColor should be 20");
1098 static_assert(offsetof(ClearColor
, header
) == 0,
1099 "offset of ClearColor header should be 0");
1100 static_assert(offsetof(ClearColor
, red
) == 4,
1101 "offset of ClearColor red should be 4");
1102 static_assert(offsetof(ClearColor
, green
) == 8,
1103 "offset of ClearColor green should be 8");
1104 static_assert(offsetof(ClearColor
, blue
) == 12,
1105 "offset of ClearColor blue should be 12");
1106 static_assert(offsetof(ClearColor
, alpha
) == 16,
1107 "offset of ClearColor alpha should be 16");
1109 struct ClearDepthf
{
1110 typedef ClearDepthf ValueType
;
1111 static const CommandId kCmdId
= kClearDepthf
;
1112 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1113 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1115 static uint32_t ComputeSize() {
1116 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1119 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1121 void Init(GLclampf _depth
) {
1126 void* Set(void* cmd
, GLclampf _depth
) {
1127 static_cast<ValueType
*>(cmd
)->Init(_depth
);
1128 return NextCmdAddress
<ValueType
>(cmd
);
1131 gpu::CommandHeader header
;
1135 static_assert(sizeof(ClearDepthf
) == 8, "size of ClearDepthf should be 8");
1136 static_assert(offsetof(ClearDepthf
, header
) == 0,
1137 "offset of ClearDepthf header should be 0");
1138 static_assert(offsetof(ClearDepthf
, depth
) == 4,
1139 "offset of ClearDepthf depth should be 4");
1141 struct ClearStencil
{
1142 typedef ClearStencil ValueType
;
1143 static const CommandId kCmdId
= kClearStencil
;
1144 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1145 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1147 static uint32_t ComputeSize() {
1148 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1151 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1153 void Init(GLint _s
) {
1158 void* Set(void* cmd
, GLint _s
) {
1159 static_cast<ValueType
*>(cmd
)->Init(_s
);
1160 return NextCmdAddress
<ValueType
>(cmd
);
1163 gpu::CommandHeader header
;
1167 static_assert(sizeof(ClearStencil
) == 8, "size of ClearStencil should be 8");
1168 static_assert(offsetof(ClearStencil
, header
) == 0,
1169 "offset of ClearStencil header should be 0");
1170 static_assert(offsetof(ClearStencil
, s
) == 4,
1171 "offset of ClearStencil s should be 4");
1173 struct ClientWaitSync
{
1174 typedef ClientWaitSync ValueType
;
1175 static const CommandId kCmdId
= kClientWaitSync
;
1176 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1177 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
1179 typedef GLenum Result
;
1181 static uint32_t ComputeSize() {
1182 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1185 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1187 void Init(GLuint _sync
,
1191 uint32_t _result_shm_id
,
1192 uint32_t _result_shm_offset
) {
1196 timeout_0
= _timeout_0
;
1197 timeout_1
= _timeout_1
;
1198 result_shm_id
= _result_shm_id
;
1199 result_shm_offset
= _result_shm_offset
;
1202 void* Set(void* cmd
,
1207 uint32_t _result_shm_id
,
1208 uint32_t _result_shm_offset
) {
1209 static_cast<ValueType
*>(cmd
)->Init(_sync
, _flags
, _timeout_0
, _timeout_1
,
1210 _result_shm_id
, _result_shm_offset
);
1211 return NextCmdAddress
<ValueType
>(cmd
);
1214 gpu::CommandHeader header
;
1219 uint32_t result_shm_id
;
1220 uint32_t result_shm_offset
;
1223 static_assert(sizeof(ClientWaitSync
) == 28,
1224 "size of ClientWaitSync should be 28");
1225 static_assert(offsetof(ClientWaitSync
, header
) == 0,
1226 "offset of ClientWaitSync header should be 0");
1227 static_assert(offsetof(ClientWaitSync
, sync
) == 4,
1228 "offset of ClientWaitSync sync should be 4");
1229 static_assert(offsetof(ClientWaitSync
, flags
) == 8,
1230 "offset of ClientWaitSync flags should be 8");
1231 static_assert(offsetof(ClientWaitSync
, timeout_0
) == 12,
1232 "offset of ClientWaitSync timeout_0 should be 12");
1233 static_assert(offsetof(ClientWaitSync
, timeout_1
) == 16,
1234 "offset of ClientWaitSync timeout_1 should be 16");
1235 static_assert(offsetof(ClientWaitSync
, result_shm_id
) == 20,
1236 "offset of ClientWaitSync result_shm_id should be 20");
1237 static_assert(offsetof(ClientWaitSync
, result_shm_offset
) == 24,
1238 "offset of ClientWaitSync result_shm_offset should be 24");
1241 typedef ColorMask ValueType
;
1242 static const CommandId kCmdId
= kColorMask
;
1243 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1244 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1246 static uint32_t ComputeSize() {
1247 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1250 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1252 void Init(GLboolean _red
,
1263 void* Set(void* cmd
,
1268 static_cast<ValueType
*>(cmd
)->Init(_red
, _green
, _blue
, _alpha
);
1269 return NextCmdAddress
<ValueType
>(cmd
);
1272 gpu::CommandHeader header
;
1279 static_assert(sizeof(ColorMask
) == 20, "size of ColorMask should be 20");
1280 static_assert(offsetof(ColorMask
, header
) == 0,
1281 "offset of ColorMask header should be 0");
1282 static_assert(offsetof(ColorMask
, red
) == 4,
1283 "offset of ColorMask red should be 4");
1284 static_assert(offsetof(ColorMask
, green
) == 8,
1285 "offset of ColorMask green should be 8");
1286 static_assert(offsetof(ColorMask
, blue
) == 12,
1287 "offset of ColorMask blue should be 12");
1288 static_assert(offsetof(ColorMask
, alpha
) == 16,
1289 "offset of ColorMask alpha should be 16");
1291 struct CompileShader
{
1292 typedef CompileShader ValueType
;
1293 static const CommandId kCmdId
= kCompileShader
;
1294 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1295 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1297 static uint32_t ComputeSize() {
1298 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1301 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1303 void Init(GLuint _shader
) {
1308 void* Set(void* cmd
, GLuint _shader
) {
1309 static_cast<ValueType
*>(cmd
)->Init(_shader
);
1310 return NextCmdAddress
<ValueType
>(cmd
);
1313 gpu::CommandHeader header
;
1317 static_assert(sizeof(CompileShader
) == 8, "size of CompileShader should be 8");
1318 static_assert(offsetof(CompileShader
, header
) == 0,
1319 "offset of CompileShader header should be 0");
1320 static_assert(offsetof(CompileShader
, shader
) == 4,
1321 "offset of CompileShader shader should be 4");
1323 struct CompressedTexImage2DBucket
{
1324 typedef CompressedTexImage2DBucket ValueType
;
1325 static const CommandId kCmdId
= kCompressedTexImage2DBucket
;
1326 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1327 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1329 static uint32_t ComputeSize() {
1330 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1333 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1335 void Init(GLenum _target
,
1337 GLenum _internalformat
,
1340 GLuint _bucket_id
) {
1344 internalformat
= _internalformat
;
1347 bucket_id
= _bucket_id
;
1350 void* Set(void* cmd
,
1353 GLenum _internalformat
,
1356 GLuint _bucket_id
) {
1357 static_cast<ValueType
*>(cmd
)
1358 ->Init(_target
, _level
, _internalformat
, _width
, _height
, _bucket_id
);
1359 return NextCmdAddress
<ValueType
>(cmd
);
1362 gpu::CommandHeader header
;
1365 uint32_t internalformat
;
1369 static const int32_t border
= 0;
1372 static_assert(sizeof(CompressedTexImage2DBucket
) == 28,
1373 "size of CompressedTexImage2DBucket should be 28");
1374 static_assert(offsetof(CompressedTexImage2DBucket
, header
) == 0,
1375 "offset of CompressedTexImage2DBucket header should be 0");
1376 static_assert(offsetof(CompressedTexImage2DBucket
, target
) == 4,
1377 "offset of CompressedTexImage2DBucket target should be 4");
1378 static_assert(offsetof(CompressedTexImage2DBucket
, level
) == 8,
1379 "offset of CompressedTexImage2DBucket level should be 8");
1381 offsetof(CompressedTexImage2DBucket
, internalformat
) == 12,
1382 "offset of CompressedTexImage2DBucket internalformat should be 12");
1383 static_assert(offsetof(CompressedTexImage2DBucket
, width
) == 16,
1384 "offset of CompressedTexImage2DBucket width should be 16");
1385 static_assert(offsetof(CompressedTexImage2DBucket
, height
) == 20,
1386 "offset of CompressedTexImage2DBucket height should be 20");
1387 static_assert(offsetof(CompressedTexImage2DBucket
, bucket_id
) == 24,
1388 "offset of CompressedTexImage2DBucket bucket_id should be 24");
1390 struct CompressedTexImage2D
{
1391 typedef CompressedTexImage2D ValueType
;
1392 static const CommandId kCmdId
= kCompressedTexImage2D
;
1393 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1394 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1396 static uint32_t ComputeSize() {
1397 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1400 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1402 void Init(GLenum _target
,
1404 GLenum _internalformat
,
1408 uint32_t _data_shm_id
,
1409 uint32_t _data_shm_offset
) {
1413 internalformat
= _internalformat
;
1416 imageSize
= _imageSize
;
1417 data_shm_id
= _data_shm_id
;
1418 data_shm_offset
= _data_shm_offset
;
1421 void* Set(void* cmd
,
1424 GLenum _internalformat
,
1428 uint32_t _data_shm_id
,
1429 uint32_t _data_shm_offset
) {
1430 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _internalformat
, _width
,
1431 _height
, _imageSize
, _data_shm_id
,
1433 return NextCmdAddress
<ValueType
>(cmd
);
1436 gpu::CommandHeader header
;
1439 uint32_t internalformat
;
1443 uint32_t data_shm_id
;
1444 uint32_t data_shm_offset
;
1445 static const int32_t border
= 0;
1448 static_assert(sizeof(CompressedTexImage2D
) == 36,
1449 "size of CompressedTexImage2D should be 36");
1450 static_assert(offsetof(CompressedTexImage2D
, header
) == 0,
1451 "offset of CompressedTexImage2D header should be 0");
1452 static_assert(offsetof(CompressedTexImage2D
, target
) == 4,
1453 "offset of CompressedTexImage2D target should be 4");
1454 static_assert(offsetof(CompressedTexImage2D
, level
) == 8,
1455 "offset of CompressedTexImage2D level should be 8");
1456 static_assert(offsetof(CompressedTexImage2D
, internalformat
) == 12,
1457 "offset of CompressedTexImage2D internalformat should be 12");
1458 static_assert(offsetof(CompressedTexImage2D
, width
) == 16,
1459 "offset of CompressedTexImage2D width should be 16");
1460 static_assert(offsetof(CompressedTexImage2D
, height
) == 20,
1461 "offset of CompressedTexImage2D height should be 20");
1462 static_assert(offsetof(CompressedTexImage2D
, imageSize
) == 24,
1463 "offset of CompressedTexImage2D imageSize should be 24");
1464 static_assert(offsetof(CompressedTexImage2D
, data_shm_id
) == 28,
1465 "offset of CompressedTexImage2D data_shm_id should be 28");
1466 static_assert(offsetof(CompressedTexImage2D
, data_shm_offset
) == 32,
1467 "offset of CompressedTexImage2D data_shm_offset should be 32");
1469 struct CompressedTexSubImage2DBucket
{
1470 typedef CompressedTexSubImage2DBucket ValueType
;
1471 static const CommandId kCmdId
= kCompressedTexSubImage2DBucket
;
1472 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1473 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1475 static uint32_t ComputeSize() {
1476 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1479 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1481 void Init(GLenum _target
,
1488 GLuint _bucket_id
) {
1497 bucket_id
= _bucket_id
;
1500 void* Set(void* cmd
,
1508 GLuint _bucket_id
) {
1509 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _xoffset
, _yoffset
,
1510 _width
, _height
, _format
, _bucket_id
);
1511 return NextCmdAddress
<ValueType
>(cmd
);
1514 gpu::CommandHeader header
;
1525 static_assert(sizeof(CompressedTexSubImage2DBucket
) == 36,
1526 "size of CompressedTexSubImage2DBucket should be 36");
1527 static_assert(offsetof(CompressedTexSubImage2DBucket
, header
) == 0,
1528 "offset of CompressedTexSubImage2DBucket header should be 0");
1529 static_assert(offsetof(CompressedTexSubImage2DBucket
, target
) == 4,
1530 "offset of CompressedTexSubImage2DBucket target should be 4");
1531 static_assert(offsetof(CompressedTexSubImage2DBucket
, level
) == 8,
1532 "offset of CompressedTexSubImage2DBucket level should be 8");
1533 static_assert(offsetof(CompressedTexSubImage2DBucket
, xoffset
) == 12,
1534 "offset of CompressedTexSubImage2DBucket xoffset should be 12");
1535 static_assert(offsetof(CompressedTexSubImage2DBucket
, yoffset
) == 16,
1536 "offset of CompressedTexSubImage2DBucket yoffset should be 16");
1537 static_assert(offsetof(CompressedTexSubImage2DBucket
, width
) == 20,
1538 "offset of CompressedTexSubImage2DBucket width should be 20");
1539 static_assert(offsetof(CompressedTexSubImage2DBucket
, height
) == 24,
1540 "offset of CompressedTexSubImage2DBucket height should be 24");
1541 static_assert(offsetof(CompressedTexSubImage2DBucket
, format
) == 28,
1542 "offset of CompressedTexSubImage2DBucket format should be 28");
1543 static_assert(offsetof(CompressedTexSubImage2DBucket
, bucket_id
) == 32,
1544 "offset of CompressedTexSubImage2DBucket bucket_id should be 32");
1546 struct CompressedTexSubImage2D
{
1547 typedef CompressedTexSubImage2D ValueType
;
1548 static const CommandId kCmdId
= kCompressedTexSubImage2D
;
1549 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1550 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1552 static uint32_t ComputeSize() {
1553 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1556 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1558 void Init(GLenum _target
,
1566 uint32_t _data_shm_id
,
1567 uint32_t _data_shm_offset
) {
1576 imageSize
= _imageSize
;
1577 data_shm_id
= _data_shm_id
;
1578 data_shm_offset
= _data_shm_offset
;
1581 void* Set(void* cmd
,
1590 uint32_t _data_shm_id
,
1591 uint32_t _data_shm_offset
) {
1592 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _xoffset
, _yoffset
,
1593 _width
, _height
, _format
, _imageSize
,
1594 _data_shm_id
, _data_shm_offset
);
1595 return NextCmdAddress
<ValueType
>(cmd
);
1598 gpu::CommandHeader header
;
1607 uint32_t data_shm_id
;
1608 uint32_t data_shm_offset
;
1611 static_assert(sizeof(CompressedTexSubImage2D
) == 44,
1612 "size of CompressedTexSubImage2D should be 44");
1613 static_assert(offsetof(CompressedTexSubImage2D
, header
) == 0,
1614 "offset of CompressedTexSubImage2D header should be 0");
1615 static_assert(offsetof(CompressedTexSubImage2D
, target
) == 4,
1616 "offset of CompressedTexSubImage2D target should be 4");
1617 static_assert(offsetof(CompressedTexSubImage2D
, level
) == 8,
1618 "offset of CompressedTexSubImage2D level should be 8");
1619 static_assert(offsetof(CompressedTexSubImage2D
, xoffset
) == 12,
1620 "offset of CompressedTexSubImage2D xoffset should be 12");
1621 static_assert(offsetof(CompressedTexSubImage2D
, yoffset
) == 16,
1622 "offset of CompressedTexSubImage2D yoffset should be 16");
1623 static_assert(offsetof(CompressedTexSubImage2D
, width
) == 20,
1624 "offset of CompressedTexSubImage2D width should be 20");
1625 static_assert(offsetof(CompressedTexSubImage2D
, height
) == 24,
1626 "offset of CompressedTexSubImage2D height should be 24");
1627 static_assert(offsetof(CompressedTexSubImage2D
, format
) == 28,
1628 "offset of CompressedTexSubImage2D format should be 28");
1629 static_assert(offsetof(CompressedTexSubImage2D
, imageSize
) == 32,
1630 "offset of CompressedTexSubImage2D imageSize should be 32");
1631 static_assert(offsetof(CompressedTexSubImage2D
, data_shm_id
) == 36,
1632 "offset of CompressedTexSubImage2D data_shm_id should be 36");
1633 static_assert(offsetof(CompressedTexSubImage2D
, data_shm_offset
) == 40,
1634 "offset of CompressedTexSubImage2D data_shm_offset should be 40");
1636 struct CompressedTexImage3DBucket
{
1637 typedef CompressedTexImage3DBucket ValueType
;
1638 static const CommandId kCmdId
= kCompressedTexImage3DBucket
;
1639 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1640 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1642 static uint32_t ComputeSize() {
1643 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1646 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1648 void Init(GLenum _target
,
1650 GLenum _internalformat
,
1654 GLuint _bucket_id
) {
1658 internalformat
= _internalformat
;
1662 bucket_id
= _bucket_id
;
1665 void* Set(void* cmd
,
1668 GLenum _internalformat
,
1672 GLuint _bucket_id
) {
1673 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _internalformat
, _width
,
1674 _height
, _depth
, _bucket_id
);
1675 return NextCmdAddress
<ValueType
>(cmd
);
1678 gpu::CommandHeader header
;
1681 uint32_t internalformat
;
1686 static const int32_t border
= 0;
1689 static_assert(sizeof(CompressedTexImage3DBucket
) == 32,
1690 "size of CompressedTexImage3DBucket should be 32");
1691 static_assert(offsetof(CompressedTexImage3DBucket
, header
) == 0,
1692 "offset of CompressedTexImage3DBucket header should be 0");
1693 static_assert(offsetof(CompressedTexImage3DBucket
, target
) == 4,
1694 "offset of CompressedTexImage3DBucket target should be 4");
1695 static_assert(offsetof(CompressedTexImage3DBucket
, level
) == 8,
1696 "offset of CompressedTexImage3DBucket level should be 8");
1698 offsetof(CompressedTexImage3DBucket
, internalformat
) == 12,
1699 "offset of CompressedTexImage3DBucket internalformat should be 12");
1700 static_assert(offsetof(CompressedTexImage3DBucket
, width
) == 16,
1701 "offset of CompressedTexImage3DBucket width should be 16");
1702 static_assert(offsetof(CompressedTexImage3DBucket
, height
) == 20,
1703 "offset of CompressedTexImage3DBucket height should be 20");
1704 static_assert(offsetof(CompressedTexImage3DBucket
, depth
) == 24,
1705 "offset of CompressedTexImage3DBucket depth should be 24");
1706 static_assert(offsetof(CompressedTexImage3DBucket
, bucket_id
) == 28,
1707 "offset of CompressedTexImage3DBucket bucket_id should be 28");
1709 struct CompressedTexImage3D
{
1710 typedef CompressedTexImage3D ValueType
;
1711 static const CommandId kCmdId
= kCompressedTexImage3D
;
1712 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1713 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1715 static uint32_t ComputeSize() {
1716 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1719 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1721 void Init(GLenum _target
,
1723 GLenum _internalformat
,
1728 uint32_t _data_shm_id
,
1729 uint32_t _data_shm_offset
) {
1733 internalformat
= _internalformat
;
1737 imageSize
= _imageSize
;
1738 data_shm_id
= _data_shm_id
;
1739 data_shm_offset
= _data_shm_offset
;
1742 void* Set(void* cmd
,
1745 GLenum _internalformat
,
1750 uint32_t _data_shm_id
,
1751 uint32_t _data_shm_offset
) {
1752 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _internalformat
, _width
,
1753 _height
, _depth
, _imageSize
,
1754 _data_shm_id
, _data_shm_offset
);
1755 return NextCmdAddress
<ValueType
>(cmd
);
1758 gpu::CommandHeader header
;
1761 uint32_t internalformat
;
1766 uint32_t data_shm_id
;
1767 uint32_t data_shm_offset
;
1768 static const int32_t border
= 0;
1771 static_assert(sizeof(CompressedTexImage3D
) == 40,
1772 "size of CompressedTexImage3D should be 40");
1773 static_assert(offsetof(CompressedTexImage3D
, header
) == 0,
1774 "offset of CompressedTexImage3D header should be 0");
1775 static_assert(offsetof(CompressedTexImage3D
, target
) == 4,
1776 "offset of CompressedTexImage3D target should be 4");
1777 static_assert(offsetof(CompressedTexImage3D
, level
) == 8,
1778 "offset of CompressedTexImage3D level should be 8");
1779 static_assert(offsetof(CompressedTexImage3D
, internalformat
) == 12,
1780 "offset of CompressedTexImage3D internalformat should be 12");
1781 static_assert(offsetof(CompressedTexImage3D
, width
) == 16,
1782 "offset of CompressedTexImage3D width should be 16");
1783 static_assert(offsetof(CompressedTexImage3D
, height
) == 20,
1784 "offset of CompressedTexImage3D height should be 20");
1785 static_assert(offsetof(CompressedTexImage3D
, depth
) == 24,
1786 "offset of CompressedTexImage3D depth should be 24");
1787 static_assert(offsetof(CompressedTexImage3D
, imageSize
) == 28,
1788 "offset of CompressedTexImage3D imageSize should be 28");
1789 static_assert(offsetof(CompressedTexImage3D
, data_shm_id
) == 32,
1790 "offset of CompressedTexImage3D data_shm_id should be 32");
1791 static_assert(offsetof(CompressedTexImage3D
, data_shm_offset
) == 36,
1792 "offset of CompressedTexImage3D data_shm_offset should be 36");
1794 struct CompressedTexSubImage3DBucket
{
1795 typedef CompressedTexSubImage3DBucket ValueType
;
1796 static const CommandId kCmdId
= kCompressedTexSubImage3DBucket
;
1797 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1798 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1800 static uint32_t ComputeSize() {
1801 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1804 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1806 void Init(GLenum _target
,
1815 GLuint _bucket_id
) {
1826 bucket_id
= _bucket_id
;
1829 void* Set(void* cmd
,
1839 GLuint _bucket_id
) {
1840 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _xoffset
, _yoffset
,
1841 _zoffset
, _width
, _height
, _depth
,
1842 _format
, _bucket_id
);
1843 return NextCmdAddress
<ValueType
>(cmd
);
1846 gpu::CommandHeader header
;
1859 static_assert(sizeof(CompressedTexSubImage3DBucket
) == 44,
1860 "size of CompressedTexSubImage3DBucket should be 44");
1861 static_assert(offsetof(CompressedTexSubImage3DBucket
, header
) == 0,
1862 "offset of CompressedTexSubImage3DBucket header should be 0");
1863 static_assert(offsetof(CompressedTexSubImage3DBucket
, target
) == 4,
1864 "offset of CompressedTexSubImage3DBucket target should be 4");
1865 static_assert(offsetof(CompressedTexSubImage3DBucket
, level
) == 8,
1866 "offset of CompressedTexSubImage3DBucket level should be 8");
1867 static_assert(offsetof(CompressedTexSubImage3DBucket
, xoffset
) == 12,
1868 "offset of CompressedTexSubImage3DBucket xoffset should be 12");
1869 static_assert(offsetof(CompressedTexSubImage3DBucket
, yoffset
) == 16,
1870 "offset of CompressedTexSubImage3DBucket yoffset should be 16");
1871 static_assert(offsetof(CompressedTexSubImage3DBucket
, zoffset
) == 20,
1872 "offset of CompressedTexSubImage3DBucket zoffset should be 20");
1873 static_assert(offsetof(CompressedTexSubImage3DBucket
, width
) == 24,
1874 "offset of CompressedTexSubImage3DBucket width should be 24");
1875 static_assert(offsetof(CompressedTexSubImage3DBucket
, height
) == 28,
1876 "offset of CompressedTexSubImage3DBucket height should be 28");
1877 static_assert(offsetof(CompressedTexSubImage3DBucket
, depth
) == 32,
1878 "offset of CompressedTexSubImage3DBucket depth should be 32");
1879 static_assert(offsetof(CompressedTexSubImage3DBucket
, format
) == 36,
1880 "offset of CompressedTexSubImage3DBucket format should be 36");
1881 static_assert(offsetof(CompressedTexSubImage3DBucket
, bucket_id
) == 40,
1882 "offset of CompressedTexSubImage3DBucket bucket_id should be 40");
1884 struct CompressedTexSubImage3D
{
1885 typedef CompressedTexSubImage3D ValueType
;
1886 static const CommandId kCmdId
= kCompressedTexSubImage3D
;
1887 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1888 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
1890 static uint32_t ComputeSize() {
1891 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1894 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1896 void Init(GLenum _target
,
1906 uint32_t _data_shm_id
,
1907 uint32_t _data_shm_offset
) {
1918 imageSize
= _imageSize
;
1919 data_shm_id
= _data_shm_id
;
1920 data_shm_offset
= _data_shm_offset
;
1923 void* Set(void* cmd
,
1934 uint32_t _data_shm_id
,
1935 uint32_t _data_shm_offset
) {
1936 static_cast<ValueType
*>(cmd
)
1937 ->Init(_target
, _level
, _xoffset
, _yoffset
, _zoffset
, _width
, _height
,
1938 _depth
, _format
, _imageSize
, _data_shm_id
, _data_shm_offset
);
1939 return NextCmdAddress
<ValueType
>(cmd
);
1942 gpu::CommandHeader header
;
1953 uint32_t data_shm_id
;
1954 uint32_t data_shm_offset
;
1957 static_assert(sizeof(CompressedTexSubImage3D
) == 52,
1958 "size of CompressedTexSubImage3D should be 52");
1959 static_assert(offsetof(CompressedTexSubImage3D
, header
) == 0,
1960 "offset of CompressedTexSubImage3D header should be 0");
1961 static_assert(offsetof(CompressedTexSubImage3D
, target
) == 4,
1962 "offset of CompressedTexSubImage3D target should be 4");
1963 static_assert(offsetof(CompressedTexSubImage3D
, level
) == 8,
1964 "offset of CompressedTexSubImage3D level should be 8");
1965 static_assert(offsetof(CompressedTexSubImage3D
, xoffset
) == 12,
1966 "offset of CompressedTexSubImage3D xoffset should be 12");
1967 static_assert(offsetof(CompressedTexSubImage3D
, yoffset
) == 16,
1968 "offset of CompressedTexSubImage3D yoffset should be 16");
1969 static_assert(offsetof(CompressedTexSubImage3D
, zoffset
) == 20,
1970 "offset of CompressedTexSubImage3D zoffset should be 20");
1971 static_assert(offsetof(CompressedTexSubImage3D
, width
) == 24,
1972 "offset of CompressedTexSubImage3D width should be 24");
1973 static_assert(offsetof(CompressedTexSubImage3D
, height
) == 28,
1974 "offset of CompressedTexSubImage3D height should be 28");
1975 static_assert(offsetof(CompressedTexSubImage3D
, depth
) == 32,
1976 "offset of CompressedTexSubImage3D depth should be 32");
1977 static_assert(offsetof(CompressedTexSubImage3D
, format
) == 36,
1978 "offset of CompressedTexSubImage3D format should be 36");
1979 static_assert(offsetof(CompressedTexSubImage3D
, imageSize
) == 40,
1980 "offset of CompressedTexSubImage3D imageSize should be 40");
1981 static_assert(offsetof(CompressedTexSubImage3D
, data_shm_id
) == 44,
1982 "offset of CompressedTexSubImage3D data_shm_id should be 44");
1983 static_assert(offsetof(CompressedTexSubImage3D
, data_shm_offset
) == 48,
1984 "offset of CompressedTexSubImage3D data_shm_offset should be 48");
1986 struct CopyBufferSubData
{
1987 typedef CopyBufferSubData ValueType
;
1988 static const CommandId kCmdId
= kCopyBufferSubData
;
1989 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
1990 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
1992 static uint32_t ComputeSize() {
1993 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
1996 void SetHeader() { header
.SetCmd
<ValueType
>(); }
1998 void Init(GLenum _readtarget
,
1999 GLenum _writetarget
,
2000 GLintptr _readoffset
,
2001 GLintptr _writeoffset
,
2004 readtarget
= _readtarget
;
2005 writetarget
= _writetarget
;
2006 readoffset
= _readoffset
;
2007 writeoffset
= _writeoffset
;
2011 void* Set(void* cmd
,
2013 GLenum _writetarget
,
2014 GLintptr _readoffset
,
2015 GLintptr _writeoffset
,
2017 static_cast<ValueType
*>(cmd
)
2018 ->Init(_readtarget
, _writetarget
, _readoffset
, _writeoffset
, _size
);
2019 return NextCmdAddress
<ValueType
>(cmd
);
2022 gpu::CommandHeader header
;
2023 uint32_t readtarget
;
2024 uint32_t writetarget
;
2026 int32_t writeoffset
;
2030 static_assert(sizeof(CopyBufferSubData
) == 24,
2031 "size of CopyBufferSubData should be 24");
2032 static_assert(offsetof(CopyBufferSubData
, header
) == 0,
2033 "offset of CopyBufferSubData header should be 0");
2034 static_assert(offsetof(CopyBufferSubData
, readtarget
) == 4,
2035 "offset of CopyBufferSubData readtarget should be 4");
2036 static_assert(offsetof(CopyBufferSubData
, writetarget
) == 8,
2037 "offset of CopyBufferSubData writetarget should be 8");
2038 static_assert(offsetof(CopyBufferSubData
, readoffset
) == 12,
2039 "offset of CopyBufferSubData readoffset should be 12");
2040 static_assert(offsetof(CopyBufferSubData
, writeoffset
) == 16,
2041 "offset of CopyBufferSubData writeoffset should be 16");
2042 static_assert(offsetof(CopyBufferSubData
, size
) == 20,
2043 "offset of CopyBufferSubData size should be 20");
2045 struct CopyTexImage2D
{
2046 typedef CopyTexImage2D ValueType
;
2047 static const CommandId kCmdId
= kCopyTexImage2D
;
2048 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2049 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
2051 static uint32_t ComputeSize() {
2052 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2055 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2057 void Init(GLenum _target
,
2059 GLenum _internalformat
,
2067 internalformat
= _internalformat
;
2074 void* Set(void* cmd
,
2077 GLenum _internalformat
,
2082 static_cast<ValueType
*>(cmd
)
2083 ->Init(_target
, _level
, _internalformat
, _x
, _y
, _width
, _height
);
2084 return NextCmdAddress
<ValueType
>(cmd
);
2087 gpu::CommandHeader header
;
2090 uint32_t internalformat
;
2095 static const int32_t border
= 0;
2098 static_assert(sizeof(CopyTexImage2D
) == 32,
2099 "size of CopyTexImage2D should be 32");
2100 static_assert(offsetof(CopyTexImage2D
, header
) == 0,
2101 "offset of CopyTexImage2D header should be 0");
2102 static_assert(offsetof(CopyTexImage2D
, target
) == 4,
2103 "offset of CopyTexImage2D target should be 4");
2104 static_assert(offsetof(CopyTexImage2D
, level
) == 8,
2105 "offset of CopyTexImage2D level should be 8");
2106 static_assert(offsetof(CopyTexImage2D
, internalformat
) == 12,
2107 "offset of CopyTexImage2D internalformat should be 12");
2108 static_assert(offsetof(CopyTexImage2D
, x
) == 16,
2109 "offset of CopyTexImage2D x should be 16");
2110 static_assert(offsetof(CopyTexImage2D
, y
) == 20,
2111 "offset of CopyTexImage2D y should be 20");
2112 static_assert(offsetof(CopyTexImage2D
, width
) == 24,
2113 "offset of CopyTexImage2D width should be 24");
2114 static_assert(offsetof(CopyTexImage2D
, height
) == 28,
2115 "offset of CopyTexImage2D height should be 28");
2117 struct CopyTexSubImage2D
{
2118 typedef CopyTexSubImage2D ValueType
;
2119 static const CommandId kCmdId
= kCopyTexSubImage2D
;
2120 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2121 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
2123 static uint32_t ComputeSize() {
2124 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2127 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2129 void Init(GLenum _target
,
2148 void* Set(void* cmd
,
2157 static_cast<ValueType
*>(cmd
)
2158 ->Init(_target
, _level
, _xoffset
, _yoffset
, _x
, _y
, _width
, _height
);
2159 return NextCmdAddress
<ValueType
>(cmd
);
2162 gpu::CommandHeader header
;
2173 static_assert(sizeof(CopyTexSubImage2D
) == 36,
2174 "size of CopyTexSubImage2D should be 36");
2175 static_assert(offsetof(CopyTexSubImage2D
, header
) == 0,
2176 "offset of CopyTexSubImage2D header should be 0");
2177 static_assert(offsetof(CopyTexSubImage2D
, target
) == 4,
2178 "offset of CopyTexSubImage2D target should be 4");
2179 static_assert(offsetof(CopyTexSubImage2D
, level
) == 8,
2180 "offset of CopyTexSubImage2D level should be 8");
2181 static_assert(offsetof(CopyTexSubImage2D
, xoffset
) == 12,
2182 "offset of CopyTexSubImage2D xoffset should be 12");
2183 static_assert(offsetof(CopyTexSubImage2D
, yoffset
) == 16,
2184 "offset of CopyTexSubImage2D yoffset should be 16");
2185 static_assert(offsetof(CopyTexSubImage2D
, x
) == 20,
2186 "offset of CopyTexSubImage2D x should be 20");
2187 static_assert(offsetof(CopyTexSubImage2D
, y
) == 24,
2188 "offset of CopyTexSubImage2D y should be 24");
2189 static_assert(offsetof(CopyTexSubImage2D
, width
) == 28,
2190 "offset of CopyTexSubImage2D width should be 28");
2191 static_assert(offsetof(CopyTexSubImage2D
, height
) == 32,
2192 "offset of CopyTexSubImage2D height should be 32");
2194 struct CopyTexSubImage3D
{
2195 typedef CopyTexSubImage3D ValueType
;
2196 static const CommandId kCmdId
= kCopyTexSubImage3D
;
2197 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2198 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
2200 static uint32_t ComputeSize() {
2201 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2204 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2206 void Init(GLenum _target
,
2227 void* Set(void* cmd
,
2237 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _xoffset
, _yoffset
,
2238 _zoffset
, _x
, _y
, _width
, _height
);
2239 return NextCmdAddress
<ValueType
>(cmd
);
2242 gpu::CommandHeader header
;
2254 static_assert(sizeof(CopyTexSubImage3D
) == 40,
2255 "size of CopyTexSubImage3D should be 40");
2256 static_assert(offsetof(CopyTexSubImage3D
, header
) == 0,
2257 "offset of CopyTexSubImage3D header should be 0");
2258 static_assert(offsetof(CopyTexSubImage3D
, target
) == 4,
2259 "offset of CopyTexSubImage3D target should be 4");
2260 static_assert(offsetof(CopyTexSubImage3D
, level
) == 8,
2261 "offset of CopyTexSubImage3D level should be 8");
2262 static_assert(offsetof(CopyTexSubImage3D
, xoffset
) == 12,
2263 "offset of CopyTexSubImage3D xoffset should be 12");
2264 static_assert(offsetof(CopyTexSubImage3D
, yoffset
) == 16,
2265 "offset of CopyTexSubImage3D yoffset should be 16");
2266 static_assert(offsetof(CopyTexSubImage3D
, zoffset
) == 20,
2267 "offset of CopyTexSubImage3D zoffset should be 20");
2268 static_assert(offsetof(CopyTexSubImage3D
, x
) == 24,
2269 "offset of CopyTexSubImage3D x should be 24");
2270 static_assert(offsetof(CopyTexSubImage3D
, y
) == 28,
2271 "offset of CopyTexSubImage3D y should be 28");
2272 static_assert(offsetof(CopyTexSubImage3D
, width
) == 32,
2273 "offset of CopyTexSubImage3D width should be 32");
2274 static_assert(offsetof(CopyTexSubImage3D
, height
) == 36,
2275 "offset of CopyTexSubImage3D height should be 36");
2277 struct CreateProgram
{
2278 typedef CreateProgram ValueType
;
2279 static const CommandId kCmdId
= kCreateProgram
;
2280 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2281 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2283 static uint32_t ComputeSize() {
2284 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2287 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2289 void Init(uint32_t _client_id
) {
2291 client_id
= _client_id
;
2294 void* Set(void* cmd
, uint32_t _client_id
) {
2295 static_cast<ValueType
*>(cmd
)->Init(_client_id
);
2296 return NextCmdAddress
<ValueType
>(cmd
);
2299 gpu::CommandHeader header
;
2303 static_assert(sizeof(CreateProgram
) == 8, "size of CreateProgram should be 8");
2304 static_assert(offsetof(CreateProgram
, header
) == 0,
2305 "offset of CreateProgram header should be 0");
2306 static_assert(offsetof(CreateProgram
, client_id
) == 4,
2307 "offset of CreateProgram client_id should be 4");
2309 struct CreateShader
{
2310 typedef CreateShader ValueType
;
2311 static const CommandId kCmdId
= kCreateShader
;
2312 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2313 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2315 static uint32_t ComputeSize() {
2316 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2319 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2321 void Init(GLenum _type
, uint32_t _client_id
) {
2324 client_id
= _client_id
;
2327 void* Set(void* cmd
, GLenum _type
, uint32_t _client_id
) {
2328 static_cast<ValueType
*>(cmd
)->Init(_type
, _client_id
);
2329 return NextCmdAddress
<ValueType
>(cmd
);
2332 gpu::CommandHeader header
;
2337 static_assert(sizeof(CreateShader
) == 12, "size of CreateShader should be 12");
2338 static_assert(offsetof(CreateShader
, header
) == 0,
2339 "offset of CreateShader header should be 0");
2340 static_assert(offsetof(CreateShader
, type
) == 4,
2341 "offset of CreateShader type should be 4");
2342 static_assert(offsetof(CreateShader
, client_id
) == 8,
2343 "offset of CreateShader client_id should be 8");
2346 typedef CullFace ValueType
;
2347 static const CommandId kCmdId
= kCullFace
;
2348 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2349 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2351 static uint32_t ComputeSize() {
2352 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2355 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2357 void Init(GLenum _mode
) {
2362 void* Set(void* cmd
, GLenum _mode
) {
2363 static_cast<ValueType
*>(cmd
)->Init(_mode
);
2364 return NextCmdAddress
<ValueType
>(cmd
);
2367 gpu::CommandHeader header
;
2371 static_assert(sizeof(CullFace
) == 8, "size of CullFace should be 8");
2372 static_assert(offsetof(CullFace
, header
) == 0,
2373 "offset of CullFace header should be 0");
2374 static_assert(offsetof(CullFace
, mode
) == 4,
2375 "offset of CullFace mode should be 4");
2377 struct DeleteBuffersImmediate
{
2378 typedef DeleteBuffersImmediate ValueType
;
2379 static const CommandId kCmdId
= kDeleteBuffersImmediate
;
2380 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2381 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2383 static uint32_t ComputeDataSize(GLsizei n
) {
2384 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2387 static uint32_t ComputeSize(GLsizei n
) {
2388 return static_cast<uint32_t>(sizeof(ValueType
) +
2389 ComputeDataSize(n
)); // NOLINT
2392 void SetHeader(GLsizei n
) {
2393 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2396 void Init(GLsizei _n
, const GLuint
* _buffers
) {
2399 memcpy(ImmediateDataAddress(this), _buffers
, ComputeDataSize(_n
));
2402 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _buffers
) {
2403 static_cast<ValueType
*>(cmd
)->Init(_n
, _buffers
);
2404 const uint32_t size
= ComputeSize(_n
);
2405 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2408 gpu::CommandHeader header
;
2412 static_assert(sizeof(DeleteBuffersImmediate
) == 8,
2413 "size of DeleteBuffersImmediate should be 8");
2414 static_assert(offsetof(DeleteBuffersImmediate
, header
) == 0,
2415 "offset of DeleteBuffersImmediate header should be 0");
2416 static_assert(offsetof(DeleteBuffersImmediate
, n
) == 4,
2417 "offset of DeleteBuffersImmediate n should be 4");
2419 struct DeleteFramebuffersImmediate
{
2420 typedef DeleteFramebuffersImmediate ValueType
;
2421 static const CommandId kCmdId
= kDeleteFramebuffersImmediate
;
2422 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2423 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
2425 static uint32_t ComputeDataSize(GLsizei n
) {
2426 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2429 static uint32_t ComputeSize(GLsizei n
) {
2430 return static_cast<uint32_t>(sizeof(ValueType
) +
2431 ComputeDataSize(n
)); // NOLINT
2434 void SetHeader(GLsizei n
) {
2435 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2438 void Init(GLsizei _n
, const GLuint
* _framebuffers
) {
2441 memcpy(ImmediateDataAddress(this), _framebuffers
, ComputeDataSize(_n
));
2444 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _framebuffers
) {
2445 static_cast<ValueType
*>(cmd
)->Init(_n
, _framebuffers
);
2446 const uint32_t size
= ComputeSize(_n
);
2447 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2450 gpu::CommandHeader header
;
2454 static_assert(sizeof(DeleteFramebuffersImmediate
) == 8,
2455 "size of DeleteFramebuffersImmediate should be 8");
2456 static_assert(offsetof(DeleteFramebuffersImmediate
, header
) == 0,
2457 "offset of DeleteFramebuffersImmediate header should be 0");
2458 static_assert(offsetof(DeleteFramebuffersImmediate
, n
) == 4,
2459 "offset of DeleteFramebuffersImmediate n should be 4");
2461 struct DeleteProgram
{
2462 typedef DeleteProgram ValueType
;
2463 static const CommandId kCmdId
= kDeleteProgram
;
2464 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2465 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2467 static uint32_t ComputeSize() {
2468 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2471 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2473 void Init(GLuint _program
) {
2478 void* Set(void* cmd
, GLuint _program
) {
2479 static_cast<ValueType
*>(cmd
)->Init(_program
);
2480 return NextCmdAddress
<ValueType
>(cmd
);
2483 gpu::CommandHeader header
;
2487 static_assert(sizeof(DeleteProgram
) == 8, "size of DeleteProgram should be 8");
2488 static_assert(offsetof(DeleteProgram
, header
) == 0,
2489 "offset of DeleteProgram header should be 0");
2490 static_assert(offsetof(DeleteProgram
, program
) == 4,
2491 "offset of DeleteProgram program should be 4");
2493 struct DeleteRenderbuffersImmediate
{
2494 typedef DeleteRenderbuffersImmediate ValueType
;
2495 static const CommandId kCmdId
= kDeleteRenderbuffersImmediate
;
2496 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2497 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
2499 static uint32_t ComputeDataSize(GLsizei n
) {
2500 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2503 static uint32_t ComputeSize(GLsizei n
) {
2504 return static_cast<uint32_t>(sizeof(ValueType
) +
2505 ComputeDataSize(n
)); // NOLINT
2508 void SetHeader(GLsizei n
) {
2509 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2512 void Init(GLsizei _n
, const GLuint
* _renderbuffers
) {
2515 memcpy(ImmediateDataAddress(this), _renderbuffers
, ComputeDataSize(_n
));
2518 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _renderbuffers
) {
2519 static_cast<ValueType
*>(cmd
)->Init(_n
, _renderbuffers
);
2520 const uint32_t size
= ComputeSize(_n
);
2521 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2524 gpu::CommandHeader header
;
2528 static_assert(sizeof(DeleteRenderbuffersImmediate
) == 8,
2529 "size of DeleteRenderbuffersImmediate should be 8");
2530 static_assert(offsetof(DeleteRenderbuffersImmediate
, header
) == 0,
2531 "offset of DeleteRenderbuffersImmediate header should be 0");
2532 static_assert(offsetof(DeleteRenderbuffersImmediate
, n
) == 4,
2533 "offset of DeleteRenderbuffersImmediate n should be 4");
2535 struct DeleteSamplersImmediate
{
2536 typedef DeleteSamplersImmediate ValueType
;
2537 static const CommandId kCmdId
= kDeleteSamplersImmediate
;
2538 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2539 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2541 static uint32_t ComputeDataSize(GLsizei n
) {
2542 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2545 static uint32_t ComputeSize(GLsizei n
) {
2546 return static_cast<uint32_t>(sizeof(ValueType
) +
2547 ComputeDataSize(n
)); // NOLINT
2550 void SetHeader(GLsizei n
) {
2551 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2554 void Init(GLsizei _n
, const GLuint
* _samplers
) {
2557 memcpy(ImmediateDataAddress(this), _samplers
, ComputeDataSize(_n
));
2560 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _samplers
) {
2561 static_cast<ValueType
*>(cmd
)->Init(_n
, _samplers
);
2562 const uint32_t size
= ComputeSize(_n
);
2563 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2566 gpu::CommandHeader header
;
2570 static_assert(sizeof(DeleteSamplersImmediate
) == 8,
2571 "size of DeleteSamplersImmediate should be 8");
2572 static_assert(offsetof(DeleteSamplersImmediate
, header
) == 0,
2573 "offset of DeleteSamplersImmediate header should be 0");
2574 static_assert(offsetof(DeleteSamplersImmediate
, n
) == 4,
2575 "offset of DeleteSamplersImmediate n should be 4");
2578 typedef DeleteSync ValueType
;
2579 static const CommandId kCmdId
= kDeleteSync
;
2580 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2581 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2583 static uint32_t ComputeSize() {
2584 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2587 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2589 void Init(GLuint _sync
) {
2594 void* Set(void* cmd
, GLuint _sync
) {
2595 static_cast<ValueType
*>(cmd
)->Init(_sync
);
2596 return NextCmdAddress
<ValueType
>(cmd
);
2599 gpu::CommandHeader header
;
2603 static_assert(sizeof(DeleteSync
) == 8, "size of DeleteSync should be 8");
2604 static_assert(offsetof(DeleteSync
, header
) == 0,
2605 "offset of DeleteSync header should be 0");
2606 static_assert(offsetof(DeleteSync
, sync
) == 4,
2607 "offset of DeleteSync sync should be 4");
2609 struct DeleteShader
{
2610 typedef DeleteShader ValueType
;
2611 static const CommandId kCmdId
= kDeleteShader
;
2612 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2613 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2615 static uint32_t ComputeSize() {
2616 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2619 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2621 void Init(GLuint _shader
) {
2626 void* Set(void* cmd
, GLuint _shader
) {
2627 static_cast<ValueType
*>(cmd
)->Init(_shader
);
2628 return NextCmdAddress
<ValueType
>(cmd
);
2631 gpu::CommandHeader header
;
2635 static_assert(sizeof(DeleteShader
) == 8, "size of DeleteShader should be 8");
2636 static_assert(offsetof(DeleteShader
, header
) == 0,
2637 "offset of DeleteShader header should be 0");
2638 static_assert(offsetof(DeleteShader
, shader
) == 4,
2639 "offset of DeleteShader shader should be 4");
2641 struct DeleteTexturesImmediate
{
2642 typedef DeleteTexturesImmediate ValueType
;
2643 static const CommandId kCmdId
= kDeleteTexturesImmediate
;
2644 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2645 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2647 static uint32_t ComputeDataSize(GLsizei n
) {
2648 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2651 static uint32_t ComputeSize(GLsizei n
) {
2652 return static_cast<uint32_t>(sizeof(ValueType
) +
2653 ComputeDataSize(n
)); // NOLINT
2656 void SetHeader(GLsizei n
) {
2657 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2660 void Init(GLsizei _n
, const GLuint
* _textures
) {
2663 memcpy(ImmediateDataAddress(this), _textures
, ComputeDataSize(_n
));
2666 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _textures
) {
2667 static_cast<ValueType
*>(cmd
)->Init(_n
, _textures
);
2668 const uint32_t size
= ComputeSize(_n
);
2669 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2672 gpu::CommandHeader header
;
2676 static_assert(sizeof(DeleteTexturesImmediate
) == 8,
2677 "size of DeleteTexturesImmediate should be 8");
2678 static_assert(offsetof(DeleteTexturesImmediate
, header
) == 0,
2679 "offset of DeleteTexturesImmediate header should be 0");
2680 static_assert(offsetof(DeleteTexturesImmediate
, n
) == 4,
2681 "offset of DeleteTexturesImmediate n should be 4");
2683 struct DeleteTransformFeedbacksImmediate
{
2684 typedef DeleteTransformFeedbacksImmediate ValueType
;
2685 static const CommandId kCmdId
= kDeleteTransformFeedbacksImmediate
;
2686 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
2687 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2689 static uint32_t ComputeDataSize(GLsizei n
) {
2690 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
2693 static uint32_t ComputeSize(GLsizei n
) {
2694 return static_cast<uint32_t>(sizeof(ValueType
) +
2695 ComputeDataSize(n
)); // NOLINT
2698 void SetHeader(GLsizei n
) {
2699 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
2702 void Init(GLsizei _n
, const GLuint
* _ids
) {
2705 memcpy(ImmediateDataAddress(this), _ids
, ComputeDataSize(_n
));
2708 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _ids
) {
2709 static_cast<ValueType
*>(cmd
)->Init(_n
, _ids
);
2710 const uint32_t size
= ComputeSize(_n
);
2711 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
2714 gpu::CommandHeader header
;
2718 static_assert(sizeof(DeleteTransformFeedbacksImmediate
) == 8,
2719 "size of DeleteTransformFeedbacksImmediate should be 8");
2720 static_assert(offsetof(DeleteTransformFeedbacksImmediate
, header
) == 0,
2721 "offset of DeleteTransformFeedbacksImmediate header should be 0");
2722 static_assert(offsetof(DeleteTransformFeedbacksImmediate
, n
) == 4,
2723 "offset of DeleteTransformFeedbacksImmediate n should be 4");
2726 typedef DepthFunc ValueType
;
2727 static const CommandId kCmdId
= kDepthFunc
;
2728 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2729 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2731 static uint32_t ComputeSize() {
2732 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2735 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2737 void Init(GLenum _func
) {
2742 void* Set(void* cmd
, GLenum _func
) {
2743 static_cast<ValueType
*>(cmd
)->Init(_func
);
2744 return NextCmdAddress
<ValueType
>(cmd
);
2747 gpu::CommandHeader header
;
2751 static_assert(sizeof(DepthFunc
) == 8, "size of DepthFunc should be 8");
2752 static_assert(offsetof(DepthFunc
, header
) == 0,
2753 "offset of DepthFunc header should be 0");
2754 static_assert(offsetof(DepthFunc
, func
) == 4,
2755 "offset of DepthFunc func should be 4");
2758 typedef DepthMask ValueType
;
2759 static const CommandId kCmdId
= kDepthMask
;
2760 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2761 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2763 static uint32_t ComputeSize() {
2764 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2767 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2769 void Init(GLboolean _flag
) {
2774 void* Set(void* cmd
, GLboolean _flag
) {
2775 static_cast<ValueType
*>(cmd
)->Init(_flag
);
2776 return NextCmdAddress
<ValueType
>(cmd
);
2779 gpu::CommandHeader header
;
2783 static_assert(sizeof(DepthMask
) == 8, "size of DepthMask should be 8");
2784 static_assert(offsetof(DepthMask
, header
) == 0,
2785 "offset of DepthMask header should be 0");
2786 static_assert(offsetof(DepthMask
, flag
) == 4,
2787 "offset of DepthMask flag should be 4");
2789 struct DepthRangef
{
2790 typedef DepthRangef ValueType
;
2791 static const CommandId kCmdId
= kDepthRangef
;
2792 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2793 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2795 static uint32_t ComputeSize() {
2796 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2799 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2801 void Init(GLclampf _zNear
, GLclampf _zFar
) {
2807 void* Set(void* cmd
, GLclampf _zNear
, GLclampf _zFar
) {
2808 static_cast<ValueType
*>(cmd
)->Init(_zNear
, _zFar
);
2809 return NextCmdAddress
<ValueType
>(cmd
);
2812 gpu::CommandHeader header
;
2817 static_assert(sizeof(DepthRangef
) == 12, "size of DepthRangef should be 12");
2818 static_assert(offsetof(DepthRangef
, header
) == 0,
2819 "offset of DepthRangef header should be 0");
2820 static_assert(offsetof(DepthRangef
, zNear
) == 4,
2821 "offset of DepthRangef zNear should be 4");
2822 static_assert(offsetof(DepthRangef
, zFar
) == 8,
2823 "offset of DepthRangef zFar should be 8");
2825 struct DetachShader
{
2826 typedef DetachShader ValueType
;
2827 static const CommandId kCmdId
= kDetachShader
;
2828 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2829 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2831 static uint32_t ComputeSize() {
2832 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2835 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2837 void Init(GLuint _program
, GLuint _shader
) {
2843 void* Set(void* cmd
, GLuint _program
, GLuint _shader
) {
2844 static_cast<ValueType
*>(cmd
)->Init(_program
, _shader
);
2845 return NextCmdAddress
<ValueType
>(cmd
);
2848 gpu::CommandHeader header
;
2853 static_assert(sizeof(DetachShader
) == 12, "size of DetachShader should be 12");
2854 static_assert(offsetof(DetachShader
, header
) == 0,
2855 "offset of DetachShader header should be 0");
2856 static_assert(offsetof(DetachShader
, program
) == 4,
2857 "offset of DetachShader program should be 4");
2858 static_assert(offsetof(DetachShader
, shader
) == 8,
2859 "offset of DetachShader shader should be 8");
2862 typedef Disable ValueType
;
2863 static const CommandId kCmdId
= kDisable
;
2864 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2865 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2867 static uint32_t ComputeSize() {
2868 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2871 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2873 void Init(GLenum _cap
) {
2878 void* Set(void* cmd
, GLenum _cap
) {
2879 static_cast<ValueType
*>(cmd
)->Init(_cap
);
2880 return NextCmdAddress
<ValueType
>(cmd
);
2883 gpu::CommandHeader header
;
2887 static_assert(sizeof(Disable
) == 8, "size of Disable should be 8");
2888 static_assert(offsetof(Disable
, header
) == 0,
2889 "offset of Disable header should be 0");
2890 static_assert(offsetof(Disable
, cap
) == 4, "offset of Disable cap should be 4");
2892 struct DisableVertexAttribArray
{
2893 typedef DisableVertexAttribArray ValueType
;
2894 static const CommandId kCmdId
= kDisableVertexAttribArray
;
2895 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2896 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
2898 static uint32_t ComputeSize() {
2899 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2902 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2904 void Init(GLuint _index
) {
2909 void* Set(void* cmd
, GLuint _index
) {
2910 static_cast<ValueType
*>(cmd
)->Init(_index
);
2911 return NextCmdAddress
<ValueType
>(cmd
);
2914 gpu::CommandHeader header
;
2918 static_assert(sizeof(DisableVertexAttribArray
) == 8,
2919 "size of DisableVertexAttribArray should be 8");
2920 static_assert(offsetof(DisableVertexAttribArray
, header
) == 0,
2921 "offset of DisableVertexAttribArray header should be 0");
2922 static_assert(offsetof(DisableVertexAttribArray
, index
) == 4,
2923 "offset of DisableVertexAttribArray index should be 4");
2926 typedef DrawArrays ValueType
;
2927 static const CommandId kCmdId
= kDrawArrays
;
2928 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2929 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
2931 static uint32_t ComputeSize() {
2932 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2935 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2937 void Init(GLenum _mode
, GLint _first
, GLsizei _count
) {
2944 void* Set(void* cmd
, GLenum _mode
, GLint _first
, GLsizei _count
) {
2945 static_cast<ValueType
*>(cmd
)->Init(_mode
, _first
, _count
);
2946 return NextCmdAddress
<ValueType
>(cmd
);
2949 gpu::CommandHeader header
;
2955 static_assert(sizeof(DrawArrays
) == 16, "size of DrawArrays should be 16");
2956 static_assert(offsetof(DrawArrays
, header
) == 0,
2957 "offset of DrawArrays header should be 0");
2958 static_assert(offsetof(DrawArrays
, mode
) == 4,
2959 "offset of DrawArrays mode should be 4");
2960 static_assert(offsetof(DrawArrays
, first
) == 8,
2961 "offset of DrawArrays first should be 8");
2962 static_assert(offsetof(DrawArrays
, count
) == 12,
2963 "offset of DrawArrays count should be 12");
2965 struct DrawElements
{
2966 typedef DrawElements ValueType
;
2967 static const CommandId kCmdId
= kDrawElements
;
2968 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
2969 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
2971 static uint32_t ComputeSize() {
2972 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
2975 void SetHeader() { header
.SetCmd
<ValueType
>(); }
2977 void Init(GLenum _mode
, GLsizei _count
, GLenum _type
, GLuint _index_offset
) {
2982 index_offset
= _index_offset
;
2985 void* Set(void* cmd
,
2989 GLuint _index_offset
) {
2990 static_cast<ValueType
*>(cmd
)->Init(_mode
, _count
, _type
, _index_offset
);
2991 return NextCmdAddress
<ValueType
>(cmd
);
2994 gpu::CommandHeader header
;
2998 uint32_t index_offset
;
3001 static_assert(sizeof(DrawElements
) == 20, "size of DrawElements should be 20");
3002 static_assert(offsetof(DrawElements
, header
) == 0,
3003 "offset of DrawElements header should be 0");
3004 static_assert(offsetof(DrawElements
, mode
) == 4,
3005 "offset of DrawElements mode should be 4");
3006 static_assert(offsetof(DrawElements
, count
) == 8,
3007 "offset of DrawElements count should be 8");
3008 static_assert(offsetof(DrawElements
, type
) == 12,
3009 "offset of DrawElements type should be 12");
3010 static_assert(offsetof(DrawElements
, index_offset
) == 16,
3011 "offset of DrawElements index_offset should be 16");
3014 typedef Enable ValueType
;
3015 static const CommandId kCmdId
= kEnable
;
3016 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3017 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3019 static uint32_t ComputeSize() {
3020 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3023 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3025 void Init(GLenum _cap
) {
3030 void* Set(void* cmd
, GLenum _cap
) {
3031 static_cast<ValueType
*>(cmd
)->Init(_cap
);
3032 return NextCmdAddress
<ValueType
>(cmd
);
3035 gpu::CommandHeader header
;
3039 static_assert(sizeof(Enable
) == 8, "size of Enable should be 8");
3040 static_assert(offsetof(Enable
, header
) == 0,
3041 "offset of Enable header should be 0");
3042 static_assert(offsetof(Enable
, cap
) == 4, "offset of Enable cap should be 4");
3044 struct EnableVertexAttribArray
{
3045 typedef EnableVertexAttribArray ValueType
;
3046 static const CommandId kCmdId
= kEnableVertexAttribArray
;
3047 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3048 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3050 static uint32_t ComputeSize() {
3051 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3054 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3056 void Init(GLuint _index
) {
3061 void* Set(void* cmd
, GLuint _index
) {
3062 static_cast<ValueType
*>(cmd
)->Init(_index
);
3063 return NextCmdAddress
<ValueType
>(cmd
);
3066 gpu::CommandHeader header
;
3070 static_assert(sizeof(EnableVertexAttribArray
) == 8,
3071 "size of EnableVertexAttribArray should be 8");
3072 static_assert(offsetof(EnableVertexAttribArray
, header
) == 0,
3073 "offset of EnableVertexAttribArray header should be 0");
3074 static_assert(offsetof(EnableVertexAttribArray
, index
) == 4,
3075 "offset of EnableVertexAttribArray index should be 4");
3078 typedef FenceSync ValueType
;
3079 static const CommandId kCmdId
= kFenceSync
;
3080 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3081 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3083 static uint32_t ComputeSize() {
3084 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3087 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3089 void Init(uint32_t _client_id
) {
3091 client_id
= _client_id
;
3094 void* Set(void* cmd
, uint32_t _client_id
) {
3095 static_cast<ValueType
*>(cmd
)->Init(_client_id
);
3096 return NextCmdAddress
<ValueType
>(cmd
);
3099 gpu::CommandHeader header
;
3101 static const uint32_t condition
= GL_SYNC_GPU_COMMANDS_COMPLETE
;
3102 static const uint32_t flags
= 0;
3105 static_assert(sizeof(FenceSync
) == 8, "size of FenceSync should be 8");
3106 static_assert(offsetof(FenceSync
, header
) == 0,
3107 "offset of FenceSync header should be 0");
3108 static_assert(offsetof(FenceSync
, client_id
) == 4,
3109 "offset of FenceSync client_id should be 4");
3112 typedef Finish ValueType
;
3113 static const CommandId kCmdId
= kFinish
;
3114 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3115 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3117 static uint32_t ComputeSize() {
3118 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3121 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3123 void Init() { SetHeader(); }
3125 void* Set(void* cmd
) {
3126 static_cast<ValueType
*>(cmd
)->Init();
3127 return NextCmdAddress
<ValueType
>(cmd
);
3130 gpu::CommandHeader header
;
3133 static_assert(sizeof(Finish
) == 4, "size of Finish should be 4");
3134 static_assert(offsetof(Finish
, header
) == 0,
3135 "offset of Finish header should be 0");
3138 typedef Flush ValueType
;
3139 static const CommandId kCmdId
= kFlush
;
3140 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3141 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3143 static uint32_t ComputeSize() {
3144 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3147 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3149 void Init() { SetHeader(); }
3151 void* Set(void* cmd
) {
3152 static_cast<ValueType
*>(cmd
)->Init();
3153 return NextCmdAddress
<ValueType
>(cmd
);
3156 gpu::CommandHeader header
;
3159 static_assert(sizeof(Flush
) == 4, "size of Flush should be 4");
3160 static_assert(offsetof(Flush
, header
) == 0,
3161 "offset of Flush header should be 0");
3163 struct FramebufferRenderbuffer
{
3164 typedef FramebufferRenderbuffer ValueType
;
3165 static const CommandId kCmdId
= kFramebufferRenderbuffer
;
3166 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3167 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3169 static uint32_t ComputeSize() {
3170 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3173 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3175 void Init(GLenum _target
,
3177 GLenum _renderbuffertarget
,
3178 GLuint _renderbuffer
) {
3181 attachment
= _attachment
;
3182 renderbuffertarget
= _renderbuffertarget
;
3183 renderbuffer
= _renderbuffer
;
3186 void* Set(void* cmd
,
3189 GLenum _renderbuffertarget
,
3190 GLuint _renderbuffer
) {
3191 static_cast<ValueType
*>(cmd
)
3192 ->Init(_target
, _attachment
, _renderbuffertarget
, _renderbuffer
);
3193 return NextCmdAddress
<ValueType
>(cmd
);
3196 gpu::CommandHeader header
;
3198 uint32_t attachment
;
3199 uint32_t renderbuffertarget
;
3200 uint32_t renderbuffer
;
3203 static_assert(sizeof(FramebufferRenderbuffer
) == 20,
3204 "size of FramebufferRenderbuffer should be 20");
3205 static_assert(offsetof(FramebufferRenderbuffer
, header
) == 0,
3206 "offset of FramebufferRenderbuffer header should be 0");
3207 static_assert(offsetof(FramebufferRenderbuffer
, target
) == 4,
3208 "offset of FramebufferRenderbuffer target should be 4");
3209 static_assert(offsetof(FramebufferRenderbuffer
, attachment
) == 8,
3210 "offset of FramebufferRenderbuffer attachment should be 8");
3212 offsetof(FramebufferRenderbuffer
, renderbuffertarget
) == 12,
3213 "offset of FramebufferRenderbuffer renderbuffertarget should be 12");
3214 static_assert(offsetof(FramebufferRenderbuffer
, renderbuffer
) == 16,
3215 "offset of FramebufferRenderbuffer renderbuffer should be 16");
3217 struct FramebufferTexture2D
{
3218 typedef FramebufferTexture2D ValueType
;
3219 static const CommandId kCmdId
= kFramebufferTexture2D
;
3220 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3221 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3223 static uint32_t ComputeSize() {
3224 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3227 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3229 void Init(GLenum _target
,
3235 attachment
= _attachment
;
3236 textarget
= _textarget
;
3240 void* Set(void* cmd
,
3245 static_cast<ValueType
*>(cmd
)
3246 ->Init(_target
, _attachment
, _textarget
, _texture
);
3247 return NextCmdAddress
<ValueType
>(cmd
);
3250 gpu::CommandHeader header
;
3252 uint32_t attachment
;
3255 static const int32_t level
= 0;
3258 static_assert(sizeof(FramebufferTexture2D
) == 20,
3259 "size of FramebufferTexture2D should be 20");
3260 static_assert(offsetof(FramebufferTexture2D
, header
) == 0,
3261 "offset of FramebufferTexture2D header should be 0");
3262 static_assert(offsetof(FramebufferTexture2D
, target
) == 4,
3263 "offset of FramebufferTexture2D target should be 4");
3264 static_assert(offsetof(FramebufferTexture2D
, attachment
) == 8,
3265 "offset of FramebufferTexture2D attachment should be 8");
3266 static_assert(offsetof(FramebufferTexture2D
, textarget
) == 12,
3267 "offset of FramebufferTexture2D textarget should be 12");
3268 static_assert(offsetof(FramebufferTexture2D
, texture
) == 16,
3269 "offset of FramebufferTexture2D texture should be 16");
3271 struct FramebufferTextureLayer
{
3272 typedef FramebufferTextureLayer ValueType
;
3273 static const CommandId kCmdId
= kFramebufferTextureLayer
;
3274 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3275 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3277 static uint32_t ComputeSize() {
3278 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3281 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3283 void Init(GLenum _target
,
3290 attachment
= _attachment
;
3296 void* Set(void* cmd
,
3302 static_cast<ValueType
*>(cmd
)
3303 ->Init(_target
, _attachment
, _texture
, _level
, _layer
);
3304 return NextCmdAddress
<ValueType
>(cmd
);
3307 gpu::CommandHeader header
;
3309 uint32_t attachment
;
3315 static_assert(sizeof(FramebufferTextureLayer
) == 24,
3316 "size of FramebufferTextureLayer should be 24");
3317 static_assert(offsetof(FramebufferTextureLayer
, header
) == 0,
3318 "offset of FramebufferTextureLayer header should be 0");
3319 static_assert(offsetof(FramebufferTextureLayer
, target
) == 4,
3320 "offset of FramebufferTextureLayer target should be 4");
3321 static_assert(offsetof(FramebufferTextureLayer
, attachment
) == 8,
3322 "offset of FramebufferTextureLayer attachment should be 8");
3323 static_assert(offsetof(FramebufferTextureLayer
, texture
) == 12,
3324 "offset of FramebufferTextureLayer texture should be 12");
3325 static_assert(offsetof(FramebufferTextureLayer
, level
) == 16,
3326 "offset of FramebufferTextureLayer level should be 16");
3327 static_assert(offsetof(FramebufferTextureLayer
, layer
) == 20,
3328 "offset of FramebufferTextureLayer layer should be 20");
3331 typedef FrontFace ValueType
;
3332 static const CommandId kCmdId
= kFrontFace
;
3333 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3334 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3336 static uint32_t ComputeSize() {
3337 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3340 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3342 void Init(GLenum _mode
) {
3347 void* Set(void* cmd
, GLenum _mode
) {
3348 static_cast<ValueType
*>(cmd
)->Init(_mode
);
3349 return NextCmdAddress
<ValueType
>(cmd
);
3352 gpu::CommandHeader header
;
3356 static_assert(sizeof(FrontFace
) == 8, "size of FrontFace should be 8");
3357 static_assert(offsetof(FrontFace
, header
) == 0,
3358 "offset of FrontFace header should be 0");
3359 static_assert(offsetof(FrontFace
, mode
) == 4,
3360 "offset of FrontFace mode should be 4");
3362 struct GenBuffersImmediate
{
3363 typedef GenBuffersImmediate ValueType
;
3364 static const CommandId kCmdId
= kGenBuffersImmediate
;
3365 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3366 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3368 static uint32_t ComputeDataSize(GLsizei n
) {
3369 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3372 static uint32_t ComputeSize(GLsizei n
) {
3373 return static_cast<uint32_t>(sizeof(ValueType
) +
3374 ComputeDataSize(n
)); // NOLINT
3377 void SetHeader(GLsizei n
) {
3378 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3381 void Init(GLsizei _n
, GLuint
* _buffers
) {
3384 memcpy(ImmediateDataAddress(this), _buffers
, ComputeDataSize(_n
));
3387 void* Set(void* cmd
, GLsizei _n
, GLuint
* _buffers
) {
3388 static_cast<ValueType
*>(cmd
)->Init(_n
, _buffers
);
3389 const uint32_t size
= ComputeSize(_n
);
3390 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3393 gpu::CommandHeader header
;
3397 static_assert(sizeof(GenBuffersImmediate
) == 8,
3398 "size of GenBuffersImmediate should be 8");
3399 static_assert(offsetof(GenBuffersImmediate
, header
) == 0,
3400 "offset of GenBuffersImmediate header should be 0");
3401 static_assert(offsetof(GenBuffersImmediate
, n
) == 4,
3402 "offset of GenBuffersImmediate n should be 4");
3404 struct GenerateMipmap
{
3405 typedef GenerateMipmap ValueType
;
3406 static const CommandId kCmdId
= kGenerateMipmap
;
3407 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3408 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
3410 static uint32_t ComputeSize() {
3411 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3414 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3416 void Init(GLenum _target
) {
3421 void* Set(void* cmd
, GLenum _target
) {
3422 static_cast<ValueType
*>(cmd
)->Init(_target
);
3423 return NextCmdAddress
<ValueType
>(cmd
);
3426 gpu::CommandHeader header
;
3430 static_assert(sizeof(GenerateMipmap
) == 8,
3431 "size of GenerateMipmap should be 8");
3432 static_assert(offsetof(GenerateMipmap
, header
) == 0,
3433 "offset of GenerateMipmap header should be 0");
3434 static_assert(offsetof(GenerateMipmap
, target
) == 4,
3435 "offset of GenerateMipmap target should be 4");
3437 struct GenFramebuffersImmediate
{
3438 typedef GenFramebuffersImmediate ValueType
;
3439 static const CommandId kCmdId
= kGenFramebuffersImmediate
;
3440 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3441 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3443 static uint32_t ComputeDataSize(GLsizei n
) {
3444 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3447 static uint32_t ComputeSize(GLsizei n
) {
3448 return static_cast<uint32_t>(sizeof(ValueType
) +
3449 ComputeDataSize(n
)); // NOLINT
3452 void SetHeader(GLsizei n
) {
3453 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3456 void Init(GLsizei _n
, GLuint
* _framebuffers
) {
3459 memcpy(ImmediateDataAddress(this), _framebuffers
, ComputeDataSize(_n
));
3462 void* Set(void* cmd
, GLsizei _n
, GLuint
* _framebuffers
) {
3463 static_cast<ValueType
*>(cmd
)->Init(_n
, _framebuffers
);
3464 const uint32_t size
= ComputeSize(_n
);
3465 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3468 gpu::CommandHeader header
;
3472 static_assert(sizeof(GenFramebuffersImmediate
) == 8,
3473 "size of GenFramebuffersImmediate should be 8");
3474 static_assert(offsetof(GenFramebuffersImmediate
, header
) == 0,
3475 "offset of GenFramebuffersImmediate header should be 0");
3476 static_assert(offsetof(GenFramebuffersImmediate
, n
) == 4,
3477 "offset of GenFramebuffersImmediate n should be 4");
3479 struct GenRenderbuffersImmediate
{
3480 typedef GenRenderbuffersImmediate ValueType
;
3481 static const CommandId kCmdId
= kGenRenderbuffersImmediate
;
3482 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3483 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3485 static uint32_t ComputeDataSize(GLsizei n
) {
3486 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3489 static uint32_t ComputeSize(GLsizei n
) {
3490 return static_cast<uint32_t>(sizeof(ValueType
) +
3491 ComputeDataSize(n
)); // NOLINT
3494 void SetHeader(GLsizei n
) {
3495 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3498 void Init(GLsizei _n
, GLuint
* _renderbuffers
) {
3501 memcpy(ImmediateDataAddress(this), _renderbuffers
, ComputeDataSize(_n
));
3504 void* Set(void* cmd
, GLsizei _n
, GLuint
* _renderbuffers
) {
3505 static_cast<ValueType
*>(cmd
)->Init(_n
, _renderbuffers
);
3506 const uint32_t size
= ComputeSize(_n
);
3507 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3510 gpu::CommandHeader header
;
3514 static_assert(sizeof(GenRenderbuffersImmediate
) == 8,
3515 "size of GenRenderbuffersImmediate should be 8");
3516 static_assert(offsetof(GenRenderbuffersImmediate
, header
) == 0,
3517 "offset of GenRenderbuffersImmediate header should be 0");
3518 static_assert(offsetof(GenRenderbuffersImmediate
, n
) == 4,
3519 "offset of GenRenderbuffersImmediate n should be 4");
3521 struct GenSamplersImmediate
{
3522 typedef GenSamplersImmediate ValueType
;
3523 static const CommandId kCmdId
= kGenSamplersImmediate
;
3524 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3525 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3527 static uint32_t ComputeDataSize(GLsizei n
) {
3528 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3531 static uint32_t ComputeSize(GLsizei n
) {
3532 return static_cast<uint32_t>(sizeof(ValueType
) +
3533 ComputeDataSize(n
)); // NOLINT
3536 void SetHeader(GLsizei n
) {
3537 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3540 void Init(GLsizei _n
, GLuint
* _samplers
) {
3543 memcpy(ImmediateDataAddress(this), _samplers
, ComputeDataSize(_n
));
3546 void* Set(void* cmd
, GLsizei _n
, GLuint
* _samplers
) {
3547 static_cast<ValueType
*>(cmd
)->Init(_n
, _samplers
);
3548 const uint32_t size
= ComputeSize(_n
);
3549 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3552 gpu::CommandHeader header
;
3556 static_assert(sizeof(GenSamplersImmediate
) == 8,
3557 "size of GenSamplersImmediate should be 8");
3558 static_assert(offsetof(GenSamplersImmediate
, header
) == 0,
3559 "offset of GenSamplersImmediate header should be 0");
3560 static_assert(offsetof(GenSamplersImmediate
, n
) == 4,
3561 "offset of GenSamplersImmediate n should be 4");
3563 struct GenTexturesImmediate
{
3564 typedef GenTexturesImmediate ValueType
;
3565 static const CommandId kCmdId
= kGenTexturesImmediate
;
3566 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3567 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3569 static uint32_t ComputeDataSize(GLsizei n
) {
3570 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3573 static uint32_t ComputeSize(GLsizei n
) {
3574 return static_cast<uint32_t>(sizeof(ValueType
) +
3575 ComputeDataSize(n
)); // NOLINT
3578 void SetHeader(GLsizei n
) {
3579 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3582 void Init(GLsizei _n
, GLuint
* _textures
) {
3585 memcpy(ImmediateDataAddress(this), _textures
, ComputeDataSize(_n
));
3588 void* Set(void* cmd
, GLsizei _n
, GLuint
* _textures
) {
3589 static_cast<ValueType
*>(cmd
)->Init(_n
, _textures
);
3590 const uint32_t size
= ComputeSize(_n
);
3591 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3594 gpu::CommandHeader header
;
3598 static_assert(sizeof(GenTexturesImmediate
) == 8,
3599 "size of GenTexturesImmediate should be 8");
3600 static_assert(offsetof(GenTexturesImmediate
, header
) == 0,
3601 "offset of GenTexturesImmediate header should be 0");
3602 static_assert(offsetof(GenTexturesImmediate
, n
) == 4,
3603 "offset of GenTexturesImmediate n should be 4");
3605 struct GenTransformFeedbacksImmediate
{
3606 typedef GenTransformFeedbacksImmediate ValueType
;
3607 static const CommandId kCmdId
= kGenTransformFeedbacksImmediate
;
3608 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
3609 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3611 static uint32_t ComputeDataSize(GLsizei n
) {
3612 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
3615 static uint32_t ComputeSize(GLsizei n
) {
3616 return static_cast<uint32_t>(sizeof(ValueType
) +
3617 ComputeDataSize(n
)); // NOLINT
3620 void SetHeader(GLsizei n
) {
3621 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
3624 void Init(GLsizei _n
, GLuint
* _ids
) {
3627 memcpy(ImmediateDataAddress(this), _ids
, ComputeDataSize(_n
));
3630 void* Set(void* cmd
, GLsizei _n
, GLuint
* _ids
) {
3631 static_cast<ValueType
*>(cmd
)->Init(_n
, _ids
);
3632 const uint32_t size
= ComputeSize(_n
);
3633 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
3636 gpu::CommandHeader header
;
3640 static_assert(sizeof(GenTransformFeedbacksImmediate
) == 8,
3641 "size of GenTransformFeedbacksImmediate should be 8");
3642 static_assert(offsetof(GenTransformFeedbacksImmediate
, header
) == 0,
3643 "offset of GenTransformFeedbacksImmediate header should be 0");
3644 static_assert(offsetof(GenTransformFeedbacksImmediate
, n
) == 4,
3645 "offset of GenTransformFeedbacksImmediate n should be 4");
3647 struct GetActiveAttrib
{
3648 typedef GetActiveAttrib ValueType
;
3649 static const CommandId kCmdId
= kGetActiveAttrib
;
3650 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3651 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3659 static uint32_t ComputeSize() {
3660 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3663 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3665 void Init(GLuint _program
,
3667 uint32_t _name_bucket_id
,
3668 uint32_t _result_shm_id
,
3669 uint32_t _result_shm_offset
) {
3673 name_bucket_id
= _name_bucket_id
;
3674 result_shm_id
= _result_shm_id
;
3675 result_shm_offset
= _result_shm_offset
;
3678 void* Set(void* cmd
,
3681 uint32_t _name_bucket_id
,
3682 uint32_t _result_shm_id
,
3683 uint32_t _result_shm_offset
) {
3684 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _name_bucket_id
,
3685 _result_shm_id
, _result_shm_offset
);
3686 return NextCmdAddress
<ValueType
>(cmd
);
3689 gpu::CommandHeader header
;
3692 uint32_t name_bucket_id
;
3693 uint32_t result_shm_id
;
3694 uint32_t result_shm_offset
;
3697 static_assert(sizeof(GetActiveAttrib
) == 24,
3698 "size of GetActiveAttrib should be 24");
3699 static_assert(offsetof(GetActiveAttrib
, header
) == 0,
3700 "offset of GetActiveAttrib header should be 0");
3701 static_assert(offsetof(GetActiveAttrib
, program
) == 4,
3702 "offset of GetActiveAttrib program should be 4");
3703 static_assert(offsetof(GetActiveAttrib
, index
) == 8,
3704 "offset of GetActiveAttrib index should be 8");
3705 static_assert(offsetof(GetActiveAttrib
, name_bucket_id
) == 12,
3706 "offset of GetActiveAttrib name_bucket_id should be 12");
3707 static_assert(offsetof(GetActiveAttrib
, result_shm_id
) == 16,
3708 "offset of GetActiveAttrib result_shm_id should be 16");
3709 static_assert(offsetof(GetActiveAttrib
, result_shm_offset
) == 20,
3710 "offset of GetActiveAttrib result_shm_offset should be 20");
3711 static_assert(offsetof(GetActiveAttrib::Result
, success
) == 0,
3712 "offset of GetActiveAttrib Result success should be "
3714 static_assert(offsetof(GetActiveAttrib::Result
, size
) == 4,
3715 "offset of GetActiveAttrib Result size should be "
3717 static_assert(offsetof(GetActiveAttrib::Result
, type
) == 8,
3718 "offset of GetActiveAttrib Result type should be "
3721 struct GetActiveUniform
{
3722 typedef GetActiveUniform ValueType
;
3723 static const CommandId kCmdId
= kGetActiveUniform
;
3724 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3725 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3733 static uint32_t ComputeSize() {
3734 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3737 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3739 void Init(GLuint _program
,
3741 uint32_t _name_bucket_id
,
3742 uint32_t _result_shm_id
,
3743 uint32_t _result_shm_offset
) {
3747 name_bucket_id
= _name_bucket_id
;
3748 result_shm_id
= _result_shm_id
;
3749 result_shm_offset
= _result_shm_offset
;
3752 void* Set(void* cmd
,
3755 uint32_t _name_bucket_id
,
3756 uint32_t _result_shm_id
,
3757 uint32_t _result_shm_offset
) {
3758 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _name_bucket_id
,
3759 _result_shm_id
, _result_shm_offset
);
3760 return NextCmdAddress
<ValueType
>(cmd
);
3763 gpu::CommandHeader header
;
3766 uint32_t name_bucket_id
;
3767 uint32_t result_shm_id
;
3768 uint32_t result_shm_offset
;
3771 static_assert(sizeof(GetActiveUniform
) == 24,
3772 "size of GetActiveUniform should be 24");
3773 static_assert(offsetof(GetActiveUniform
, header
) == 0,
3774 "offset of GetActiveUniform header should be 0");
3775 static_assert(offsetof(GetActiveUniform
, program
) == 4,
3776 "offset of GetActiveUniform program should be 4");
3777 static_assert(offsetof(GetActiveUniform
, index
) == 8,
3778 "offset of GetActiveUniform index should be 8");
3779 static_assert(offsetof(GetActiveUniform
, name_bucket_id
) == 12,
3780 "offset of GetActiveUniform name_bucket_id should be 12");
3781 static_assert(offsetof(GetActiveUniform
, result_shm_id
) == 16,
3782 "offset of GetActiveUniform result_shm_id should be 16");
3783 static_assert(offsetof(GetActiveUniform
, result_shm_offset
) == 20,
3784 "offset of GetActiveUniform result_shm_offset should be 20");
3785 static_assert(offsetof(GetActiveUniform::Result
, success
) == 0,
3786 "offset of GetActiveUniform Result success should be "
3788 static_assert(offsetof(GetActiveUniform::Result
, size
) == 4,
3789 "offset of GetActiveUniform Result size should be "
3791 static_assert(offsetof(GetActiveUniform::Result
, type
) == 8,
3792 "offset of GetActiveUniform Result type should be "
3795 struct GetActiveUniformBlockiv
{
3796 typedef GetActiveUniformBlockiv ValueType
;
3797 static const CommandId kCmdId
= kGetActiveUniformBlockiv
;
3798 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3799 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3801 typedef SizedResult
<GLint
> Result
;
3803 static uint32_t ComputeSize() {
3804 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3807 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3809 void Init(GLuint _program
,
3812 uint32_t _params_shm_id
,
3813 uint32_t _params_shm_offset
) {
3818 params_shm_id
= _params_shm_id
;
3819 params_shm_offset
= _params_shm_offset
;
3822 void* Set(void* cmd
,
3826 uint32_t _params_shm_id
,
3827 uint32_t _params_shm_offset
) {
3828 static_cast<ValueType
*>(cmd
)
3829 ->Init(_program
, _index
, _pname
, _params_shm_id
, _params_shm_offset
);
3830 return NextCmdAddress
<ValueType
>(cmd
);
3833 gpu::CommandHeader header
;
3837 uint32_t params_shm_id
;
3838 uint32_t params_shm_offset
;
3841 static_assert(sizeof(GetActiveUniformBlockiv
) == 24,
3842 "size of GetActiveUniformBlockiv should be 24");
3843 static_assert(offsetof(GetActiveUniformBlockiv
, header
) == 0,
3844 "offset of GetActiveUniformBlockiv header should be 0");
3845 static_assert(offsetof(GetActiveUniformBlockiv
, program
) == 4,
3846 "offset of GetActiveUniformBlockiv program should be 4");
3847 static_assert(offsetof(GetActiveUniformBlockiv
, index
) == 8,
3848 "offset of GetActiveUniformBlockiv index should be 8");
3849 static_assert(offsetof(GetActiveUniformBlockiv
, pname
) == 12,
3850 "offset of GetActiveUniformBlockiv pname should be 12");
3851 static_assert(offsetof(GetActiveUniformBlockiv
, params_shm_id
) == 16,
3852 "offset of GetActiveUniformBlockiv params_shm_id should be 16");
3854 offsetof(GetActiveUniformBlockiv
, params_shm_offset
) == 20,
3855 "offset of GetActiveUniformBlockiv params_shm_offset should be 20");
3857 struct GetActiveUniformBlockName
{
3858 typedef GetActiveUniformBlockName ValueType
;
3859 static const CommandId kCmdId
= kGetActiveUniformBlockName
;
3860 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3861 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3863 typedef int32_t Result
;
3865 static uint32_t ComputeSize() {
3866 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3869 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3871 void Init(GLuint _program
,
3873 uint32_t _name_bucket_id
,
3874 uint32_t _result_shm_id
,
3875 uint32_t _result_shm_offset
) {
3879 name_bucket_id
= _name_bucket_id
;
3880 result_shm_id
= _result_shm_id
;
3881 result_shm_offset
= _result_shm_offset
;
3884 void* Set(void* cmd
,
3887 uint32_t _name_bucket_id
,
3888 uint32_t _result_shm_id
,
3889 uint32_t _result_shm_offset
) {
3890 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _name_bucket_id
,
3891 _result_shm_id
, _result_shm_offset
);
3892 return NextCmdAddress
<ValueType
>(cmd
);
3895 gpu::CommandHeader header
;
3898 uint32_t name_bucket_id
;
3899 uint32_t result_shm_id
;
3900 uint32_t result_shm_offset
;
3903 static_assert(sizeof(GetActiveUniformBlockName
) == 24,
3904 "size of GetActiveUniformBlockName should be 24");
3905 static_assert(offsetof(GetActiveUniformBlockName
, header
) == 0,
3906 "offset of GetActiveUniformBlockName header should be 0");
3907 static_assert(offsetof(GetActiveUniformBlockName
, program
) == 4,
3908 "offset of GetActiveUniformBlockName program should be 4");
3909 static_assert(offsetof(GetActiveUniformBlockName
, index
) == 8,
3910 "offset of GetActiveUniformBlockName index should be 8");
3912 offsetof(GetActiveUniformBlockName
, name_bucket_id
) == 12,
3913 "offset of GetActiveUniformBlockName name_bucket_id should be 12");
3914 static_assert(offsetof(GetActiveUniformBlockName
, result_shm_id
) == 16,
3915 "offset of GetActiveUniformBlockName result_shm_id should be 16");
3917 offsetof(GetActiveUniformBlockName
, result_shm_offset
) == 20,
3918 "offset of GetActiveUniformBlockName result_shm_offset should be 20");
3920 struct GetActiveUniformsiv
{
3921 typedef GetActiveUniformsiv ValueType
;
3922 static const CommandId kCmdId
= kGetActiveUniformsiv
;
3923 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3924 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3926 typedef SizedResult
<GLint
> Result
;
3928 static uint32_t ComputeSize() {
3929 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3932 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3934 void Init(GLuint _program
,
3935 uint32_t _indices_bucket_id
,
3937 uint32_t _params_shm_id
,
3938 uint32_t _params_shm_offset
) {
3941 indices_bucket_id
= _indices_bucket_id
;
3943 params_shm_id
= _params_shm_id
;
3944 params_shm_offset
= _params_shm_offset
;
3947 void* Set(void* cmd
,
3949 uint32_t _indices_bucket_id
,
3951 uint32_t _params_shm_id
,
3952 uint32_t _params_shm_offset
) {
3953 static_cast<ValueType
*>(cmd
)->Init(_program
, _indices_bucket_id
, _pname
,
3954 _params_shm_id
, _params_shm_offset
);
3955 return NextCmdAddress
<ValueType
>(cmd
);
3958 gpu::CommandHeader header
;
3960 uint32_t indices_bucket_id
;
3962 uint32_t params_shm_id
;
3963 uint32_t params_shm_offset
;
3966 static_assert(sizeof(GetActiveUniformsiv
) == 24,
3967 "size of GetActiveUniformsiv should be 24");
3968 static_assert(offsetof(GetActiveUniformsiv
, header
) == 0,
3969 "offset of GetActiveUniformsiv header should be 0");
3970 static_assert(offsetof(GetActiveUniformsiv
, program
) == 4,
3971 "offset of GetActiveUniformsiv program should be 4");
3972 static_assert(offsetof(GetActiveUniformsiv
, indices_bucket_id
) == 8,
3973 "offset of GetActiveUniformsiv indices_bucket_id should be 8");
3974 static_assert(offsetof(GetActiveUniformsiv
, pname
) == 12,
3975 "offset of GetActiveUniformsiv pname should be 12");
3976 static_assert(offsetof(GetActiveUniformsiv
, params_shm_id
) == 16,
3977 "offset of GetActiveUniformsiv params_shm_id should be 16");
3978 static_assert(offsetof(GetActiveUniformsiv
, params_shm_offset
) == 20,
3979 "offset of GetActiveUniformsiv params_shm_offset should be 20");
3981 struct GetAttachedShaders
{
3982 typedef GetAttachedShaders ValueType
;
3983 static const CommandId kCmdId
= kGetAttachedShaders
;
3984 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
3985 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
3987 typedef SizedResult
<GLuint
> Result
;
3989 static uint32_t ComputeSize() {
3990 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
3993 void SetHeader() { header
.SetCmd
<ValueType
>(); }
3995 void Init(GLuint _program
,
3996 uint32_t _result_shm_id
,
3997 uint32_t _result_shm_offset
,
3998 uint32_t _result_size
) {
4001 result_shm_id
= _result_shm_id
;
4002 result_shm_offset
= _result_shm_offset
;
4003 result_size
= _result_size
;
4006 void* Set(void* cmd
,
4008 uint32_t _result_shm_id
,
4009 uint32_t _result_shm_offset
,
4010 uint32_t _result_size
) {
4011 static_cast<ValueType
*>(cmd
)
4012 ->Init(_program
, _result_shm_id
, _result_shm_offset
, _result_size
);
4013 return NextCmdAddress
<ValueType
>(cmd
);
4016 gpu::CommandHeader header
;
4018 uint32_t result_shm_id
;
4019 uint32_t result_shm_offset
;
4020 uint32_t result_size
;
4023 static_assert(sizeof(GetAttachedShaders
) == 20,
4024 "size of GetAttachedShaders should be 20");
4025 static_assert(offsetof(GetAttachedShaders
, header
) == 0,
4026 "offset of GetAttachedShaders header should be 0");
4027 static_assert(offsetof(GetAttachedShaders
, program
) == 4,
4028 "offset of GetAttachedShaders program should be 4");
4029 static_assert(offsetof(GetAttachedShaders
, result_shm_id
) == 8,
4030 "offset of GetAttachedShaders result_shm_id should be 8");
4031 static_assert(offsetof(GetAttachedShaders
, result_shm_offset
) == 12,
4032 "offset of GetAttachedShaders result_shm_offset should be 12");
4033 static_assert(offsetof(GetAttachedShaders
, result_size
) == 16,
4034 "offset of GetAttachedShaders result_size should be 16");
4036 struct GetAttribLocation
{
4037 typedef GetAttribLocation ValueType
;
4038 static const CommandId kCmdId
= kGetAttribLocation
;
4039 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4040 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4042 typedef GLint Result
;
4044 static uint32_t ComputeSize() {
4045 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4048 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4050 void Init(GLuint _program
,
4051 uint32_t _name_bucket_id
,
4052 uint32_t _location_shm_id
,
4053 uint32_t _location_shm_offset
) {
4056 name_bucket_id
= _name_bucket_id
;
4057 location_shm_id
= _location_shm_id
;
4058 location_shm_offset
= _location_shm_offset
;
4061 void* Set(void* cmd
,
4063 uint32_t _name_bucket_id
,
4064 uint32_t _location_shm_id
,
4065 uint32_t _location_shm_offset
) {
4066 static_cast<ValueType
*>(cmd
)->Init(_program
, _name_bucket_id
,
4067 _location_shm_id
, _location_shm_offset
);
4068 return NextCmdAddress
<ValueType
>(cmd
);
4071 gpu::CommandHeader header
;
4073 uint32_t name_bucket_id
;
4074 uint32_t location_shm_id
;
4075 uint32_t location_shm_offset
;
4078 static_assert(sizeof(GetAttribLocation
) == 20,
4079 "size of GetAttribLocation should be 20");
4080 static_assert(offsetof(GetAttribLocation
, header
) == 0,
4081 "offset of GetAttribLocation header should be 0");
4082 static_assert(offsetof(GetAttribLocation
, program
) == 4,
4083 "offset of GetAttribLocation program should be 4");
4084 static_assert(offsetof(GetAttribLocation
, name_bucket_id
) == 8,
4085 "offset of GetAttribLocation name_bucket_id should be 8");
4086 static_assert(offsetof(GetAttribLocation
, location_shm_id
) == 12,
4087 "offset of GetAttribLocation location_shm_id should be 12");
4088 static_assert(offsetof(GetAttribLocation
, location_shm_offset
) == 16,
4089 "offset of GetAttribLocation location_shm_offset should be 16");
4091 struct GetBooleanv
{
4092 typedef GetBooleanv ValueType
;
4093 static const CommandId kCmdId
= kGetBooleanv
;
4094 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4095 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4097 typedef SizedResult
<GLboolean
> Result
;
4099 static uint32_t ComputeSize() {
4100 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4103 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4105 void Init(GLenum _pname
,
4106 uint32_t _params_shm_id
,
4107 uint32_t _params_shm_offset
) {
4110 params_shm_id
= _params_shm_id
;
4111 params_shm_offset
= _params_shm_offset
;
4114 void* Set(void* cmd
,
4116 uint32_t _params_shm_id
,
4117 uint32_t _params_shm_offset
) {
4118 static_cast<ValueType
*>(cmd
)
4119 ->Init(_pname
, _params_shm_id
, _params_shm_offset
);
4120 return NextCmdAddress
<ValueType
>(cmd
);
4123 gpu::CommandHeader header
;
4125 uint32_t params_shm_id
;
4126 uint32_t params_shm_offset
;
4129 static_assert(sizeof(GetBooleanv
) == 16, "size of GetBooleanv should be 16");
4130 static_assert(offsetof(GetBooleanv
, header
) == 0,
4131 "offset of GetBooleanv header should be 0");
4132 static_assert(offsetof(GetBooleanv
, pname
) == 4,
4133 "offset of GetBooleanv pname should be 4");
4134 static_assert(offsetof(GetBooleanv
, params_shm_id
) == 8,
4135 "offset of GetBooleanv params_shm_id should be 8");
4136 static_assert(offsetof(GetBooleanv
, params_shm_offset
) == 12,
4137 "offset of GetBooleanv params_shm_offset should be 12");
4139 struct GetBufferParameteri64v
{
4140 typedef GetBufferParameteri64v ValueType
;
4141 static const CommandId kCmdId
= kGetBufferParameteri64v
;
4142 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4143 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4145 typedef SizedResult
<GLint64
> Result
;
4147 static uint32_t ComputeSize() {
4148 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4151 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4153 void Init(GLenum _target
,
4155 uint32_t _params_shm_id
,
4156 uint32_t _params_shm_offset
) {
4160 params_shm_id
= _params_shm_id
;
4161 params_shm_offset
= _params_shm_offset
;
4164 void* Set(void* cmd
,
4167 uint32_t _params_shm_id
,
4168 uint32_t _params_shm_offset
) {
4169 static_cast<ValueType
*>(cmd
)
4170 ->Init(_target
, _pname
, _params_shm_id
, _params_shm_offset
);
4171 return NextCmdAddress
<ValueType
>(cmd
);
4174 gpu::CommandHeader header
;
4177 uint32_t params_shm_id
;
4178 uint32_t params_shm_offset
;
4181 static_assert(sizeof(GetBufferParameteri64v
) == 20,
4182 "size of GetBufferParameteri64v should be 20");
4183 static_assert(offsetof(GetBufferParameteri64v
, header
) == 0,
4184 "offset of GetBufferParameteri64v header should be 0");
4185 static_assert(offsetof(GetBufferParameteri64v
, target
) == 4,
4186 "offset of GetBufferParameteri64v target should be 4");
4187 static_assert(offsetof(GetBufferParameteri64v
, pname
) == 8,
4188 "offset of GetBufferParameteri64v pname should be 8");
4189 static_assert(offsetof(GetBufferParameteri64v
, params_shm_id
) == 12,
4190 "offset of GetBufferParameteri64v params_shm_id should be 12");
4192 offsetof(GetBufferParameteri64v
, params_shm_offset
) == 16,
4193 "offset of GetBufferParameteri64v params_shm_offset should be 16");
4195 struct GetBufferParameteriv
{
4196 typedef GetBufferParameteriv ValueType
;
4197 static const CommandId kCmdId
= kGetBufferParameteriv
;
4198 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4199 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4201 typedef SizedResult
<GLint
> Result
;
4203 static uint32_t ComputeSize() {
4204 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4207 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4209 void Init(GLenum _target
,
4211 uint32_t _params_shm_id
,
4212 uint32_t _params_shm_offset
) {
4216 params_shm_id
= _params_shm_id
;
4217 params_shm_offset
= _params_shm_offset
;
4220 void* Set(void* cmd
,
4223 uint32_t _params_shm_id
,
4224 uint32_t _params_shm_offset
) {
4225 static_cast<ValueType
*>(cmd
)
4226 ->Init(_target
, _pname
, _params_shm_id
, _params_shm_offset
);
4227 return NextCmdAddress
<ValueType
>(cmd
);
4230 gpu::CommandHeader header
;
4233 uint32_t params_shm_id
;
4234 uint32_t params_shm_offset
;
4237 static_assert(sizeof(GetBufferParameteriv
) == 20,
4238 "size of GetBufferParameteriv should be 20");
4239 static_assert(offsetof(GetBufferParameteriv
, header
) == 0,
4240 "offset of GetBufferParameteriv header should be 0");
4241 static_assert(offsetof(GetBufferParameteriv
, target
) == 4,
4242 "offset of GetBufferParameteriv target should be 4");
4243 static_assert(offsetof(GetBufferParameteriv
, pname
) == 8,
4244 "offset of GetBufferParameteriv pname should be 8");
4245 static_assert(offsetof(GetBufferParameteriv
, params_shm_id
) == 12,
4246 "offset of GetBufferParameteriv params_shm_id should be 12");
4247 static_assert(offsetof(GetBufferParameteriv
, params_shm_offset
) == 16,
4248 "offset of GetBufferParameteriv params_shm_offset should be 16");
4251 typedef GetError ValueType
;
4252 static const CommandId kCmdId
= kGetError
;
4253 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4254 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4256 typedef GLenum Result
;
4258 static uint32_t ComputeSize() {
4259 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4262 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4264 void Init(uint32_t _result_shm_id
, uint32_t _result_shm_offset
) {
4266 result_shm_id
= _result_shm_id
;
4267 result_shm_offset
= _result_shm_offset
;
4270 void* Set(void* cmd
, uint32_t _result_shm_id
, uint32_t _result_shm_offset
) {
4271 static_cast<ValueType
*>(cmd
)->Init(_result_shm_id
, _result_shm_offset
);
4272 return NextCmdAddress
<ValueType
>(cmd
);
4275 gpu::CommandHeader header
;
4276 uint32_t result_shm_id
;
4277 uint32_t result_shm_offset
;
4280 static_assert(sizeof(GetError
) == 12, "size of GetError should be 12");
4281 static_assert(offsetof(GetError
, header
) == 0,
4282 "offset of GetError header should be 0");
4283 static_assert(offsetof(GetError
, result_shm_id
) == 4,
4284 "offset of GetError result_shm_id should be 4");
4285 static_assert(offsetof(GetError
, result_shm_offset
) == 8,
4286 "offset of GetError result_shm_offset should be 8");
4289 typedef GetFloatv ValueType
;
4290 static const CommandId kCmdId
= kGetFloatv
;
4291 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4292 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4294 typedef SizedResult
<GLfloat
> Result
;
4296 static uint32_t ComputeSize() {
4297 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4300 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4302 void Init(GLenum _pname
,
4303 uint32_t _params_shm_id
,
4304 uint32_t _params_shm_offset
) {
4307 params_shm_id
= _params_shm_id
;
4308 params_shm_offset
= _params_shm_offset
;
4311 void* Set(void* cmd
,
4313 uint32_t _params_shm_id
,
4314 uint32_t _params_shm_offset
) {
4315 static_cast<ValueType
*>(cmd
)
4316 ->Init(_pname
, _params_shm_id
, _params_shm_offset
);
4317 return NextCmdAddress
<ValueType
>(cmd
);
4320 gpu::CommandHeader header
;
4322 uint32_t params_shm_id
;
4323 uint32_t params_shm_offset
;
4326 static_assert(sizeof(GetFloatv
) == 16, "size of GetFloatv should be 16");
4327 static_assert(offsetof(GetFloatv
, header
) == 0,
4328 "offset of GetFloatv header should be 0");
4329 static_assert(offsetof(GetFloatv
, pname
) == 4,
4330 "offset of GetFloatv pname should be 4");
4331 static_assert(offsetof(GetFloatv
, params_shm_id
) == 8,
4332 "offset of GetFloatv params_shm_id should be 8");
4333 static_assert(offsetof(GetFloatv
, params_shm_offset
) == 12,
4334 "offset of GetFloatv params_shm_offset should be 12");
4336 struct GetFragDataLocation
{
4337 typedef GetFragDataLocation ValueType
;
4338 static const CommandId kCmdId
= kGetFragDataLocation
;
4339 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4340 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4342 typedef GLint Result
;
4344 static uint32_t ComputeSize() {
4345 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4348 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4350 void Init(GLuint _program
,
4351 uint32_t _name_bucket_id
,
4352 uint32_t _location_shm_id
,
4353 uint32_t _location_shm_offset
) {
4356 name_bucket_id
= _name_bucket_id
;
4357 location_shm_id
= _location_shm_id
;
4358 location_shm_offset
= _location_shm_offset
;
4361 void* Set(void* cmd
,
4363 uint32_t _name_bucket_id
,
4364 uint32_t _location_shm_id
,
4365 uint32_t _location_shm_offset
) {
4366 static_cast<ValueType
*>(cmd
)->Init(_program
, _name_bucket_id
,
4367 _location_shm_id
, _location_shm_offset
);
4368 return NextCmdAddress
<ValueType
>(cmd
);
4371 gpu::CommandHeader header
;
4373 uint32_t name_bucket_id
;
4374 uint32_t location_shm_id
;
4375 uint32_t location_shm_offset
;
4378 static_assert(sizeof(GetFragDataLocation
) == 20,
4379 "size of GetFragDataLocation should be 20");
4380 static_assert(offsetof(GetFragDataLocation
, header
) == 0,
4381 "offset of GetFragDataLocation header should be 0");
4382 static_assert(offsetof(GetFragDataLocation
, program
) == 4,
4383 "offset of GetFragDataLocation program should be 4");
4384 static_assert(offsetof(GetFragDataLocation
, name_bucket_id
) == 8,
4385 "offset of GetFragDataLocation name_bucket_id should be 8");
4386 static_assert(offsetof(GetFragDataLocation
, location_shm_id
) == 12,
4387 "offset of GetFragDataLocation location_shm_id should be 12");
4388 static_assert(offsetof(GetFragDataLocation
, location_shm_offset
) == 16,
4389 "offset of GetFragDataLocation location_shm_offset should be 16");
4391 struct GetFramebufferAttachmentParameteriv
{
4392 typedef GetFramebufferAttachmentParameteriv ValueType
;
4393 static const CommandId kCmdId
= kGetFramebufferAttachmentParameteriv
;
4394 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4395 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4397 typedef SizedResult
<GLint
> Result
;
4399 static uint32_t ComputeSize() {
4400 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4403 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4405 void Init(GLenum _target
,
4408 uint32_t _params_shm_id
,
4409 uint32_t _params_shm_offset
) {
4412 attachment
= _attachment
;
4414 params_shm_id
= _params_shm_id
;
4415 params_shm_offset
= _params_shm_offset
;
4418 void* Set(void* cmd
,
4422 uint32_t _params_shm_id
,
4423 uint32_t _params_shm_offset
) {
4424 static_cast<ValueType
*>(cmd
)->Init(_target
, _attachment
, _pname
,
4425 _params_shm_id
, _params_shm_offset
);
4426 return NextCmdAddress
<ValueType
>(cmd
);
4429 gpu::CommandHeader header
;
4431 uint32_t attachment
;
4433 uint32_t params_shm_id
;
4434 uint32_t params_shm_offset
;
4437 static_assert(sizeof(GetFramebufferAttachmentParameteriv
) == 24,
4438 "size of GetFramebufferAttachmentParameteriv should be 24");
4440 offsetof(GetFramebufferAttachmentParameteriv
, header
) == 0,
4441 "offset of GetFramebufferAttachmentParameteriv header should be 0");
4443 offsetof(GetFramebufferAttachmentParameteriv
, target
) == 4,
4444 "offset of GetFramebufferAttachmentParameteriv target should be 4");
4446 offsetof(GetFramebufferAttachmentParameteriv
, attachment
) == 8,
4447 "offset of GetFramebufferAttachmentParameteriv attachment should be 8");
4449 offsetof(GetFramebufferAttachmentParameteriv
, pname
) == 12,
4450 "offset of GetFramebufferAttachmentParameteriv pname should be 12");
4452 offsetof(GetFramebufferAttachmentParameteriv
, params_shm_id
) == 16,
4453 "offset of GetFramebufferAttachmentParameteriv params_shm_id should be 16");
4454 static_assert(offsetof(GetFramebufferAttachmentParameteriv
,
4455 params_shm_offset
) == 20,
4456 "offset of GetFramebufferAttachmentParameteriv params_shm_offset "
4459 struct GetInteger64v
{
4460 typedef GetInteger64v ValueType
;
4461 static const CommandId kCmdId
= kGetInteger64v
;
4462 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4463 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4465 typedef SizedResult
<GLint64
> Result
;
4467 static uint32_t ComputeSize() {
4468 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4471 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4473 void Init(GLenum _pname
,
4474 uint32_t _params_shm_id
,
4475 uint32_t _params_shm_offset
) {
4478 params_shm_id
= _params_shm_id
;
4479 params_shm_offset
= _params_shm_offset
;
4482 void* Set(void* cmd
,
4484 uint32_t _params_shm_id
,
4485 uint32_t _params_shm_offset
) {
4486 static_cast<ValueType
*>(cmd
)
4487 ->Init(_pname
, _params_shm_id
, _params_shm_offset
);
4488 return NextCmdAddress
<ValueType
>(cmd
);
4491 gpu::CommandHeader header
;
4493 uint32_t params_shm_id
;
4494 uint32_t params_shm_offset
;
4497 static_assert(sizeof(GetInteger64v
) == 16,
4498 "size of GetInteger64v should be 16");
4499 static_assert(offsetof(GetInteger64v
, header
) == 0,
4500 "offset of GetInteger64v header should be 0");
4501 static_assert(offsetof(GetInteger64v
, pname
) == 4,
4502 "offset of GetInteger64v pname should be 4");
4503 static_assert(offsetof(GetInteger64v
, params_shm_id
) == 8,
4504 "offset of GetInteger64v params_shm_id should be 8");
4505 static_assert(offsetof(GetInteger64v
, params_shm_offset
) == 12,
4506 "offset of GetInteger64v params_shm_offset should be 12");
4508 struct GetIntegeri_v
{
4509 typedef GetIntegeri_v ValueType
;
4510 static const CommandId kCmdId
= kGetIntegeri_v
;
4511 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4512 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4514 typedef SizedResult
<GLint
> Result
;
4516 static uint32_t ComputeSize() {
4517 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4520 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4522 void Init(GLenum _pname
,
4524 uint32_t _data_shm_id
,
4525 uint32_t _data_shm_offset
) {
4529 data_shm_id
= _data_shm_id
;
4530 data_shm_offset
= _data_shm_offset
;
4533 void* Set(void* cmd
,
4536 uint32_t _data_shm_id
,
4537 uint32_t _data_shm_offset
) {
4538 static_cast<ValueType
*>(cmd
)
4539 ->Init(_pname
, _index
, _data_shm_id
, _data_shm_offset
);
4540 return NextCmdAddress
<ValueType
>(cmd
);
4543 gpu::CommandHeader header
;
4546 uint32_t data_shm_id
;
4547 uint32_t data_shm_offset
;
4550 static_assert(sizeof(GetIntegeri_v
) == 20,
4551 "size of GetIntegeri_v should be 20");
4552 static_assert(offsetof(GetIntegeri_v
, header
) == 0,
4553 "offset of GetIntegeri_v header should be 0");
4554 static_assert(offsetof(GetIntegeri_v
, pname
) == 4,
4555 "offset of GetIntegeri_v pname should be 4");
4556 static_assert(offsetof(GetIntegeri_v
, index
) == 8,
4557 "offset of GetIntegeri_v index should be 8");
4558 static_assert(offsetof(GetIntegeri_v
, data_shm_id
) == 12,
4559 "offset of GetIntegeri_v data_shm_id should be 12");
4560 static_assert(offsetof(GetIntegeri_v
, data_shm_offset
) == 16,
4561 "offset of GetIntegeri_v data_shm_offset should be 16");
4563 struct GetInteger64i_v
{
4564 typedef GetInteger64i_v ValueType
;
4565 static const CommandId kCmdId
= kGetInteger64i_v
;
4566 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4567 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4569 typedef SizedResult
<GLint64
> Result
;
4571 static uint32_t ComputeSize() {
4572 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4575 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4577 void Init(GLenum _pname
,
4579 uint32_t _data_shm_id
,
4580 uint32_t _data_shm_offset
) {
4584 data_shm_id
= _data_shm_id
;
4585 data_shm_offset
= _data_shm_offset
;
4588 void* Set(void* cmd
,
4591 uint32_t _data_shm_id
,
4592 uint32_t _data_shm_offset
) {
4593 static_cast<ValueType
*>(cmd
)
4594 ->Init(_pname
, _index
, _data_shm_id
, _data_shm_offset
);
4595 return NextCmdAddress
<ValueType
>(cmd
);
4598 gpu::CommandHeader header
;
4601 uint32_t data_shm_id
;
4602 uint32_t data_shm_offset
;
4605 static_assert(sizeof(GetInteger64i_v
) == 20,
4606 "size of GetInteger64i_v should be 20");
4607 static_assert(offsetof(GetInteger64i_v
, header
) == 0,
4608 "offset of GetInteger64i_v header should be 0");
4609 static_assert(offsetof(GetInteger64i_v
, pname
) == 4,
4610 "offset of GetInteger64i_v pname should be 4");
4611 static_assert(offsetof(GetInteger64i_v
, index
) == 8,
4612 "offset of GetInteger64i_v index should be 8");
4613 static_assert(offsetof(GetInteger64i_v
, data_shm_id
) == 12,
4614 "offset of GetInteger64i_v data_shm_id should be 12");
4615 static_assert(offsetof(GetInteger64i_v
, data_shm_offset
) == 16,
4616 "offset of GetInteger64i_v data_shm_offset should be 16");
4618 struct GetIntegerv
{
4619 typedef GetIntegerv ValueType
;
4620 static const CommandId kCmdId
= kGetIntegerv
;
4621 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4622 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4624 typedef SizedResult
<GLint
> Result
;
4626 static uint32_t ComputeSize() {
4627 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4630 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4632 void Init(GLenum _pname
,
4633 uint32_t _params_shm_id
,
4634 uint32_t _params_shm_offset
) {
4637 params_shm_id
= _params_shm_id
;
4638 params_shm_offset
= _params_shm_offset
;
4641 void* Set(void* cmd
,
4643 uint32_t _params_shm_id
,
4644 uint32_t _params_shm_offset
) {
4645 static_cast<ValueType
*>(cmd
)
4646 ->Init(_pname
, _params_shm_id
, _params_shm_offset
);
4647 return NextCmdAddress
<ValueType
>(cmd
);
4650 gpu::CommandHeader header
;
4652 uint32_t params_shm_id
;
4653 uint32_t params_shm_offset
;
4656 static_assert(sizeof(GetIntegerv
) == 16, "size of GetIntegerv should be 16");
4657 static_assert(offsetof(GetIntegerv
, header
) == 0,
4658 "offset of GetIntegerv header should be 0");
4659 static_assert(offsetof(GetIntegerv
, pname
) == 4,
4660 "offset of GetIntegerv pname should be 4");
4661 static_assert(offsetof(GetIntegerv
, params_shm_id
) == 8,
4662 "offset of GetIntegerv params_shm_id should be 8");
4663 static_assert(offsetof(GetIntegerv
, params_shm_offset
) == 12,
4664 "offset of GetIntegerv params_shm_offset should be 12");
4666 struct GetInternalformativ
{
4667 typedef GetInternalformativ ValueType
;
4668 static const CommandId kCmdId
= kGetInternalformativ
;
4669 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4670 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4672 typedef SizedResult
<GLint
> Result
;
4674 static uint32_t ComputeSize() {
4675 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4678 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4680 void Init(GLenum _target
,
4683 uint32_t _params_shm_id
,
4684 uint32_t _params_shm_offset
) {
4689 params_shm_id
= _params_shm_id
;
4690 params_shm_offset
= _params_shm_offset
;
4693 void* Set(void* cmd
,
4697 uint32_t _params_shm_id
,
4698 uint32_t _params_shm_offset
) {
4699 static_cast<ValueType
*>(cmd
)
4700 ->Init(_target
, _format
, _pname
, _params_shm_id
, _params_shm_offset
);
4701 return NextCmdAddress
<ValueType
>(cmd
);
4704 gpu::CommandHeader header
;
4708 uint32_t params_shm_id
;
4709 uint32_t params_shm_offset
;
4712 static_assert(sizeof(GetInternalformativ
) == 24,
4713 "size of GetInternalformativ should be 24");
4714 static_assert(offsetof(GetInternalformativ
, header
) == 0,
4715 "offset of GetInternalformativ header should be 0");
4716 static_assert(offsetof(GetInternalformativ
, target
) == 4,
4717 "offset of GetInternalformativ target should be 4");
4718 static_assert(offsetof(GetInternalformativ
, format
) == 8,
4719 "offset of GetInternalformativ format should be 8");
4720 static_assert(offsetof(GetInternalformativ
, pname
) == 12,
4721 "offset of GetInternalformativ pname should be 12");
4722 static_assert(offsetof(GetInternalformativ
, params_shm_id
) == 16,
4723 "offset of GetInternalformativ params_shm_id should be 16");
4724 static_assert(offsetof(GetInternalformativ
, params_shm_offset
) == 20,
4725 "offset of GetInternalformativ params_shm_offset should be 20");
4727 struct GetProgramiv
{
4728 typedef GetProgramiv ValueType
;
4729 static const CommandId kCmdId
= kGetProgramiv
;
4730 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4731 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4733 typedef SizedResult
<GLint
> Result
;
4735 static uint32_t ComputeSize() {
4736 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4739 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4741 void Init(GLuint _program
,
4743 uint32_t _params_shm_id
,
4744 uint32_t _params_shm_offset
) {
4748 params_shm_id
= _params_shm_id
;
4749 params_shm_offset
= _params_shm_offset
;
4752 void* Set(void* cmd
,
4755 uint32_t _params_shm_id
,
4756 uint32_t _params_shm_offset
) {
4757 static_cast<ValueType
*>(cmd
)
4758 ->Init(_program
, _pname
, _params_shm_id
, _params_shm_offset
);
4759 return NextCmdAddress
<ValueType
>(cmd
);
4762 gpu::CommandHeader header
;
4765 uint32_t params_shm_id
;
4766 uint32_t params_shm_offset
;
4769 static_assert(sizeof(GetProgramiv
) == 20, "size of GetProgramiv should be 20");
4770 static_assert(offsetof(GetProgramiv
, header
) == 0,
4771 "offset of GetProgramiv header should be 0");
4772 static_assert(offsetof(GetProgramiv
, program
) == 4,
4773 "offset of GetProgramiv program should be 4");
4774 static_assert(offsetof(GetProgramiv
, pname
) == 8,
4775 "offset of GetProgramiv pname should be 8");
4776 static_assert(offsetof(GetProgramiv
, params_shm_id
) == 12,
4777 "offset of GetProgramiv params_shm_id should be 12");
4778 static_assert(offsetof(GetProgramiv
, params_shm_offset
) == 16,
4779 "offset of GetProgramiv params_shm_offset should be 16");
4781 struct GetProgramInfoLog
{
4782 typedef GetProgramInfoLog ValueType
;
4783 static const CommandId kCmdId
= kGetProgramInfoLog
;
4784 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4785 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4787 static uint32_t ComputeSize() {
4788 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4791 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4793 void Init(GLuint _program
, uint32_t _bucket_id
) {
4796 bucket_id
= _bucket_id
;
4799 void* Set(void* cmd
, GLuint _program
, uint32_t _bucket_id
) {
4800 static_cast<ValueType
*>(cmd
)->Init(_program
, _bucket_id
);
4801 return NextCmdAddress
<ValueType
>(cmd
);
4804 gpu::CommandHeader header
;
4809 static_assert(sizeof(GetProgramInfoLog
) == 12,
4810 "size of GetProgramInfoLog should be 12");
4811 static_assert(offsetof(GetProgramInfoLog
, header
) == 0,
4812 "offset of GetProgramInfoLog header should be 0");
4813 static_assert(offsetof(GetProgramInfoLog
, program
) == 4,
4814 "offset of GetProgramInfoLog program should be 4");
4815 static_assert(offsetof(GetProgramInfoLog
, bucket_id
) == 8,
4816 "offset of GetProgramInfoLog bucket_id should be 8");
4818 struct GetRenderbufferParameteriv
{
4819 typedef GetRenderbufferParameteriv ValueType
;
4820 static const CommandId kCmdId
= kGetRenderbufferParameteriv
;
4821 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4822 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4824 typedef SizedResult
<GLint
> Result
;
4826 static uint32_t ComputeSize() {
4827 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4830 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4832 void Init(GLenum _target
,
4834 uint32_t _params_shm_id
,
4835 uint32_t _params_shm_offset
) {
4839 params_shm_id
= _params_shm_id
;
4840 params_shm_offset
= _params_shm_offset
;
4843 void* Set(void* cmd
,
4846 uint32_t _params_shm_id
,
4847 uint32_t _params_shm_offset
) {
4848 static_cast<ValueType
*>(cmd
)
4849 ->Init(_target
, _pname
, _params_shm_id
, _params_shm_offset
);
4850 return NextCmdAddress
<ValueType
>(cmd
);
4853 gpu::CommandHeader header
;
4856 uint32_t params_shm_id
;
4857 uint32_t params_shm_offset
;
4860 static_assert(sizeof(GetRenderbufferParameteriv
) == 20,
4861 "size of GetRenderbufferParameteriv should be 20");
4862 static_assert(offsetof(GetRenderbufferParameteriv
, header
) == 0,
4863 "offset of GetRenderbufferParameteriv header should be 0");
4864 static_assert(offsetof(GetRenderbufferParameteriv
, target
) == 4,
4865 "offset of GetRenderbufferParameteriv target should be 4");
4866 static_assert(offsetof(GetRenderbufferParameteriv
, pname
) == 8,
4867 "offset of GetRenderbufferParameteriv pname should be 8");
4869 offsetof(GetRenderbufferParameteriv
, params_shm_id
) == 12,
4870 "offset of GetRenderbufferParameteriv params_shm_id should be 12");
4872 offsetof(GetRenderbufferParameteriv
, params_shm_offset
) == 16,
4873 "offset of GetRenderbufferParameteriv params_shm_offset should be 16");
4875 struct GetSamplerParameterfv
{
4876 typedef GetSamplerParameterfv ValueType
;
4877 static const CommandId kCmdId
= kGetSamplerParameterfv
;
4878 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4879 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4881 typedef SizedResult
<GLfloat
> Result
;
4883 static uint32_t ComputeSize() {
4884 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4887 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4889 void Init(GLuint _sampler
,
4891 uint32_t _params_shm_id
,
4892 uint32_t _params_shm_offset
) {
4896 params_shm_id
= _params_shm_id
;
4897 params_shm_offset
= _params_shm_offset
;
4900 void* Set(void* cmd
,
4903 uint32_t _params_shm_id
,
4904 uint32_t _params_shm_offset
) {
4905 static_cast<ValueType
*>(cmd
)
4906 ->Init(_sampler
, _pname
, _params_shm_id
, _params_shm_offset
);
4907 return NextCmdAddress
<ValueType
>(cmd
);
4910 gpu::CommandHeader header
;
4913 uint32_t params_shm_id
;
4914 uint32_t params_shm_offset
;
4917 static_assert(sizeof(GetSamplerParameterfv
) == 20,
4918 "size of GetSamplerParameterfv should be 20");
4919 static_assert(offsetof(GetSamplerParameterfv
, header
) == 0,
4920 "offset of GetSamplerParameterfv header should be 0");
4921 static_assert(offsetof(GetSamplerParameterfv
, sampler
) == 4,
4922 "offset of GetSamplerParameterfv sampler should be 4");
4923 static_assert(offsetof(GetSamplerParameterfv
, pname
) == 8,
4924 "offset of GetSamplerParameterfv pname should be 8");
4925 static_assert(offsetof(GetSamplerParameterfv
, params_shm_id
) == 12,
4926 "offset of GetSamplerParameterfv params_shm_id should be 12");
4927 static_assert(offsetof(GetSamplerParameterfv
, params_shm_offset
) == 16,
4928 "offset of GetSamplerParameterfv params_shm_offset should be 16");
4930 struct GetSamplerParameteriv
{
4931 typedef GetSamplerParameteriv ValueType
;
4932 static const CommandId kCmdId
= kGetSamplerParameteriv
;
4933 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4934 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4936 typedef SizedResult
<GLint
> Result
;
4938 static uint32_t ComputeSize() {
4939 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4942 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4944 void Init(GLuint _sampler
,
4946 uint32_t _params_shm_id
,
4947 uint32_t _params_shm_offset
) {
4951 params_shm_id
= _params_shm_id
;
4952 params_shm_offset
= _params_shm_offset
;
4955 void* Set(void* cmd
,
4958 uint32_t _params_shm_id
,
4959 uint32_t _params_shm_offset
) {
4960 static_cast<ValueType
*>(cmd
)
4961 ->Init(_sampler
, _pname
, _params_shm_id
, _params_shm_offset
);
4962 return NextCmdAddress
<ValueType
>(cmd
);
4965 gpu::CommandHeader header
;
4968 uint32_t params_shm_id
;
4969 uint32_t params_shm_offset
;
4972 static_assert(sizeof(GetSamplerParameteriv
) == 20,
4973 "size of GetSamplerParameteriv should be 20");
4974 static_assert(offsetof(GetSamplerParameteriv
, header
) == 0,
4975 "offset of GetSamplerParameteriv header should be 0");
4976 static_assert(offsetof(GetSamplerParameteriv
, sampler
) == 4,
4977 "offset of GetSamplerParameteriv sampler should be 4");
4978 static_assert(offsetof(GetSamplerParameteriv
, pname
) == 8,
4979 "offset of GetSamplerParameteriv pname should be 8");
4980 static_assert(offsetof(GetSamplerParameteriv
, params_shm_id
) == 12,
4981 "offset of GetSamplerParameteriv params_shm_id should be 12");
4982 static_assert(offsetof(GetSamplerParameteriv
, params_shm_offset
) == 16,
4983 "offset of GetSamplerParameteriv params_shm_offset should be 16");
4985 struct GetShaderiv
{
4986 typedef GetShaderiv ValueType
;
4987 static const CommandId kCmdId
= kGetShaderiv
;
4988 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
4989 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
4991 typedef SizedResult
<GLint
> Result
;
4993 static uint32_t ComputeSize() {
4994 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
4997 void SetHeader() { header
.SetCmd
<ValueType
>(); }
4999 void Init(GLuint _shader
,
5001 uint32_t _params_shm_id
,
5002 uint32_t _params_shm_offset
) {
5006 params_shm_id
= _params_shm_id
;
5007 params_shm_offset
= _params_shm_offset
;
5010 void* Set(void* cmd
,
5013 uint32_t _params_shm_id
,
5014 uint32_t _params_shm_offset
) {
5015 static_cast<ValueType
*>(cmd
)
5016 ->Init(_shader
, _pname
, _params_shm_id
, _params_shm_offset
);
5017 return NextCmdAddress
<ValueType
>(cmd
);
5020 gpu::CommandHeader header
;
5023 uint32_t params_shm_id
;
5024 uint32_t params_shm_offset
;
5027 static_assert(sizeof(GetShaderiv
) == 20, "size of GetShaderiv should be 20");
5028 static_assert(offsetof(GetShaderiv
, header
) == 0,
5029 "offset of GetShaderiv header should be 0");
5030 static_assert(offsetof(GetShaderiv
, shader
) == 4,
5031 "offset of GetShaderiv shader should be 4");
5032 static_assert(offsetof(GetShaderiv
, pname
) == 8,
5033 "offset of GetShaderiv pname should be 8");
5034 static_assert(offsetof(GetShaderiv
, params_shm_id
) == 12,
5035 "offset of GetShaderiv params_shm_id should be 12");
5036 static_assert(offsetof(GetShaderiv
, params_shm_offset
) == 16,
5037 "offset of GetShaderiv params_shm_offset should be 16");
5039 struct GetShaderInfoLog
{
5040 typedef GetShaderInfoLog ValueType
;
5041 static const CommandId kCmdId
= kGetShaderInfoLog
;
5042 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5043 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5045 static uint32_t ComputeSize() {
5046 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5049 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5051 void Init(GLuint _shader
, uint32_t _bucket_id
) {
5054 bucket_id
= _bucket_id
;
5057 void* Set(void* cmd
, GLuint _shader
, uint32_t _bucket_id
) {
5058 static_cast<ValueType
*>(cmd
)->Init(_shader
, _bucket_id
);
5059 return NextCmdAddress
<ValueType
>(cmd
);
5062 gpu::CommandHeader header
;
5067 static_assert(sizeof(GetShaderInfoLog
) == 12,
5068 "size of GetShaderInfoLog should be 12");
5069 static_assert(offsetof(GetShaderInfoLog
, header
) == 0,
5070 "offset of GetShaderInfoLog header should be 0");
5071 static_assert(offsetof(GetShaderInfoLog
, shader
) == 4,
5072 "offset of GetShaderInfoLog shader should be 4");
5073 static_assert(offsetof(GetShaderInfoLog
, bucket_id
) == 8,
5074 "offset of GetShaderInfoLog bucket_id should be 8");
5076 struct GetShaderPrecisionFormat
{
5077 typedef GetShaderPrecisionFormat ValueType
;
5078 static const CommandId kCmdId
= kGetShaderPrecisionFormat
;
5079 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5080 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5089 static uint32_t ComputeSize() {
5090 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5093 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5095 void Init(GLenum _shadertype
,
5096 GLenum _precisiontype
,
5097 uint32_t _result_shm_id
,
5098 uint32_t _result_shm_offset
) {
5100 shadertype
= _shadertype
;
5101 precisiontype
= _precisiontype
;
5102 result_shm_id
= _result_shm_id
;
5103 result_shm_offset
= _result_shm_offset
;
5106 void* Set(void* cmd
,
5108 GLenum _precisiontype
,
5109 uint32_t _result_shm_id
,
5110 uint32_t _result_shm_offset
) {
5111 static_cast<ValueType
*>(cmd
)
5112 ->Init(_shadertype
, _precisiontype
, _result_shm_id
, _result_shm_offset
);
5113 return NextCmdAddress
<ValueType
>(cmd
);
5116 gpu::CommandHeader header
;
5117 uint32_t shadertype
;
5118 uint32_t precisiontype
;
5119 uint32_t result_shm_id
;
5120 uint32_t result_shm_offset
;
5123 static_assert(sizeof(GetShaderPrecisionFormat
) == 20,
5124 "size of GetShaderPrecisionFormat should be 20");
5125 static_assert(offsetof(GetShaderPrecisionFormat
, header
) == 0,
5126 "offset of GetShaderPrecisionFormat header should be 0");
5127 static_assert(offsetof(GetShaderPrecisionFormat
, shadertype
) == 4,
5128 "offset of GetShaderPrecisionFormat shadertype should be 4");
5129 static_assert(offsetof(GetShaderPrecisionFormat
, precisiontype
) == 8,
5130 "offset of GetShaderPrecisionFormat precisiontype should be 8");
5131 static_assert(offsetof(GetShaderPrecisionFormat
, result_shm_id
) == 12,
5132 "offset of GetShaderPrecisionFormat result_shm_id should be 12");
5134 offsetof(GetShaderPrecisionFormat
, result_shm_offset
) == 16,
5135 "offset of GetShaderPrecisionFormat result_shm_offset should be 16");
5136 static_assert(offsetof(GetShaderPrecisionFormat::Result
, success
) == 0,
5137 "offset of GetShaderPrecisionFormat Result success should be "
5139 static_assert(offsetof(GetShaderPrecisionFormat::Result
, min_range
) == 4,
5140 "offset of GetShaderPrecisionFormat Result min_range should be "
5142 static_assert(offsetof(GetShaderPrecisionFormat::Result
, max_range
) == 8,
5143 "offset of GetShaderPrecisionFormat Result max_range should be "
5145 static_assert(offsetof(GetShaderPrecisionFormat::Result
, precision
) == 12,
5146 "offset of GetShaderPrecisionFormat Result precision should be "
5149 struct GetShaderSource
{
5150 typedef GetShaderSource ValueType
;
5151 static const CommandId kCmdId
= kGetShaderSource
;
5152 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5153 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5155 static uint32_t ComputeSize() {
5156 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5159 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5161 void Init(GLuint _shader
, uint32_t _bucket_id
) {
5164 bucket_id
= _bucket_id
;
5167 void* Set(void* cmd
, GLuint _shader
, uint32_t _bucket_id
) {
5168 static_cast<ValueType
*>(cmd
)->Init(_shader
, _bucket_id
);
5169 return NextCmdAddress
<ValueType
>(cmd
);
5172 gpu::CommandHeader header
;
5177 static_assert(sizeof(GetShaderSource
) == 12,
5178 "size of GetShaderSource should be 12");
5179 static_assert(offsetof(GetShaderSource
, header
) == 0,
5180 "offset of GetShaderSource header should be 0");
5181 static_assert(offsetof(GetShaderSource
, shader
) == 4,
5182 "offset of GetShaderSource shader should be 4");
5183 static_assert(offsetof(GetShaderSource
, bucket_id
) == 8,
5184 "offset of GetShaderSource bucket_id should be 8");
5187 typedef GetString ValueType
;
5188 static const CommandId kCmdId
= kGetString
;
5189 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5190 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5192 static uint32_t ComputeSize() {
5193 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5196 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5198 void Init(GLenum _name
, uint32_t _bucket_id
) {
5201 bucket_id
= _bucket_id
;
5204 void* Set(void* cmd
, GLenum _name
, uint32_t _bucket_id
) {
5205 static_cast<ValueType
*>(cmd
)->Init(_name
, _bucket_id
);
5206 return NextCmdAddress
<ValueType
>(cmd
);
5209 gpu::CommandHeader header
;
5214 static_assert(sizeof(GetString
) == 12, "size of GetString should be 12");
5215 static_assert(offsetof(GetString
, header
) == 0,
5216 "offset of GetString header should be 0");
5217 static_assert(offsetof(GetString
, name
) == 4,
5218 "offset of GetString name should be 4");
5219 static_assert(offsetof(GetString
, bucket_id
) == 8,
5220 "offset of GetString bucket_id should be 8");
5223 typedef GetSynciv ValueType
;
5224 static const CommandId kCmdId
= kGetSynciv
;
5225 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5226 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5228 typedef SizedResult
<GLint
> Result
;
5230 static uint32_t ComputeSize() {
5231 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5234 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5236 void Init(GLuint _sync
,
5238 uint32_t _values_shm_id
,
5239 uint32_t _values_shm_offset
) {
5243 values_shm_id
= _values_shm_id
;
5244 values_shm_offset
= _values_shm_offset
;
5247 void* Set(void* cmd
,
5250 uint32_t _values_shm_id
,
5251 uint32_t _values_shm_offset
) {
5252 static_cast<ValueType
*>(cmd
)
5253 ->Init(_sync
, _pname
, _values_shm_id
, _values_shm_offset
);
5254 return NextCmdAddress
<ValueType
>(cmd
);
5257 gpu::CommandHeader header
;
5260 uint32_t values_shm_id
;
5261 uint32_t values_shm_offset
;
5264 static_assert(sizeof(GetSynciv
) == 20, "size of GetSynciv should be 20");
5265 static_assert(offsetof(GetSynciv
, header
) == 0,
5266 "offset of GetSynciv header should be 0");
5267 static_assert(offsetof(GetSynciv
, sync
) == 4,
5268 "offset of GetSynciv sync should be 4");
5269 static_assert(offsetof(GetSynciv
, pname
) == 8,
5270 "offset of GetSynciv pname should be 8");
5271 static_assert(offsetof(GetSynciv
, values_shm_id
) == 12,
5272 "offset of GetSynciv values_shm_id should be 12");
5273 static_assert(offsetof(GetSynciv
, values_shm_offset
) == 16,
5274 "offset of GetSynciv values_shm_offset should be 16");
5276 struct GetTexParameterfv
{
5277 typedef GetTexParameterfv ValueType
;
5278 static const CommandId kCmdId
= kGetTexParameterfv
;
5279 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5280 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5282 typedef SizedResult
<GLfloat
> Result
;
5284 static uint32_t ComputeSize() {
5285 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5288 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5290 void Init(GLenum _target
,
5292 uint32_t _params_shm_id
,
5293 uint32_t _params_shm_offset
) {
5297 params_shm_id
= _params_shm_id
;
5298 params_shm_offset
= _params_shm_offset
;
5301 void* Set(void* cmd
,
5304 uint32_t _params_shm_id
,
5305 uint32_t _params_shm_offset
) {
5306 static_cast<ValueType
*>(cmd
)
5307 ->Init(_target
, _pname
, _params_shm_id
, _params_shm_offset
);
5308 return NextCmdAddress
<ValueType
>(cmd
);
5311 gpu::CommandHeader header
;
5314 uint32_t params_shm_id
;
5315 uint32_t params_shm_offset
;
5318 static_assert(sizeof(GetTexParameterfv
) == 20,
5319 "size of GetTexParameterfv should be 20");
5320 static_assert(offsetof(GetTexParameterfv
, header
) == 0,
5321 "offset of GetTexParameterfv header should be 0");
5322 static_assert(offsetof(GetTexParameterfv
, target
) == 4,
5323 "offset of GetTexParameterfv target should be 4");
5324 static_assert(offsetof(GetTexParameterfv
, pname
) == 8,
5325 "offset of GetTexParameterfv pname should be 8");
5326 static_assert(offsetof(GetTexParameterfv
, params_shm_id
) == 12,
5327 "offset of GetTexParameterfv params_shm_id should be 12");
5328 static_assert(offsetof(GetTexParameterfv
, params_shm_offset
) == 16,
5329 "offset of GetTexParameterfv params_shm_offset should be 16");
5331 struct GetTexParameteriv
{
5332 typedef GetTexParameteriv ValueType
;
5333 static const CommandId kCmdId
= kGetTexParameteriv
;
5334 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5335 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5337 typedef SizedResult
<GLint
> Result
;
5339 static uint32_t ComputeSize() {
5340 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5343 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5345 void Init(GLenum _target
,
5347 uint32_t _params_shm_id
,
5348 uint32_t _params_shm_offset
) {
5352 params_shm_id
= _params_shm_id
;
5353 params_shm_offset
= _params_shm_offset
;
5356 void* Set(void* cmd
,
5359 uint32_t _params_shm_id
,
5360 uint32_t _params_shm_offset
) {
5361 static_cast<ValueType
*>(cmd
)
5362 ->Init(_target
, _pname
, _params_shm_id
, _params_shm_offset
);
5363 return NextCmdAddress
<ValueType
>(cmd
);
5366 gpu::CommandHeader header
;
5369 uint32_t params_shm_id
;
5370 uint32_t params_shm_offset
;
5373 static_assert(sizeof(GetTexParameteriv
) == 20,
5374 "size of GetTexParameteriv should be 20");
5375 static_assert(offsetof(GetTexParameteriv
, header
) == 0,
5376 "offset of GetTexParameteriv header should be 0");
5377 static_assert(offsetof(GetTexParameteriv
, target
) == 4,
5378 "offset of GetTexParameteriv target should be 4");
5379 static_assert(offsetof(GetTexParameteriv
, pname
) == 8,
5380 "offset of GetTexParameteriv pname should be 8");
5381 static_assert(offsetof(GetTexParameteriv
, params_shm_id
) == 12,
5382 "offset of GetTexParameteriv params_shm_id should be 12");
5383 static_assert(offsetof(GetTexParameteriv
, params_shm_offset
) == 16,
5384 "offset of GetTexParameteriv params_shm_offset should be 16");
5386 struct GetTransformFeedbackVarying
{
5387 typedef GetTransformFeedbackVarying ValueType
;
5388 static const CommandId kCmdId
= kGetTransformFeedbackVarying
;
5389 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5390 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5398 static uint32_t ComputeSize() {
5399 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5402 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5404 void Init(GLuint _program
,
5406 uint32_t _name_bucket_id
,
5407 uint32_t _result_shm_id
,
5408 uint32_t _result_shm_offset
) {
5412 name_bucket_id
= _name_bucket_id
;
5413 result_shm_id
= _result_shm_id
;
5414 result_shm_offset
= _result_shm_offset
;
5417 void* Set(void* cmd
,
5420 uint32_t _name_bucket_id
,
5421 uint32_t _result_shm_id
,
5422 uint32_t _result_shm_offset
) {
5423 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _name_bucket_id
,
5424 _result_shm_id
, _result_shm_offset
);
5425 return NextCmdAddress
<ValueType
>(cmd
);
5428 gpu::CommandHeader header
;
5431 uint32_t name_bucket_id
;
5432 uint32_t result_shm_id
;
5433 uint32_t result_shm_offset
;
5436 static_assert(sizeof(GetTransformFeedbackVarying
) == 24,
5437 "size of GetTransformFeedbackVarying should be 24");
5438 static_assert(offsetof(GetTransformFeedbackVarying
, header
) == 0,
5439 "offset of GetTransformFeedbackVarying header should be 0");
5440 static_assert(offsetof(GetTransformFeedbackVarying
, program
) == 4,
5441 "offset of GetTransformFeedbackVarying program should be 4");
5442 static_assert(offsetof(GetTransformFeedbackVarying
, index
) == 8,
5443 "offset of GetTransformFeedbackVarying index should be 8");
5445 offsetof(GetTransformFeedbackVarying
, name_bucket_id
) == 12,
5446 "offset of GetTransformFeedbackVarying name_bucket_id should be 12");
5448 offsetof(GetTransformFeedbackVarying
, result_shm_id
) == 16,
5449 "offset of GetTransformFeedbackVarying result_shm_id should be 16");
5451 offsetof(GetTransformFeedbackVarying
, result_shm_offset
) == 20,
5452 "offset of GetTransformFeedbackVarying result_shm_offset should be 20");
5453 static_assert(offsetof(GetTransformFeedbackVarying::Result
, success
) == 0,
5454 "offset of GetTransformFeedbackVarying Result success should be "
5456 static_assert(offsetof(GetTransformFeedbackVarying::Result
, size
) == 4,
5457 "offset of GetTransformFeedbackVarying Result size should be "
5459 static_assert(offsetof(GetTransformFeedbackVarying::Result
, type
) == 8,
5460 "offset of GetTransformFeedbackVarying Result type should be "
5463 struct GetUniformBlockIndex
{
5464 typedef GetUniformBlockIndex ValueType
;
5465 static const CommandId kCmdId
= kGetUniformBlockIndex
;
5466 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5467 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5469 typedef GLuint Result
;
5471 static uint32_t ComputeSize() {
5472 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5475 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5477 void Init(GLuint _program
,
5478 uint32_t _name_bucket_id
,
5479 uint32_t _index_shm_id
,
5480 uint32_t _index_shm_offset
) {
5483 name_bucket_id
= _name_bucket_id
;
5484 index_shm_id
= _index_shm_id
;
5485 index_shm_offset
= _index_shm_offset
;
5488 void* Set(void* cmd
,
5490 uint32_t _name_bucket_id
,
5491 uint32_t _index_shm_id
,
5492 uint32_t _index_shm_offset
) {
5493 static_cast<ValueType
*>(cmd
)
5494 ->Init(_program
, _name_bucket_id
, _index_shm_id
, _index_shm_offset
);
5495 return NextCmdAddress
<ValueType
>(cmd
);
5498 gpu::CommandHeader header
;
5500 uint32_t name_bucket_id
;
5501 uint32_t index_shm_id
;
5502 uint32_t index_shm_offset
;
5505 static_assert(sizeof(GetUniformBlockIndex
) == 20,
5506 "size of GetUniformBlockIndex should be 20");
5507 static_assert(offsetof(GetUniformBlockIndex
, header
) == 0,
5508 "offset of GetUniformBlockIndex header should be 0");
5509 static_assert(offsetof(GetUniformBlockIndex
, program
) == 4,
5510 "offset of GetUniformBlockIndex program should be 4");
5511 static_assert(offsetof(GetUniformBlockIndex
, name_bucket_id
) == 8,
5512 "offset of GetUniformBlockIndex name_bucket_id should be 8");
5513 static_assert(offsetof(GetUniformBlockIndex
, index_shm_id
) == 12,
5514 "offset of GetUniformBlockIndex index_shm_id should be 12");
5515 static_assert(offsetof(GetUniformBlockIndex
, index_shm_offset
) == 16,
5516 "offset of GetUniformBlockIndex index_shm_offset should be 16");
5518 struct GetUniformfv
{
5519 typedef GetUniformfv ValueType
;
5520 static const CommandId kCmdId
= kGetUniformfv
;
5521 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5522 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5524 typedef SizedResult
<GLfloat
> Result
;
5526 static uint32_t ComputeSize() {
5527 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5530 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5532 void Init(GLuint _program
,
5534 uint32_t _params_shm_id
,
5535 uint32_t _params_shm_offset
) {
5538 location
= _location
;
5539 params_shm_id
= _params_shm_id
;
5540 params_shm_offset
= _params_shm_offset
;
5543 void* Set(void* cmd
,
5546 uint32_t _params_shm_id
,
5547 uint32_t _params_shm_offset
) {
5548 static_cast<ValueType
*>(cmd
)
5549 ->Init(_program
, _location
, _params_shm_id
, _params_shm_offset
);
5550 return NextCmdAddress
<ValueType
>(cmd
);
5553 gpu::CommandHeader header
;
5556 uint32_t params_shm_id
;
5557 uint32_t params_shm_offset
;
5560 static_assert(sizeof(GetUniformfv
) == 20, "size of GetUniformfv should be 20");
5561 static_assert(offsetof(GetUniformfv
, header
) == 0,
5562 "offset of GetUniformfv header should be 0");
5563 static_assert(offsetof(GetUniformfv
, program
) == 4,
5564 "offset of GetUniformfv program should be 4");
5565 static_assert(offsetof(GetUniformfv
, location
) == 8,
5566 "offset of GetUniformfv location should be 8");
5567 static_assert(offsetof(GetUniformfv
, params_shm_id
) == 12,
5568 "offset of GetUniformfv params_shm_id should be 12");
5569 static_assert(offsetof(GetUniformfv
, params_shm_offset
) == 16,
5570 "offset of GetUniformfv params_shm_offset should be 16");
5572 struct GetUniformiv
{
5573 typedef GetUniformiv ValueType
;
5574 static const CommandId kCmdId
= kGetUniformiv
;
5575 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5576 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5578 typedef SizedResult
<GLint
> Result
;
5580 static uint32_t ComputeSize() {
5581 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5584 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5586 void Init(GLuint _program
,
5588 uint32_t _params_shm_id
,
5589 uint32_t _params_shm_offset
) {
5592 location
= _location
;
5593 params_shm_id
= _params_shm_id
;
5594 params_shm_offset
= _params_shm_offset
;
5597 void* Set(void* cmd
,
5600 uint32_t _params_shm_id
,
5601 uint32_t _params_shm_offset
) {
5602 static_cast<ValueType
*>(cmd
)
5603 ->Init(_program
, _location
, _params_shm_id
, _params_shm_offset
);
5604 return NextCmdAddress
<ValueType
>(cmd
);
5607 gpu::CommandHeader header
;
5610 uint32_t params_shm_id
;
5611 uint32_t params_shm_offset
;
5614 static_assert(sizeof(GetUniformiv
) == 20, "size of GetUniformiv should be 20");
5615 static_assert(offsetof(GetUniformiv
, header
) == 0,
5616 "offset of GetUniformiv header should be 0");
5617 static_assert(offsetof(GetUniformiv
, program
) == 4,
5618 "offset of GetUniformiv program should be 4");
5619 static_assert(offsetof(GetUniformiv
, location
) == 8,
5620 "offset of GetUniformiv location should be 8");
5621 static_assert(offsetof(GetUniformiv
, params_shm_id
) == 12,
5622 "offset of GetUniformiv params_shm_id should be 12");
5623 static_assert(offsetof(GetUniformiv
, params_shm_offset
) == 16,
5624 "offset of GetUniformiv params_shm_offset should be 16");
5626 struct GetUniformuiv
{
5627 typedef GetUniformuiv ValueType
;
5628 static const CommandId kCmdId
= kGetUniformuiv
;
5629 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5630 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5632 typedef SizedResult
<GLuint
> Result
;
5634 static uint32_t ComputeSize() {
5635 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5638 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5640 void Init(GLuint _program
,
5642 uint32_t _params_shm_id
,
5643 uint32_t _params_shm_offset
) {
5646 location
= _location
;
5647 params_shm_id
= _params_shm_id
;
5648 params_shm_offset
= _params_shm_offset
;
5651 void* Set(void* cmd
,
5654 uint32_t _params_shm_id
,
5655 uint32_t _params_shm_offset
) {
5656 static_cast<ValueType
*>(cmd
)
5657 ->Init(_program
, _location
, _params_shm_id
, _params_shm_offset
);
5658 return NextCmdAddress
<ValueType
>(cmd
);
5661 gpu::CommandHeader header
;
5664 uint32_t params_shm_id
;
5665 uint32_t params_shm_offset
;
5668 static_assert(sizeof(GetUniformuiv
) == 20,
5669 "size of GetUniformuiv should be 20");
5670 static_assert(offsetof(GetUniformuiv
, header
) == 0,
5671 "offset of GetUniformuiv header should be 0");
5672 static_assert(offsetof(GetUniformuiv
, program
) == 4,
5673 "offset of GetUniformuiv program should be 4");
5674 static_assert(offsetof(GetUniformuiv
, location
) == 8,
5675 "offset of GetUniformuiv location should be 8");
5676 static_assert(offsetof(GetUniformuiv
, params_shm_id
) == 12,
5677 "offset of GetUniformuiv params_shm_id should be 12");
5678 static_assert(offsetof(GetUniformuiv
, params_shm_offset
) == 16,
5679 "offset of GetUniformuiv params_shm_offset should be 16");
5681 struct GetUniformIndices
{
5682 typedef GetUniformIndices ValueType
;
5683 static const CommandId kCmdId
= kGetUniformIndices
;
5684 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5685 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5687 typedef SizedResult
<GLuint
> Result
;
5689 static uint32_t ComputeSize() {
5690 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5693 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5695 void Init(GLuint _program
,
5696 uint32_t _names_bucket_id
,
5697 uint32_t _indices_shm_id
,
5698 uint32_t _indices_shm_offset
) {
5701 names_bucket_id
= _names_bucket_id
;
5702 indices_shm_id
= _indices_shm_id
;
5703 indices_shm_offset
= _indices_shm_offset
;
5706 void* Set(void* cmd
,
5708 uint32_t _names_bucket_id
,
5709 uint32_t _indices_shm_id
,
5710 uint32_t _indices_shm_offset
) {
5711 static_cast<ValueType
*>(cmd
)->Init(_program
, _names_bucket_id
,
5712 _indices_shm_id
, _indices_shm_offset
);
5713 return NextCmdAddress
<ValueType
>(cmd
);
5716 gpu::CommandHeader header
;
5718 uint32_t names_bucket_id
;
5719 uint32_t indices_shm_id
;
5720 uint32_t indices_shm_offset
;
5723 static_assert(sizeof(GetUniformIndices
) == 20,
5724 "size of GetUniformIndices should be 20");
5725 static_assert(offsetof(GetUniformIndices
, header
) == 0,
5726 "offset of GetUniformIndices header should be 0");
5727 static_assert(offsetof(GetUniformIndices
, program
) == 4,
5728 "offset of GetUniformIndices program should be 4");
5729 static_assert(offsetof(GetUniformIndices
, names_bucket_id
) == 8,
5730 "offset of GetUniformIndices names_bucket_id should be 8");
5731 static_assert(offsetof(GetUniformIndices
, indices_shm_id
) == 12,
5732 "offset of GetUniformIndices indices_shm_id should be 12");
5733 static_assert(offsetof(GetUniformIndices
, indices_shm_offset
) == 16,
5734 "offset of GetUniformIndices indices_shm_offset should be 16");
5736 struct GetUniformLocation
{
5737 typedef GetUniformLocation ValueType
;
5738 static const CommandId kCmdId
= kGetUniformLocation
;
5739 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5740 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5742 typedef GLint Result
;
5744 static uint32_t ComputeSize() {
5745 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5748 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5750 void Init(GLuint _program
,
5751 uint32_t _name_bucket_id
,
5752 uint32_t _location_shm_id
,
5753 uint32_t _location_shm_offset
) {
5756 name_bucket_id
= _name_bucket_id
;
5757 location_shm_id
= _location_shm_id
;
5758 location_shm_offset
= _location_shm_offset
;
5761 void* Set(void* cmd
,
5763 uint32_t _name_bucket_id
,
5764 uint32_t _location_shm_id
,
5765 uint32_t _location_shm_offset
) {
5766 static_cast<ValueType
*>(cmd
)->Init(_program
, _name_bucket_id
,
5767 _location_shm_id
, _location_shm_offset
);
5768 return NextCmdAddress
<ValueType
>(cmd
);
5771 gpu::CommandHeader header
;
5773 uint32_t name_bucket_id
;
5774 uint32_t location_shm_id
;
5775 uint32_t location_shm_offset
;
5778 static_assert(sizeof(GetUniformLocation
) == 20,
5779 "size of GetUniformLocation should be 20");
5780 static_assert(offsetof(GetUniformLocation
, header
) == 0,
5781 "offset of GetUniformLocation header should be 0");
5782 static_assert(offsetof(GetUniformLocation
, program
) == 4,
5783 "offset of GetUniformLocation program should be 4");
5784 static_assert(offsetof(GetUniformLocation
, name_bucket_id
) == 8,
5785 "offset of GetUniformLocation name_bucket_id should be 8");
5786 static_assert(offsetof(GetUniformLocation
, location_shm_id
) == 12,
5787 "offset of GetUniformLocation location_shm_id should be 12");
5788 static_assert(offsetof(GetUniformLocation
, location_shm_offset
) == 16,
5789 "offset of GetUniformLocation location_shm_offset should be 16");
5791 struct GetVertexAttribfv
{
5792 typedef GetVertexAttribfv ValueType
;
5793 static const CommandId kCmdId
= kGetVertexAttribfv
;
5794 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5795 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5797 typedef SizedResult
<GLfloat
> Result
;
5799 static uint32_t ComputeSize() {
5800 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5803 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5805 void Init(GLuint _index
,
5807 uint32_t _params_shm_id
,
5808 uint32_t _params_shm_offset
) {
5812 params_shm_id
= _params_shm_id
;
5813 params_shm_offset
= _params_shm_offset
;
5816 void* Set(void* cmd
,
5819 uint32_t _params_shm_id
,
5820 uint32_t _params_shm_offset
) {
5821 static_cast<ValueType
*>(cmd
)
5822 ->Init(_index
, _pname
, _params_shm_id
, _params_shm_offset
);
5823 return NextCmdAddress
<ValueType
>(cmd
);
5826 gpu::CommandHeader header
;
5829 uint32_t params_shm_id
;
5830 uint32_t params_shm_offset
;
5833 static_assert(sizeof(GetVertexAttribfv
) == 20,
5834 "size of GetVertexAttribfv should be 20");
5835 static_assert(offsetof(GetVertexAttribfv
, header
) == 0,
5836 "offset of GetVertexAttribfv header should be 0");
5837 static_assert(offsetof(GetVertexAttribfv
, index
) == 4,
5838 "offset of GetVertexAttribfv index should be 4");
5839 static_assert(offsetof(GetVertexAttribfv
, pname
) == 8,
5840 "offset of GetVertexAttribfv pname should be 8");
5841 static_assert(offsetof(GetVertexAttribfv
, params_shm_id
) == 12,
5842 "offset of GetVertexAttribfv params_shm_id should be 12");
5843 static_assert(offsetof(GetVertexAttribfv
, params_shm_offset
) == 16,
5844 "offset of GetVertexAttribfv params_shm_offset should be 16");
5846 struct GetVertexAttribiv
{
5847 typedef GetVertexAttribiv ValueType
;
5848 static const CommandId kCmdId
= kGetVertexAttribiv
;
5849 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5850 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5852 typedef SizedResult
<GLint
> Result
;
5854 static uint32_t ComputeSize() {
5855 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5858 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5860 void Init(GLuint _index
,
5862 uint32_t _params_shm_id
,
5863 uint32_t _params_shm_offset
) {
5867 params_shm_id
= _params_shm_id
;
5868 params_shm_offset
= _params_shm_offset
;
5871 void* Set(void* cmd
,
5874 uint32_t _params_shm_id
,
5875 uint32_t _params_shm_offset
) {
5876 static_cast<ValueType
*>(cmd
)
5877 ->Init(_index
, _pname
, _params_shm_id
, _params_shm_offset
);
5878 return NextCmdAddress
<ValueType
>(cmd
);
5881 gpu::CommandHeader header
;
5884 uint32_t params_shm_id
;
5885 uint32_t params_shm_offset
;
5888 static_assert(sizeof(GetVertexAttribiv
) == 20,
5889 "size of GetVertexAttribiv should be 20");
5890 static_assert(offsetof(GetVertexAttribiv
, header
) == 0,
5891 "offset of GetVertexAttribiv header should be 0");
5892 static_assert(offsetof(GetVertexAttribiv
, index
) == 4,
5893 "offset of GetVertexAttribiv index should be 4");
5894 static_assert(offsetof(GetVertexAttribiv
, pname
) == 8,
5895 "offset of GetVertexAttribiv pname should be 8");
5896 static_assert(offsetof(GetVertexAttribiv
, params_shm_id
) == 12,
5897 "offset of GetVertexAttribiv params_shm_id should be 12");
5898 static_assert(offsetof(GetVertexAttribiv
, params_shm_offset
) == 16,
5899 "offset of GetVertexAttribiv params_shm_offset should be 16");
5901 struct GetVertexAttribIiv
{
5902 typedef GetVertexAttribIiv ValueType
;
5903 static const CommandId kCmdId
= kGetVertexAttribIiv
;
5904 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5905 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5907 typedef SizedResult
<GLint
> Result
;
5909 static uint32_t ComputeSize() {
5910 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5913 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5915 void Init(GLuint _index
,
5917 uint32_t _params_shm_id
,
5918 uint32_t _params_shm_offset
) {
5922 params_shm_id
= _params_shm_id
;
5923 params_shm_offset
= _params_shm_offset
;
5926 void* Set(void* cmd
,
5929 uint32_t _params_shm_id
,
5930 uint32_t _params_shm_offset
) {
5931 static_cast<ValueType
*>(cmd
)
5932 ->Init(_index
, _pname
, _params_shm_id
, _params_shm_offset
);
5933 return NextCmdAddress
<ValueType
>(cmd
);
5936 gpu::CommandHeader header
;
5939 uint32_t params_shm_id
;
5940 uint32_t params_shm_offset
;
5943 static_assert(sizeof(GetVertexAttribIiv
) == 20,
5944 "size of GetVertexAttribIiv should be 20");
5945 static_assert(offsetof(GetVertexAttribIiv
, header
) == 0,
5946 "offset of GetVertexAttribIiv header should be 0");
5947 static_assert(offsetof(GetVertexAttribIiv
, index
) == 4,
5948 "offset of GetVertexAttribIiv index should be 4");
5949 static_assert(offsetof(GetVertexAttribIiv
, pname
) == 8,
5950 "offset of GetVertexAttribIiv pname should be 8");
5951 static_assert(offsetof(GetVertexAttribIiv
, params_shm_id
) == 12,
5952 "offset of GetVertexAttribIiv params_shm_id should be 12");
5953 static_assert(offsetof(GetVertexAttribIiv
, params_shm_offset
) == 16,
5954 "offset of GetVertexAttribIiv params_shm_offset should be 16");
5956 struct GetVertexAttribIuiv
{
5957 typedef GetVertexAttribIuiv ValueType
;
5958 static const CommandId kCmdId
= kGetVertexAttribIuiv
;
5959 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
5960 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
5962 typedef SizedResult
<GLuint
> Result
;
5964 static uint32_t ComputeSize() {
5965 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
5968 void SetHeader() { header
.SetCmd
<ValueType
>(); }
5970 void Init(GLuint _index
,
5972 uint32_t _params_shm_id
,
5973 uint32_t _params_shm_offset
) {
5977 params_shm_id
= _params_shm_id
;
5978 params_shm_offset
= _params_shm_offset
;
5981 void* Set(void* cmd
,
5984 uint32_t _params_shm_id
,
5985 uint32_t _params_shm_offset
) {
5986 static_cast<ValueType
*>(cmd
)
5987 ->Init(_index
, _pname
, _params_shm_id
, _params_shm_offset
);
5988 return NextCmdAddress
<ValueType
>(cmd
);
5991 gpu::CommandHeader header
;
5994 uint32_t params_shm_id
;
5995 uint32_t params_shm_offset
;
5998 static_assert(sizeof(GetVertexAttribIuiv
) == 20,
5999 "size of GetVertexAttribIuiv should be 20");
6000 static_assert(offsetof(GetVertexAttribIuiv
, header
) == 0,
6001 "offset of GetVertexAttribIuiv header should be 0");
6002 static_assert(offsetof(GetVertexAttribIuiv
, index
) == 4,
6003 "offset of GetVertexAttribIuiv index should be 4");
6004 static_assert(offsetof(GetVertexAttribIuiv
, pname
) == 8,
6005 "offset of GetVertexAttribIuiv pname should be 8");
6006 static_assert(offsetof(GetVertexAttribIuiv
, params_shm_id
) == 12,
6007 "offset of GetVertexAttribIuiv params_shm_id should be 12");
6008 static_assert(offsetof(GetVertexAttribIuiv
, params_shm_offset
) == 16,
6009 "offset of GetVertexAttribIuiv params_shm_offset should be 16");
6011 struct GetVertexAttribPointerv
{
6012 typedef GetVertexAttribPointerv ValueType
;
6013 static const CommandId kCmdId
= kGetVertexAttribPointerv
;
6014 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6015 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6017 typedef SizedResult
<GLuint
> Result
;
6019 static uint32_t ComputeSize() {
6020 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6023 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6025 void Init(GLuint _index
,
6027 uint32_t _pointer_shm_id
,
6028 uint32_t _pointer_shm_offset
) {
6032 pointer_shm_id
= _pointer_shm_id
;
6033 pointer_shm_offset
= _pointer_shm_offset
;
6036 void* Set(void* cmd
,
6039 uint32_t _pointer_shm_id
,
6040 uint32_t _pointer_shm_offset
) {
6041 static_cast<ValueType
*>(cmd
)
6042 ->Init(_index
, _pname
, _pointer_shm_id
, _pointer_shm_offset
);
6043 return NextCmdAddress
<ValueType
>(cmd
);
6046 gpu::CommandHeader header
;
6049 uint32_t pointer_shm_id
;
6050 uint32_t pointer_shm_offset
;
6053 static_assert(sizeof(GetVertexAttribPointerv
) == 20,
6054 "size of GetVertexAttribPointerv should be 20");
6055 static_assert(offsetof(GetVertexAttribPointerv
, header
) == 0,
6056 "offset of GetVertexAttribPointerv header should be 0");
6057 static_assert(offsetof(GetVertexAttribPointerv
, index
) == 4,
6058 "offset of GetVertexAttribPointerv index should be 4");
6059 static_assert(offsetof(GetVertexAttribPointerv
, pname
) == 8,
6060 "offset of GetVertexAttribPointerv pname should be 8");
6061 static_assert(offsetof(GetVertexAttribPointerv
, pointer_shm_id
) == 12,
6062 "offset of GetVertexAttribPointerv pointer_shm_id should be 12");
6064 offsetof(GetVertexAttribPointerv
, pointer_shm_offset
) == 16,
6065 "offset of GetVertexAttribPointerv pointer_shm_offset should be 16");
6068 typedef Hint ValueType
;
6069 static const CommandId kCmdId
= kHint
;
6070 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6071 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6073 static uint32_t ComputeSize() {
6074 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6077 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6079 void Init(GLenum _target
, GLenum _mode
) {
6085 void* Set(void* cmd
, GLenum _target
, GLenum _mode
) {
6086 static_cast<ValueType
*>(cmd
)->Init(_target
, _mode
);
6087 return NextCmdAddress
<ValueType
>(cmd
);
6090 gpu::CommandHeader header
;
6095 static_assert(sizeof(Hint
) == 12, "size of Hint should be 12");
6096 static_assert(offsetof(Hint
, header
) == 0, "offset of Hint header should be 0");
6097 static_assert(offsetof(Hint
, target
) == 4, "offset of Hint target should be 4");
6098 static_assert(offsetof(Hint
, mode
) == 8, "offset of Hint mode should be 8");
6100 struct InvalidateFramebufferImmediate
{
6101 typedef InvalidateFramebufferImmediate ValueType
;
6102 static const CommandId kCmdId
= kInvalidateFramebufferImmediate
;
6103 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
6104 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6106 static uint32_t ComputeDataSize(GLsizei count
) {
6107 return static_cast<uint32_t>(sizeof(GLenum
) * 1 * count
); // NOLINT
6110 static uint32_t ComputeSize(GLsizei count
) {
6111 return static_cast<uint32_t>(sizeof(ValueType
) +
6112 ComputeDataSize(count
)); // NOLINT
6115 void SetHeader(GLsizei count
) {
6116 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
6119 void Init(GLenum _target
, GLsizei _count
, const GLenum
* _attachments
) {
6123 memcpy(ImmediateDataAddress(this), _attachments
, ComputeDataSize(_count
));
6126 void* Set(void* cmd
,
6129 const GLenum
* _attachments
) {
6130 static_cast<ValueType
*>(cmd
)->Init(_target
, _count
, _attachments
);
6131 const uint32_t size
= ComputeSize(_count
);
6132 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
6135 gpu::CommandHeader header
;
6140 static_assert(sizeof(InvalidateFramebufferImmediate
) == 12,
6141 "size of InvalidateFramebufferImmediate should be 12");
6142 static_assert(offsetof(InvalidateFramebufferImmediate
, header
) == 0,
6143 "offset of InvalidateFramebufferImmediate header should be 0");
6144 static_assert(offsetof(InvalidateFramebufferImmediate
, target
) == 4,
6145 "offset of InvalidateFramebufferImmediate target should be 4");
6146 static_assert(offsetof(InvalidateFramebufferImmediate
, count
) == 8,
6147 "offset of InvalidateFramebufferImmediate count should be 8");
6149 struct InvalidateSubFramebufferImmediate
{
6150 typedef InvalidateSubFramebufferImmediate ValueType
;
6151 static const CommandId kCmdId
= kInvalidateSubFramebufferImmediate
;
6152 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
6153 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6155 static uint32_t ComputeDataSize(GLsizei count
) {
6156 return static_cast<uint32_t>(sizeof(GLenum
) * 1 * count
); // NOLINT
6159 static uint32_t ComputeSize(GLsizei count
) {
6160 return static_cast<uint32_t>(sizeof(ValueType
) +
6161 ComputeDataSize(count
)); // NOLINT
6164 void SetHeader(GLsizei count
) {
6165 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
6168 void Init(GLenum _target
,
6170 const GLenum
* _attachments
,
6182 memcpy(ImmediateDataAddress(this), _attachments
, ComputeDataSize(_count
));
6185 void* Set(void* cmd
,
6188 const GLenum
* _attachments
,
6193 static_cast<ValueType
*>(cmd
)
6194 ->Init(_target
, _count
, _attachments
, _x
, _y
, _width
, _height
);
6195 const uint32_t size
= ComputeSize(_count
);
6196 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
6199 gpu::CommandHeader header
;
6208 static_assert(sizeof(InvalidateSubFramebufferImmediate
) == 28,
6209 "size of InvalidateSubFramebufferImmediate should be 28");
6210 static_assert(offsetof(InvalidateSubFramebufferImmediate
, header
) == 0,
6211 "offset of InvalidateSubFramebufferImmediate header should be 0");
6212 static_assert(offsetof(InvalidateSubFramebufferImmediate
, target
) == 4,
6213 "offset of InvalidateSubFramebufferImmediate target should be 4");
6214 static_assert(offsetof(InvalidateSubFramebufferImmediate
, count
) == 8,
6215 "offset of InvalidateSubFramebufferImmediate count should be 8");
6216 static_assert(offsetof(InvalidateSubFramebufferImmediate
, x
) == 12,
6217 "offset of InvalidateSubFramebufferImmediate x should be 12");
6218 static_assert(offsetof(InvalidateSubFramebufferImmediate
, y
) == 16,
6219 "offset of InvalidateSubFramebufferImmediate y should be 16");
6220 static_assert(offsetof(InvalidateSubFramebufferImmediate
, width
) == 20,
6221 "offset of InvalidateSubFramebufferImmediate width should be 20");
6223 offsetof(InvalidateSubFramebufferImmediate
, height
) == 24,
6224 "offset of InvalidateSubFramebufferImmediate height should be 24");
6227 typedef IsBuffer ValueType
;
6228 static const CommandId kCmdId
= kIsBuffer
;
6229 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6230 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6232 typedef uint32_t Result
;
6234 static uint32_t ComputeSize() {
6235 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6238 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6240 void Init(GLuint _buffer
,
6241 uint32_t _result_shm_id
,
6242 uint32_t _result_shm_offset
) {
6245 result_shm_id
= _result_shm_id
;
6246 result_shm_offset
= _result_shm_offset
;
6249 void* Set(void* cmd
,
6251 uint32_t _result_shm_id
,
6252 uint32_t _result_shm_offset
) {
6253 static_cast<ValueType
*>(cmd
)
6254 ->Init(_buffer
, _result_shm_id
, _result_shm_offset
);
6255 return NextCmdAddress
<ValueType
>(cmd
);
6258 gpu::CommandHeader header
;
6260 uint32_t result_shm_id
;
6261 uint32_t result_shm_offset
;
6264 static_assert(sizeof(IsBuffer
) == 16, "size of IsBuffer should be 16");
6265 static_assert(offsetof(IsBuffer
, header
) == 0,
6266 "offset of IsBuffer header should be 0");
6267 static_assert(offsetof(IsBuffer
, buffer
) == 4,
6268 "offset of IsBuffer buffer should be 4");
6269 static_assert(offsetof(IsBuffer
, result_shm_id
) == 8,
6270 "offset of IsBuffer result_shm_id should be 8");
6271 static_assert(offsetof(IsBuffer
, result_shm_offset
) == 12,
6272 "offset of IsBuffer result_shm_offset should be 12");
6275 typedef IsEnabled ValueType
;
6276 static const CommandId kCmdId
= kIsEnabled
;
6277 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6278 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6280 typedef uint32_t Result
;
6282 static uint32_t ComputeSize() {
6283 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6286 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6288 void Init(GLenum _cap
, uint32_t _result_shm_id
, uint32_t _result_shm_offset
) {
6291 result_shm_id
= _result_shm_id
;
6292 result_shm_offset
= _result_shm_offset
;
6295 void* Set(void* cmd
,
6297 uint32_t _result_shm_id
,
6298 uint32_t _result_shm_offset
) {
6299 static_cast<ValueType
*>(cmd
)
6300 ->Init(_cap
, _result_shm_id
, _result_shm_offset
);
6301 return NextCmdAddress
<ValueType
>(cmd
);
6304 gpu::CommandHeader header
;
6306 uint32_t result_shm_id
;
6307 uint32_t result_shm_offset
;
6310 static_assert(sizeof(IsEnabled
) == 16, "size of IsEnabled should be 16");
6311 static_assert(offsetof(IsEnabled
, header
) == 0,
6312 "offset of IsEnabled header should be 0");
6313 static_assert(offsetof(IsEnabled
, cap
) == 4,
6314 "offset of IsEnabled cap should be 4");
6315 static_assert(offsetof(IsEnabled
, result_shm_id
) == 8,
6316 "offset of IsEnabled result_shm_id should be 8");
6317 static_assert(offsetof(IsEnabled
, result_shm_offset
) == 12,
6318 "offset of IsEnabled result_shm_offset should be 12");
6320 struct IsFramebuffer
{
6321 typedef IsFramebuffer ValueType
;
6322 static const CommandId kCmdId
= kIsFramebuffer
;
6323 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6324 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6326 typedef uint32_t Result
;
6328 static uint32_t ComputeSize() {
6329 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6332 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6334 void Init(GLuint _framebuffer
,
6335 uint32_t _result_shm_id
,
6336 uint32_t _result_shm_offset
) {
6338 framebuffer
= _framebuffer
;
6339 result_shm_id
= _result_shm_id
;
6340 result_shm_offset
= _result_shm_offset
;
6343 void* Set(void* cmd
,
6344 GLuint _framebuffer
,
6345 uint32_t _result_shm_id
,
6346 uint32_t _result_shm_offset
) {
6347 static_cast<ValueType
*>(cmd
)
6348 ->Init(_framebuffer
, _result_shm_id
, _result_shm_offset
);
6349 return NextCmdAddress
<ValueType
>(cmd
);
6352 gpu::CommandHeader header
;
6353 uint32_t framebuffer
;
6354 uint32_t result_shm_id
;
6355 uint32_t result_shm_offset
;
6358 static_assert(sizeof(IsFramebuffer
) == 16,
6359 "size of IsFramebuffer should be 16");
6360 static_assert(offsetof(IsFramebuffer
, header
) == 0,
6361 "offset of IsFramebuffer header should be 0");
6362 static_assert(offsetof(IsFramebuffer
, framebuffer
) == 4,
6363 "offset of IsFramebuffer framebuffer should be 4");
6364 static_assert(offsetof(IsFramebuffer
, result_shm_id
) == 8,
6365 "offset of IsFramebuffer result_shm_id should be 8");
6366 static_assert(offsetof(IsFramebuffer
, result_shm_offset
) == 12,
6367 "offset of IsFramebuffer result_shm_offset should be 12");
6370 typedef IsProgram ValueType
;
6371 static const CommandId kCmdId
= kIsProgram
;
6372 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6373 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6375 typedef uint32_t Result
;
6377 static uint32_t ComputeSize() {
6378 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6381 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6383 void Init(GLuint _program
,
6384 uint32_t _result_shm_id
,
6385 uint32_t _result_shm_offset
) {
6388 result_shm_id
= _result_shm_id
;
6389 result_shm_offset
= _result_shm_offset
;
6392 void* Set(void* cmd
,
6394 uint32_t _result_shm_id
,
6395 uint32_t _result_shm_offset
) {
6396 static_cast<ValueType
*>(cmd
)
6397 ->Init(_program
, _result_shm_id
, _result_shm_offset
);
6398 return NextCmdAddress
<ValueType
>(cmd
);
6401 gpu::CommandHeader header
;
6403 uint32_t result_shm_id
;
6404 uint32_t result_shm_offset
;
6407 static_assert(sizeof(IsProgram
) == 16, "size of IsProgram should be 16");
6408 static_assert(offsetof(IsProgram
, header
) == 0,
6409 "offset of IsProgram header should be 0");
6410 static_assert(offsetof(IsProgram
, program
) == 4,
6411 "offset of IsProgram program should be 4");
6412 static_assert(offsetof(IsProgram
, result_shm_id
) == 8,
6413 "offset of IsProgram result_shm_id should be 8");
6414 static_assert(offsetof(IsProgram
, result_shm_offset
) == 12,
6415 "offset of IsProgram result_shm_offset should be 12");
6417 struct IsRenderbuffer
{
6418 typedef IsRenderbuffer ValueType
;
6419 static const CommandId kCmdId
= kIsRenderbuffer
;
6420 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6421 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6423 typedef uint32_t Result
;
6425 static uint32_t ComputeSize() {
6426 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6429 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6431 void Init(GLuint _renderbuffer
,
6432 uint32_t _result_shm_id
,
6433 uint32_t _result_shm_offset
) {
6435 renderbuffer
= _renderbuffer
;
6436 result_shm_id
= _result_shm_id
;
6437 result_shm_offset
= _result_shm_offset
;
6440 void* Set(void* cmd
,
6441 GLuint _renderbuffer
,
6442 uint32_t _result_shm_id
,
6443 uint32_t _result_shm_offset
) {
6444 static_cast<ValueType
*>(cmd
)
6445 ->Init(_renderbuffer
, _result_shm_id
, _result_shm_offset
);
6446 return NextCmdAddress
<ValueType
>(cmd
);
6449 gpu::CommandHeader header
;
6450 uint32_t renderbuffer
;
6451 uint32_t result_shm_id
;
6452 uint32_t result_shm_offset
;
6455 static_assert(sizeof(IsRenderbuffer
) == 16,
6456 "size of IsRenderbuffer should be 16");
6457 static_assert(offsetof(IsRenderbuffer
, header
) == 0,
6458 "offset of IsRenderbuffer header should be 0");
6459 static_assert(offsetof(IsRenderbuffer
, renderbuffer
) == 4,
6460 "offset of IsRenderbuffer renderbuffer should be 4");
6461 static_assert(offsetof(IsRenderbuffer
, result_shm_id
) == 8,
6462 "offset of IsRenderbuffer result_shm_id should be 8");
6463 static_assert(offsetof(IsRenderbuffer
, result_shm_offset
) == 12,
6464 "offset of IsRenderbuffer result_shm_offset should be 12");
6467 typedef IsSampler ValueType
;
6468 static const CommandId kCmdId
= kIsSampler
;
6469 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6470 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6472 typedef uint32_t Result
;
6474 static uint32_t ComputeSize() {
6475 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6478 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6480 void Init(GLuint _sampler
,
6481 uint32_t _result_shm_id
,
6482 uint32_t _result_shm_offset
) {
6485 result_shm_id
= _result_shm_id
;
6486 result_shm_offset
= _result_shm_offset
;
6489 void* Set(void* cmd
,
6491 uint32_t _result_shm_id
,
6492 uint32_t _result_shm_offset
) {
6493 static_cast<ValueType
*>(cmd
)
6494 ->Init(_sampler
, _result_shm_id
, _result_shm_offset
);
6495 return NextCmdAddress
<ValueType
>(cmd
);
6498 gpu::CommandHeader header
;
6500 uint32_t result_shm_id
;
6501 uint32_t result_shm_offset
;
6504 static_assert(sizeof(IsSampler
) == 16, "size of IsSampler should be 16");
6505 static_assert(offsetof(IsSampler
, header
) == 0,
6506 "offset of IsSampler header should be 0");
6507 static_assert(offsetof(IsSampler
, sampler
) == 4,
6508 "offset of IsSampler sampler should be 4");
6509 static_assert(offsetof(IsSampler
, result_shm_id
) == 8,
6510 "offset of IsSampler result_shm_id should be 8");
6511 static_assert(offsetof(IsSampler
, result_shm_offset
) == 12,
6512 "offset of IsSampler result_shm_offset should be 12");
6515 typedef IsShader ValueType
;
6516 static const CommandId kCmdId
= kIsShader
;
6517 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6518 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6520 typedef uint32_t Result
;
6522 static uint32_t ComputeSize() {
6523 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6526 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6528 void Init(GLuint _shader
,
6529 uint32_t _result_shm_id
,
6530 uint32_t _result_shm_offset
) {
6533 result_shm_id
= _result_shm_id
;
6534 result_shm_offset
= _result_shm_offset
;
6537 void* Set(void* cmd
,
6539 uint32_t _result_shm_id
,
6540 uint32_t _result_shm_offset
) {
6541 static_cast<ValueType
*>(cmd
)
6542 ->Init(_shader
, _result_shm_id
, _result_shm_offset
);
6543 return NextCmdAddress
<ValueType
>(cmd
);
6546 gpu::CommandHeader header
;
6548 uint32_t result_shm_id
;
6549 uint32_t result_shm_offset
;
6552 static_assert(sizeof(IsShader
) == 16, "size of IsShader should be 16");
6553 static_assert(offsetof(IsShader
, header
) == 0,
6554 "offset of IsShader header should be 0");
6555 static_assert(offsetof(IsShader
, shader
) == 4,
6556 "offset of IsShader shader should be 4");
6557 static_assert(offsetof(IsShader
, result_shm_id
) == 8,
6558 "offset of IsShader result_shm_id should be 8");
6559 static_assert(offsetof(IsShader
, result_shm_offset
) == 12,
6560 "offset of IsShader result_shm_offset should be 12");
6563 typedef IsSync ValueType
;
6564 static const CommandId kCmdId
= kIsSync
;
6565 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6566 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6568 typedef uint32_t Result
;
6570 static uint32_t ComputeSize() {
6571 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6574 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6576 void Init(GLuint _sync
,
6577 uint32_t _result_shm_id
,
6578 uint32_t _result_shm_offset
) {
6581 result_shm_id
= _result_shm_id
;
6582 result_shm_offset
= _result_shm_offset
;
6585 void* Set(void* cmd
,
6587 uint32_t _result_shm_id
,
6588 uint32_t _result_shm_offset
) {
6589 static_cast<ValueType
*>(cmd
)
6590 ->Init(_sync
, _result_shm_id
, _result_shm_offset
);
6591 return NextCmdAddress
<ValueType
>(cmd
);
6594 gpu::CommandHeader header
;
6596 uint32_t result_shm_id
;
6597 uint32_t result_shm_offset
;
6600 static_assert(sizeof(IsSync
) == 16, "size of IsSync should be 16");
6601 static_assert(offsetof(IsSync
, header
) == 0,
6602 "offset of IsSync header should be 0");
6603 static_assert(offsetof(IsSync
, sync
) == 4, "offset of IsSync sync should be 4");
6604 static_assert(offsetof(IsSync
, result_shm_id
) == 8,
6605 "offset of IsSync result_shm_id should be 8");
6606 static_assert(offsetof(IsSync
, result_shm_offset
) == 12,
6607 "offset of IsSync result_shm_offset should be 12");
6610 typedef IsTexture ValueType
;
6611 static const CommandId kCmdId
= kIsTexture
;
6612 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6613 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6615 typedef uint32_t Result
;
6617 static uint32_t ComputeSize() {
6618 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6621 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6623 void Init(GLuint _texture
,
6624 uint32_t _result_shm_id
,
6625 uint32_t _result_shm_offset
) {
6628 result_shm_id
= _result_shm_id
;
6629 result_shm_offset
= _result_shm_offset
;
6632 void* Set(void* cmd
,
6634 uint32_t _result_shm_id
,
6635 uint32_t _result_shm_offset
) {
6636 static_cast<ValueType
*>(cmd
)
6637 ->Init(_texture
, _result_shm_id
, _result_shm_offset
);
6638 return NextCmdAddress
<ValueType
>(cmd
);
6641 gpu::CommandHeader header
;
6643 uint32_t result_shm_id
;
6644 uint32_t result_shm_offset
;
6647 static_assert(sizeof(IsTexture
) == 16, "size of IsTexture should be 16");
6648 static_assert(offsetof(IsTexture
, header
) == 0,
6649 "offset of IsTexture header should be 0");
6650 static_assert(offsetof(IsTexture
, texture
) == 4,
6651 "offset of IsTexture texture should be 4");
6652 static_assert(offsetof(IsTexture
, result_shm_id
) == 8,
6653 "offset of IsTexture result_shm_id should be 8");
6654 static_assert(offsetof(IsTexture
, result_shm_offset
) == 12,
6655 "offset of IsTexture result_shm_offset should be 12");
6657 struct IsTransformFeedback
{
6658 typedef IsTransformFeedback ValueType
;
6659 static const CommandId kCmdId
= kIsTransformFeedback
;
6660 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6661 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6663 typedef uint32_t Result
;
6665 static uint32_t ComputeSize() {
6666 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6669 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6671 void Init(GLuint _transformfeedback
,
6672 uint32_t _result_shm_id
,
6673 uint32_t _result_shm_offset
) {
6675 transformfeedback
= _transformfeedback
;
6676 result_shm_id
= _result_shm_id
;
6677 result_shm_offset
= _result_shm_offset
;
6680 void* Set(void* cmd
,
6681 GLuint _transformfeedback
,
6682 uint32_t _result_shm_id
,
6683 uint32_t _result_shm_offset
) {
6684 static_cast<ValueType
*>(cmd
)
6685 ->Init(_transformfeedback
, _result_shm_id
, _result_shm_offset
);
6686 return NextCmdAddress
<ValueType
>(cmd
);
6689 gpu::CommandHeader header
;
6690 uint32_t transformfeedback
;
6691 uint32_t result_shm_id
;
6692 uint32_t result_shm_offset
;
6695 static_assert(sizeof(IsTransformFeedback
) == 16,
6696 "size of IsTransformFeedback should be 16");
6697 static_assert(offsetof(IsTransformFeedback
, header
) == 0,
6698 "offset of IsTransformFeedback header should be 0");
6699 static_assert(offsetof(IsTransformFeedback
, transformfeedback
) == 4,
6700 "offset of IsTransformFeedback transformfeedback should be 4");
6701 static_assert(offsetof(IsTransformFeedback
, result_shm_id
) == 8,
6702 "offset of IsTransformFeedback result_shm_id should be 8");
6703 static_assert(offsetof(IsTransformFeedback
, result_shm_offset
) == 12,
6704 "offset of IsTransformFeedback result_shm_offset should be 12");
6707 typedef LineWidth ValueType
;
6708 static const CommandId kCmdId
= kLineWidth
;
6709 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6710 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6712 static uint32_t ComputeSize() {
6713 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6716 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6718 void Init(GLfloat _width
) {
6723 void* Set(void* cmd
, GLfloat _width
) {
6724 static_cast<ValueType
*>(cmd
)->Init(_width
);
6725 return NextCmdAddress
<ValueType
>(cmd
);
6728 gpu::CommandHeader header
;
6732 static_assert(sizeof(LineWidth
) == 8, "size of LineWidth should be 8");
6733 static_assert(offsetof(LineWidth
, header
) == 0,
6734 "offset of LineWidth header should be 0");
6735 static_assert(offsetof(LineWidth
, width
) == 4,
6736 "offset of LineWidth width should be 4");
6738 struct LinkProgram
{
6739 typedef LinkProgram ValueType
;
6740 static const CommandId kCmdId
= kLinkProgram
;
6741 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6742 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
6744 static uint32_t ComputeSize() {
6745 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6748 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6750 void Init(GLuint _program
) {
6755 void* Set(void* cmd
, GLuint _program
) {
6756 static_cast<ValueType
*>(cmd
)->Init(_program
);
6757 return NextCmdAddress
<ValueType
>(cmd
);
6760 gpu::CommandHeader header
;
6764 static_assert(sizeof(LinkProgram
) == 8, "size of LinkProgram should be 8");
6765 static_assert(offsetof(LinkProgram
, header
) == 0,
6766 "offset of LinkProgram header should be 0");
6767 static_assert(offsetof(LinkProgram
, program
) == 4,
6768 "offset of LinkProgram program should be 4");
6770 struct PauseTransformFeedback
{
6771 typedef PauseTransformFeedback ValueType
;
6772 static const CommandId kCmdId
= kPauseTransformFeedback
;
6773 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6774 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6776 static uint32_t ComputeSize() {
6777 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6780 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6782 void Init() { SetHeader(); }
6784 void* Set(void* cmd
) {
6785 static_cast<ValueType
*>(cmd
)->Init();
6786 return NextCmdAddress
<ValueType
>(cmd
);
6789 gpu::CommandHeader header
;
6792 static_assert(sizeof(PauseTransformFeedback
) == 4,
6793 "size of PauseTransformFeedback should be 4");
6794 static_assert(offsetof(PauseTransformFeedback
, header
) == 0,
6795 "offset of PauseTransformFeedback header should be 0");
6797 struct PixelStorei
{
6798 typedef PixelStorei ValueType
;
6799 static const CommandId kCmdId
= kPixelStorei
;
6800 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6801 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6803 static uint32_t ComputeSize() {
6804 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6807 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6809 void Init(GLenum _pname
, GLint _param
) {
6815 void* Set(void* cmd
, GLenum _pname
, GLint _param
) {
6816 static_cast<ValueType
*>(cmd
)->Init(_pname
, _param
);
6817 return NextCmdAddress
<ValueType
>(cmd
);
6820 gpu::CommandHeader header
;
6825 static_assert(sizeof(PixelStorei
) == 12, "size of PixelStorei should be 12");
6826 static_assert(offsetof(PixelStorei
, header
) == 0,
6827 "offset of PixelStorei header should be 0");
6828 static_assert(offsetof(PixelStorei
, pname
) == 4,
6829 "offset of PixelStorei pname should be 4");
6830 static_assert(offsetof(PixelStorei
, param
) == 8,
6831 "offset of PixelStorei param should be 8");
6833 struct PolygonOffset
{
6834 typedef PolygonOffset ValueType
;
6835 static const CommandId kCmdId
= kPolygonOffset
;
6836 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6837 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
6839 static uint32_t ComputeSize() {
6840 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6843 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6845 void Init(GLfloat _factor
, GLfloat _units
) {
6851 void* Set(void* cmd
, GLfloat _factor
, GLfloat _units
) {
6852 static_cast<ValueType
*>(cmd
)->Init(_factor
, _units
);
6853 return NextCmdAddress
<ValueType
>(cmd
);
6856 gpu::CommandHeader header
;
6861 static_assert(sizeof(PolygonOffset
) == 12,
6862 "size of PolygonOffset should be 12");
6863 static_assert(offsetof(PolygonOffset
, header
) == 0,
6864 "offset of PolygonOffset header should be 0");
6865 static_assert(offsetof(PolygonOffset
, factor
) == 4,
6866 "offset of PolygonOffset factor should be 4");
6867 static_assert(offsetof(PolygonOffset
, units
) == 8,
6868 "offset of PolygonOffset units should be 8");
6871 typedef ReadBuffer ValueType
;
6872 static const CommandId kCmdId
= kReadBuffer
;
6873 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6874 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
6876 static uint32_t ComputeSize() {
6877 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6880 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6882 void Init(GLenum _src
) {
6887 void* Set(void* cmd
, GLenum _src
) {
6888 static_cast<ValueType
*>(cmd
)->Init(_src
);
6889 return NextCmdAddress
<ValueType
>(cmd
);
6892 gpu::CommandHeader header
;
6896 static_assert(sizeof(ReadBuffer
) == 8, "size of ReadBuffer should be 8");
6897 static_assert(offsetof(ReadBuffer
, header
) == 0,
6898 "offset of ReadBuffer header should be 0");
6899 static_assert(offsetof(ReadBuffer
, src
) == 4,
6900 "offset of ReadBuffer src should be 4");
6902 // ReadPixels has the result separated from the pixel buffer so that
6903 // it is easier to specify the result going to some specific place
6904 // that exactly fits the rectangle of pixels.
6906 typedef ReadPixels ValueType
;
6907 static const CommandId kCmdId
= kReadPixels
;
6908 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
6909 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
6911 typedef uint32_t Result
;
6913 static uint32_t ComputeSize() {
6914 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
6917 void SetHeader() { header
.SetCmd
<ValueType
>(); }
6925 uint32_t _pixels_shm_id
,
6926 uint32_t _pixels_shm_offset
,
6927 uint32_t _result_shm_id
,
6928 uint32_t _result_shm_offset
,
6937 pixels_shm_id
= _pixels_shm_id
;
6938 pixels_shm_offset
= _pixels_shm_offset
;
6939 result_shm_id
= _result_shm_id
;
6940 result_shm_offset
= _result_shm_offset
;
6944 void* Set(void* cmd
,
6951 uint32_t _pixels_shm_id
,
6952 uint32_t _pixels_shm_offset
,
6953 uint32_t _result_shm_id
,
6954 uint32_t _result_shm_offset
,
6956 static_cast<ValueType
*>(cmd
)
6957 ->Init(_x
, _y
, _width
, _height
, _format
, _type
, _pixels_shm_id
,
6958 _pixels_shm_offset
, _result_shm_id
, _result_shm_offset
, _async
);
6959 return NextCmdAddress
<ValueType
>(cmd
);
6962 gpu::CommandHeader header
;
6969 uint32_t pixels_shm_id
;
6970 uint32_t pixels_shm_offset
;
6971 uint32_t result_shm_id
;
6972 uint32_t result_shm_offset
;
6976 static_assert(sizeof(ReadPixels
) == 48, "size of ReadPixels should be 48");
6977 static_assert(offsetof(ReadPixels
, header
) == 0,
6978 "offset of ReadPixels header should be 0");
6979 static_assert(offsetof(ReadPixels
, x
) == 4,
6980 "offset of ReadPixels x should be 4");
6981 static_assert(offsetof(ReadPixels
, y
) == 8,
6982 "offset of ReadPixels y should be 8");
6983 static_assert(offsetof(ReadPixels
, width
) == 12,
6984 "offset of ReadPixels width should be 12");
6985 static_assert(offsetof(ReadPixels
, height
) == 16,
6986 "offset of ReadPixels height should be 16");
6987 static_assert(offsetof(ReadPixels
, format
) == 20,
6988 "offset of ReadPixels format should be 20");
6989 static_assert(offsetof(ReadPixels
, type
) == 24,
6990 "offset of ReadPixels type should be 24");
6991 static_assert(offsetof(ReadPixels
, pixels_shm_id
) == 28,
6992 "offset of ReadPixels pixels_shm_id should be 28");
6993 static_assert(offsetof(ReadPixels
, pixels_shm_offset
) == 32,
6994 "offset of ReadPixels pixels_shm_offset should be 32");
6995 static_assert(offsetof(ReadPixels
, result_shm_id
) == 36,
6996 "offset of ReadPixels result_shm_id should be 36");
6997 static_assert(offsetof(ReadPixels
, result_shm_offset
) == 40,
6998 "offset of ReadPixels result_shm_offset should be 40");
6999 static_assert(offsetof(ReadPixels
, async
) == 44,
7000 "offset of ReadPixels async should be 44");
7002 struct ReleaseShaderCompiler
{
7003 typedef ReleaseShaderCompiler ValueType
;
7004 static const CommandId kCmdId
= kReleaseShaderCompiler
;
7005 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7006 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7008 static uint32_t ComputeSize() {
7009 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7012 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7014 void Init() { SetHeader(); }
7016 void* Set(void* cmd
) {
7017 static_cast<ValueType
*>(cmd
)->Init();
7018 return NextCmdAddress
<ValueType
>(cmd
);
7021 gpu::CommandHeader header
;
7024 static_assert(sizeof(ReleaseShaderCompiler
) == 4,
7025 "size of ReleaseShaderCompiler should be 4");
7026 static_assert(offsetof(ReleaseShaderCompiler
, header
) == 0,
7027 "offset of ReleaseShaderCompiler header should be 0");
7029 struct RenderbufferStorage
{
7030 typedef RenderbufferStorage ValueType
;
7031 static const CommandId kCmdId
= kRenderbufferStorage
;
7032 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7033 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
7035 static uint32_t ComputeSize() {
7036 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7039 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7041 void Init(GLenum _target
,
7042 GLenum _internalformat
,
7047 internalformat
= _internalformat
;
7052 void* Set(void* cmd
,
7054 GLenum _internalformat
,
7057 static_cast<ValueType
*>(cmd
)
7058 ->Init(_target
, _internalformat
, _width
, _height
);
7059 return NextCmdAddress
<ValueType
>(cmd
);
7062 gpu::CommandHeader header
;
7064 uint32_t internalformat
;
7069 static_assert(sizeof(RenderbufferStorage
) == 20,
7070 "size of RenderbufferStorage should be 20");
7071 static_assert(offsetof(RenderbufferStorage
, header
) == 0,
7072 "offset of RenderbufferStorage header should be 0");
7073 static_assert(offsetof(RenderbufferStorage
, target
) == 4,
7074 "offset of RenderbufferStorage target should be 4");
7075 static_assert(offsetof(RenderbufferStorage
, internalformat
) == 8,
7076 "offset of RenderbufferStorage internalformat should be 8");
7077 static_assert(offsetof(RenderbufferStorage
, width
) == 12,
7078 "offset of RenderbufferStorage width should be 12");
7079 static_assert(offsetof(RenderbufferStorage
, height
) == 16,
7080 "offset of RenderbufferStorage height should be 16");
7082 struct ResumeTransformFeedback
{
7083 typedef ResumeTransformFeedback ValueType
;
7084 static const CommandId kCmdId
= kResumeTransformFeedback
;
7085 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7086 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7088 static uint32_t ComputeSize() {
7089 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7092 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7094 void Init() { SetHeader(); }
7096 void* Set(void* cmd
) {
7097 static_cast<ValueType
*>(cmd
)->Init();
7098 return NextCmdAddress
<ValueType
>(cmd
);
7101 gpu::CommandHeader header
;
7104 static_assert(sizeof(ResumeTransformFeedback
) == 4,
7105 "size of ResumeTransformFeedback should be 4");
7106 static_assert(offsetof(ResumeTransformFeedback
, header
) == 0,
7107 "offset of ResumeTransformFeedback header should be 0");
7109 struct SampleCoverage
{
7110 typedef SampleCoverage ValueType
;
7111 static const CommandId kCmdId
= kSampleCoverage
;
7112 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7113 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7115 static uint32_t ComputeSize() {
7116 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7119 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7121 void Init(GLclampf _value
, GLboolean _invert
) {
7127 void* Set(void* cmd
, GLclampf _value
, GLboolean _invert
) {
7128 static_cast<ValueType
*>(cmd
)->Init(_value
, _invert
);
7129 return NextCmdAddress
<ValueType
>(cmd
);
7132 gpu::CommandHeader header
;
7137 static_assert(sizeof(SampleCoverage
) == 12,
7138 "size of SampleCoverage should be 12");
7139 static_assert(offsetof(SampleCoverage
, header
) == 0,
7140 "offset of SampleCoverage header should be 0");
7141 static_assert(offsetof(SampleCoverage
, value
) == 4,
7142 "offset of SampleCoverage value should be 4");
7143 static_assert(offsetof(SampleCoverage
, invert
) == 8,
7144 "offset of SampleCoverage invert should be 8");
7146 struct SamplerParameterf
{
7147 typedef SamplerParameterf ValueType
;
7148 static const CommandId kCmdId
= kSamplerParameterf
;
7149 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7150 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7152 static uint32_t ComputeSize() {
7153 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7156 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7158 void Init(GLuint _sampler
, GLenum _pname
, GLfloat _param
) {
7165 void* Set(void* cmd
, GLuint _sampler
, GLenum _pname
, GLfloat _param
) {
7166 static_cast<ValueType
*>(cmd
)->Init(_sampler
, _pname
, _param
);
7167 return NextCmdAddress
<ValueType
>(cmd
);
7170 gpu::CommandHeader header
;
7176 static_assert(sizeof(SamplerParameterf
) == 16,
7177 "size of SamplerParameterf should be 16");
7178 static_assert(offsetof(SamplerParameterf
, header
) == 0,
7179 "offset of SamplerParameterf header should be 0");
7180 static_assert(offsetof(SamplerParameterf
, sampler
) == 4,
7181 "offset of SamplerParameterf sampler should be 4");
7182 static_assert(offsetof(SamplerParameterf
, pname
) == 8,
7183 "offset of SamplerParameterf pname should be 8");
7184 static_assert(offsetof(SamplerParameterf
, param
) == 12,
7185 "offset of SamplerParameterf param should be 12");
7187 struct SamplerParameterfvImmediate
{
7188 typedef SamplerParameterfvImmediate ValueType
;
7189 static const CommandId kCmdId
= kSamplerParameterfvImmediate
;
7190 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
7191 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7193 static uint32_t ComputeDataSize() {
7194 return static_cast<uint32_t>(sizeof(GLfloat
) * 1);
7197 static uint32_t ComputeSize() {
7198 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
7201 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
7203 void Init(GLuint _sampler
, GLenum _pname
, const GLfloat
* _params
) {
7207 memcpy(ImmediateDataAddress(this), _params
, ComputeDataSize());
7210 void* Set(void* cmd
, GLuint _sampler
, GLenum _pname
, const GLfloat
* _params
) {
7211 static_cast<ValueType
*>(cmd
)->Init(_sampler
, _pname
, _params
);
7212 const uint32_t size
= ComputeSize();
7213 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
7216 gpu::CommandHeader header
;
7221 static_assert(sizeof(SamplerParameterfvImmediate
) == 12,
7222 "size of SamplerParameterfvImmediate should be 12");
7223 static_assert(offsetof(SamplerParameterfvImmediate
, header
) == 0,
7224 "offset of SamplerParameterfvImmediate header should be 0");
7225 static_assert(offsetof(SamplerParameterfvImmediate
, sampler
) == 4,
7226 "offset of SamplerParameterfvImmediate sampler should be 4");
7227 static_assert(offsetof(SamplerParameterfvImmediate
, pname
) == 8,
7228 "offset of SamplerParameterfvImmediate pname should be 8");
7230 struct SamplerParameteri
{
7231 typedef SamplerParameteri ValueType
;
7232 static const CommandId kCmdId
= kSamplerParameteri
;
7233 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7234 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7236 static uint32_t ComputeSize() {
7237 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7240 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7242 void Init(GLuint _sampler
, GLenum _pname
, GLint _param
) {
7249 void* Set(void* cmd
, GLuint _sampler
, GLenum _pname
, GLint _param
) {
7250 static_cast<ValueType
*>(cmd
)->Init(_sampler
, _pname
, _param
);
7251 return NextCmdAddress
<ValueType
>(cmd
);
7254 gpu::CommandHeader header
;
7260 static_assert(sizeof(SamplerParameteri
) == 16,
7261 "size of SamplerParameteri should be 16");
7262 static_assert(offsetof(SamplerParameteri
, header
) == 0,
7263 "offset of SamplerParameteri header should be 0");
7264 static_assert(offsetof(SamplerParameteri
, sampler
) == 4,
7265 "offset of SamplerParameteri sampler should be 4");
7266 static_assert(offsetof(SamplerParameteri
, pname
) == 8,
7267 "offset of SamplerParameteri pname should be 8");
7268 static_assert(offsetof(SamplerParameteri
, param
) == 12,
7269 "offset of SamplerParameteri param should be 12");
7271 struct SamplerParameterivImmediate
{
7272 typedef SamplerParameterivImmediate ValueType
;
7273 static const CommandId kCmdId
= kSamplerParameterivImmediate
;
7274 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
7275 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7277 static uint32_t ComputeDataSize() {
7278 return static_cast<uint32_t>(sizeof(GLint
) * 1);
7281 static uint32_t ComputeSize() {
7282 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
7285 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
7287 void Init(GLuint _sampler
, GLenum _pname
, const GLint
* _params
) {
7291 memcpy(ImmediateDataAddress(this), _params
, ComputeDataSize());
7294 void* Set(void* cmd
, GLuint _sampler
, GLenum _pname
, const GLint
* _params
) {
7295 static_cast<ValueType
*>(cmd
)->Init(_sampler
, _pname
, _params
);
7296 const uint32_t size
= ComputeSize();
7297 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
7300 gpu::CommandHeader header
;
7305 static_assert(sizeof(SamplerParameterivImmediate
) == 12,
7306 "size of SamplerParameterivImmediate should be 12");
7307 static_assert(offsetof(SamplerParameterivImmediate
, header
) == 0,
7308 "offset of SamplerParameterivImmediate header should be 0");
7309 static_assert(offsetof(SamplerParameterivImmediate
, sampler
) == 4,
7310 "offset of SamplerParameterivImmediate sampler should be 4");
7311 static_assert(offsetof(SamplerParameterivImmediate
, pname
) == 8,
7312 "offset of SamplerParameterivImmediate pname should be 8");
7315 typedef Scissor ValueType
;
7316 static const CommandId kCmdId
= kScissor
;
7317 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7318 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7320 static uint32_t ComputeSize() {
7321 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7324 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7326 void Init(GLint _x
, GLint _y
, GLsizei _width
, GLsizei _height
) {
7334 void* Set(void* cmd
, GLint _x
, GLint _y
, GLsizei _width
, GLsizei _height
) {
7335 static_cast<ValueType
*>(cmd
)->Init(_x
, _y
, _width
, _height
);
7336 return NextCmdAddress
<ValueType
>(cmd
);
7339 gpu::CommandHeader header
;
7346 static_assert(sizeof(Scissor
) == 20, "size of Scissor should be 20");
7347 static_assert(offsetof(Scissor
, header
) == 0,
7348 "offset of Scissor header should be 0");
7349 static_assert(offsetof(Scissor
, x
) == 4, "offset of Scissor x should be 4");
7350 static_assert(offsetof(Scissor
, y
) == 8, "offset of Scissor y should be 8");
7351 static_assert(offsetof(Scissor
, width
) == 12,
7352 "offset of Scissor width should be 12");
7353 static_assert(offsetof(Scissor
, height
) == 16,
7354 "offset of Scissor height should be 16");
7356 struct ShaderBinary
{
7357 typedef ShaderBinary ValueType
;
7358 static const CommandId kCmdId
= kShaderBinary
;
7359 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7360 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7362 static uint32_t ComputeSize() {
7363 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7366 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7368 void Init(GLsizei _n
,
7369 uint32_t _shaders_shm_id
,
7370 uint32_t _shaders_shm_offset
,
7371 GLenum _binaryformat
,
7372 uint32_t _binary_shm_id
,
7373 uint32_t _binary_shm_offset
,
7377 shaders_shm_id
= _shaders_shm_id
;
7378 shaders_shm_offset
= _shaders_shm_offset
;
7379 binaryformat
= _binaryformat
;
7380 binary_shm_id
= _binary_shm_id
;
7381 binary_shm_offset
= _binary_shm_offset
;
7385 void* Set(void* cmd
,
7387 uint32_t _shaders_shm_id
,
7388 uint32_t _shaders_shm_offset
,
7389 GLenum _binaryformat
,
7390 uint32_t _binary_shm_id
,
7391 uint32_t _binary_shm_offset
,
7393 static_cast<ValueType
*>(cmd
)->Init(_n
, _shaders_shm_id
, _shaders_shm_offset
,
7394 _binaryformat
, _binary_shm_id
,
7395 _binary_shm_offset
, _length
);
7396 return NextCmdAddress
<ValueType
>(cmd
);
7399 gpu::CommandHeader header
;
7401 uint32_t shaders_shm_id
;
7402 uint32_t shaders_shm_offset
;
7403 uint32_t binaryformat
;
7404 uint32_t binary_shm_id
;
7405 uint32_t binary_shm_offset
;
7409 static_assert(sizeof(ShaderBinary
) == 32, "size of ShaderBinary should be 32");
7410 static_assert(offsetof(ShaderBinary
, header
) == 0,
7411 "offset of ShaderBinary header should be 0");
7412 static_assert(offsetof(ShaderBinary
, n
) == 4,
7413 "offset of ShaderBinary n should be 4");
7414 static_assert(offsetof(ShaderBinary
, shaders_shm_id
) == 8,
7415 "offset of ShaderBinary shaders_shm_id should be 8");
7416 static_assert(offsetof(ShaderBinary
, shaders_shm_offset
) == 12,
7417 "offset of ShaderBinary shaders_shm_offset should be 12");
7418 static_assert(offsetof(ShaderBinary
, binaryformat
) == 16,
7419 "offset of ShaderBinary binaryformat should be 16");
7420 static_assert(offsetof(ShaderBinary
, binary_shm_id
) == 20,
7421 "offset of ShaderBinary binary_shm_id should be 20");
7422 static_assert(offsetof(ShaderBinary
, binary_shm_offset
) == 24,
7423 "offset of ShaderBinary binary_shm_offset should be 24");
7424 static_assert(offsetof(ShaderBinary
, length
) == 28,
7425 "offset of ShaderBinary length should be 28");
7427 struct ShaderSourceBucket
{
7428 typedef ShaderSourceBucket ValueType
;
7429 static const CommandId kCmdId
= kShaderSourceBucket
;
7430 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7431 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7433 static uint32_t ComputeSize() {
7434 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7437 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7439 void Init(GLuint _shader
, uint32_t _str_bucket_id
) {
7442 str_bucket_id
= _str_bucket_id
;
7445 void* Set(void* cmd
, GLuint _shader
, uint32_t _str_bucket_id
) {
7446 static_cast<ValueType
*>(cmd
)->Init(_shader
, _str_bucket_id
);
7447 return NextCmdAddress
<ValueType
>(cmd
);
7450 gpu::CommandHeader header
;
7452 uint32_t str_bucket_id
;
7455 static_assert(sizeof(ShaderSourceBucket
) == 12,
7456 "size of ShaderSourceBucket should be 12");
7457 static_assert(offsetof(ShaderSourceBucket
, header
) == 0,
7458 "offset of ShaderSourceBucket header should be 0");
7459 static_assert(offsetof(ShaderSourceBucket
, shader
) == 4,
7460 "offset of ShaderSourceBucket shader should be 4");
7461 static_assert(offsetof(ShaderSourceBucket
, str_bucket_id
) == 8,
7462 "offset of ShaderSourceBucket str_bucket_id should be 8");
7464 struct StencilFunc
{
7465 typedef StencilFunc ValueType
;
7466 static const CommandId kCmdId
= kStencilFunc
;
7467 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7468 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7470 static uint32_t ComputeSize() {
7471 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7474 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7476 void Init(GLenum _func
, GLint _ref
, GLuint _mask
) {
7483 void* Set(void* cmd
, GLenum _func
, GLint _ref
, GLuint _mask
) {
7484 static_cast<ValueType
*>(cmd
)->Init(_func
, _ref
, _mask
);
7485 return NextCmdAddress
<ValueType
>(cmd
);
7488 gpu::CommandHeader header
;
7494 static_assert(sizeof(StencilFunc
) == 16, "size of StencilFunc should be 16");
7495 static_assert(offsetof(StencilFunc
, header
) == 0,
7496 "offset of StencilFunc header should be 0");
7497 static_assert(offsetof(StencilFunc
, func
) == 4,
7498 "offset of StencilFunc func should be 4");
7499 static_assert(offsetof(StencilFunc
, ref
) == 8,
7500 "offset of StencilFunc ref should be 8");
7501 static_assert(offsetof(StencilFunc
, mask
) == 12,
7502 "offset of StencilFunc mask should be 12");
7504 struct StencilFuncSeparate
{
7505 typedef StencilFuncSeparate ValueType
;
7506 static const CommandId kCmdId
= kStencilFuncSeparate
;
7507 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7508 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7510 static uint32_t ComputeSize() {
7511 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7514 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7516 void Init(GLenum _face
, GLenum _func
, GLint _ref
, GLuint _mask
) {
7524 void* Set(void* cmd
, GLenum _face
, GLenum _func
, GLint _ref
, GLuint _mask
) {
7525 static_cast<ValueType
*>(cmd
)->Init(_face
, _func
, _ref
, _mask
);
7526 return NextCmdAddress
<ValueType
>(cmd
);
7529 gpu::CommandHeader header
;
7536 static_assert(sizeof(StencilFuncSeparate
) == 20,
7537 "size of StencilFuncSeparate should be 20");
7538 static_assert(offsetof(StencilFuncSeparate
, header
) == 0,
7539 "offset of StencilFuncSeparate header should be 0");
7540 static_assert(offsetof(StencilFuncSeparate
, face
) == 4,
7541 "offset of StencilFuncSeparate face should be 4");
7542 static_assert(offsetof(StencilFuncSeparate
, func
) == 8,
7543 "offset of StencilFuncSeparate func should be 8");
7544 static_assert(offsetof(StencilFuncSeparate
, ref
) == 12,
7545 "offset of StencilFuncSeparate ref should be 12");
7546 static_assert(offsetof(StencilFuncSeparate
, mask
) == 16,
7547 "offset of StencilFuncSeparate mask should be 16");
7549 struct StencilMask
{
7550 typedef StencilMask ValueType
;
7551 static const CommandId kCmdId
= kStencilMask
;
7552 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7553 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7555 static uint32_t ComputeSize() {
7556 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7559 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7561 void Init(GLuint _mask
) {
7566 void* Set(void* cmd
, GLuint _mask
) {
7567 static_cast<ValueType
*>(cmd
)->Init(_mask
);
7568 return NextCmdAddress
<ValueType
>(cmd
);
7571 gpu::CommandHeader header
;
7575 static_assert(sizeof(StencilMask
) == 8, "size of StencilMask should be 8");
7576 static_assert(offsetof(StencilMask
, header
) == 0,
7577 "offset of StencilMask header should be 0");
7578 static_assert(offsetof(StencilMask
, mask
) == 4,
7579 "offset of StencilMask mask should be 4");
7581 struct StencilMaskSeparate
{
7582 typedef StencilMaskSeparate ValueType
;
7583 static const CommandId kCmdId
= kStencilMaskSeparate
;
7584 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7585 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7587 static uint32_t ComputeSize() {
7588 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7591 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7593 void Init(GLenum _face
, GLuint _mask
) {
7599 void* Set(void* cmd
, GLenum _face
, GLuint _mask
) {
7600 static_cast<ValueType
*>(cmd
)->Init(_face
, _mask
);
7601 return NextCmdAddress
<ValueType
>(cmd
);
7604 gpu::CommandHeader header
;
7609 static_assert(sizeof(StencilMaskSeparate
) == 12,
7610 "size of StencilMaskSeparate should be 12");
7611 static_assert(offsetof(StencilMaskSeparate
, header
) == 0,
7612 "offset of StencilMaskSeparate header should be 0");
7613 static_assert(offsetof(StencilMaskSeparate
, face
) == 4,
7614 "offset of StencilMaskSeparate face should be 4");
7615 static_assert(offsetof(StencilMaskSeparate
, mask
) == 8,
7616 "offset of StencilMaskSeparate mask should be 8");
7619 typedef StencilOp ValueType
;
7620 static const CommandId kCmdId
= kStencilOp
;
7621 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7622 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7624 static uint32_t ComputeSize() {
7625 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7628 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7630 void Init(GLenum _fail
, GLenum _zfail
, GLenum _zpass
) {
7637 void* Set(void* cmd
, GLenum _fail
, GLenum _zfail
, GLenum _zpass
) {
7638 static_cast<ValueType
*>(cmd
)->Init(_fail
, _zfail
, _zpass
);
7639 return NextCmdAddress
<ValueType
>(cmd
);
7642 gpu::CommandHeader header
;
7648 static_assert(sizeof(StencilOp
) == 16, "size of StencilOp should be 16");
7649 static_assert(offsetof(StencilOp
, header
) == 0,
7650 "offset of StencilOp header should be 0");
7651 static_assert(offsetof(StencilOp
, fail
) == 4,
7652 "offset of StencilOp fail should be 4");
7653 static_assert(offsetof(StencilOp
, zfail
) == 8,
7654 "offset of StencilOp zfail should be 8");
7655 static_assert(offsetof(StencilOp
, zpass
) == 12,
7656 "offset of StencilOp zpass should be 12");
7658 struct StencilOpSeparate
{
7659 typedef StencilOpSeparate ValueType
;
7660 static const CommandId kCmdId
= kStencilOpSeparate
;
7661 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7662 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7664 static uint32_t ComputeSize() {
7665 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7668 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7670 void Init(GLenum _face
, GLenum _fail
, GLenum _zfail
, GLenum _zpass
) {
7678 void* Set(void* cmd
,
7683 static_cast<ValueType
*>(cmd
)->Init(_face
, _fail
, _zfail
, _zpass
);
7684 return NextCmdAddress
<ValueType
>(cmd
);
7687 gpu::CommandHeader header
;
7694 static_assert(sizeof(StencilOpSeparate
) == 20,
7695 "size of StencilOpSeparate should be 20");
7696 static_assert(offsetof(StencilOpSeparate
, header
) == 0,
7697 "offset of StencilOpSeparate header should be 0");
7698 static_assert(offsetof(StencilOpSeparate
, face
) == 4,
7699 "offset of StencilOpSeparate face should be 4");
7700 static_assert(offsetof(StencilOpSeparate
, fail
) == 8,
7701 "offset of StencilOpSeparate fail should be 8");
7702 static_assert(offsetof(StencilOpSeparate
, zfail
) == 12,
7703 "offset of StencilOpSeparate zfail should be 12");
7704 static_assert(offsetof(StencilOpSeparate
, zpass
) == 16,
7705 "offset of StencilOpSeparate zpass should be 16");
7708 typedef TexImage2D ValueType
;
7709 static const CommandId kCmdId
= kTexImage2D
;
7710 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7711 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
7713 static uint32_t ComputeSize() {
7714 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7717 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7719 void Init(GLenum _target
,
7721 GLint _internalformat
,
7726 uint32_t _pixels_shm_id
,
7727 uint32_t _pixels_shm_offset
) {
7731 internalformat
= _internalformat
;
7736 pixels_shm_id
= _pixels_shm_id
;
7737 pixels_shm_offset
= _pixels_shm_offset
;
7740 void* Set(void* cmd
,
7743 GLint _internalformat
,
7748 uint32_t _pixels_shm_id
,
7749 uint32_t _pixels_shm_offset
) {
7750 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _internalformat
, _width
,
7751 _height
, _format
, _type
, _pixels_shm_id
,
7752 _pixels_shm_offset
);
7753 return NextCmdAddress
<ValueType
>(cmd
);
7756 gpu::CommandHeader header
;
7759 int32_t internalformat
;
7764 uint32_t pixels_shm_id
;
7765 uint32_t pixels_shm_offset
;
7766 static const int32_t border
= 0;
7769 static_assert(sizeof(TexImage2D
) == 40, "size of TexImage2D should be 40");
7770 static_assert(offsetof(TexImage2D
, header
) == 0,
7771 "offset of TexImage2D header should be 0");
7772 static_assert(offsetof(TexImage2D
, target
) == 4,
7773 "offset of TexImage2D target should be 4");
7774 static_assert(offsetof(TexImage2D
, level
) == 8,
7775 "offset of TexImage2D level should be 8");
7776 static_assert(offsetof(TexImage2D
, internalformat
) == 12,
7777 "offset of TexImage2D internalformat should be 12");
7778 static_assert(offsetof(TexImage2D
, width
) == 16,
7779 "offset of TexImage2D width should be 16");
7780 static_assert(offsetof(TexImage2D
, height
) == 20,
7781 "offset of TexImage2D height should be 20");
7782 static_assert(offsetof(TexImage2D
, format
) == 24,
7783 "offset of TexImage2D format should be 24");
7784 static_assert(offsetof(TexImage2D
, type
) == 28,
7785 "offset of TexImage2D type should be 28");
7786 static_assert(offsetof(TexImage2D
, pixels_shm_id
) == 32,
7787 "offset of TexImage2D pixels_shm_id should be 32");
7788 static_assert(offsetof(TexImage2D
, pixels_shm_offset
) == 36,
7789 "offset of TexImage2D pixels_shm_offset should be 36");
7792 typedef TexImage3D ValueType
;
7793 static const CommandId kCmdId
= kTexImage3D
;
7794 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7795 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
7797 static uint32_t ComputeSize() {
7798 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7801 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7803 void Init(GLenum _target
,
7805 GLint _internalformat
,
7811 uint32_t _pixels_shm_id
,
7812 uint32_t _pixels_shm_offset
) {
7816 internalformat
= _internalformat
;
7822 pixels_shm_id
= _pixels_shm_id
;
7823 pixels_shm_offset
= _pixels_shm_offset
;
7826 void* Set(void* cmd
,
7829 GLint _internalformat
,
7835 uint32_t _pixels_shm_id
,
7836 uint32_t _pixels_shm_offset
) {
7837 static_cast<ValueType
*>(cmd
)->Init(_target
, _level
, _internalformat
, _width
,
7838 _height
, _depth
, _format
, _type
,
7839 _pixels_shm_id
, _pixels_shm_offset
);
7840 return NextCmdAddress
<ValueType
>(cmd
);
7843 gpu::CommandHeader header
;
7846 int32_t internalformat
;
7852 uint32_t pixels_shm_id
;
7853 uint32_t pixels_shm_offset
;
7854 static const int32_t border
= 0;
7857 static_assert(sizeof(TexImage3D
) == 44, "size of TexImage3D should be 44");
7858 static_assert(offsetof(TexImage3D
, header
) == 0,
7859 "offset of TexImage3D header should be 0");
7860 static_assert(offsetof(TexImage3D
, target
) == 4,
7861 "offset of TexImage3D target should be 4");
7862 static_assert(offsetof(TexImage3D
, level
) == 8,
7863 "offset of TexImage3D level should be 8");
7864 static_assert(offsetof(TexImage3D
, internalformat
) == 12,
7865 "offset of TexImage3D internalformat should be 12");
7866 static_assert(offsetof(TexImage3D
, width
) == 16,
7867 "offset of TexImage3D width should be 16");
7868 static_assert(offsetof(TexImage3D
, height
) == 20,
7869 "offset of TexImage3D height should be 20");
7870 static_assert(offsetof(TexImage3D
, depth
) == 24,
7871 "offset of TexImage3D depth should be 24");
7872 static_assert(offsetof(TexImage3D
, format
) == 28,
7873 "offset of TexImage3D format should be 28");
7874 static_assert(offsetof(TexImage3D
, type
) == 32,
7875 "offset of TexImage3D type should be 32");
7876 static_assert(offsetof(TexImage3D
, pixels_shm_id
) == 36,
7877 "offset of TexImage3D pixels_shm_id should be 36");
7878 static_assert(offsetof(TexImage3D
, pixels_shm_offset
) == 40,
7879 "offset of TexImage3D pixels_shm_offset should be 40");
7881 struct TexParameterf
{
7882 typedef TexParameterf ValueType
;
7883 static const CommandId kCmdId
= kTexParameterf
;
7884 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7885 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7887 static uint32_t ComputeSize() {
7888 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7891 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7893 void Init(GLenum _target
, GLenum _pname
, GLfloat _param
) {
7900 void* Set(void* cmd
, GLenum _target
, GLenum _pname
, GLfloat _param
) {
7901 static_cast<ValueType
*>(cmd
)->Init(_target
, _pname
, _param
);
7902 return NextCmdAddress
<ValueType
>(cmd
);
7905 gpu::CommandHeader header
;
7911 static_assert(sizeof(TexParameterf
) == 16,
7912 "size of TexParameterf should be 16");
7913 static_assert(offsetof(TexParameterf
, header
) == 0,
7914 "offset of TexParameterf header should be 0");
7915 static_assert(offsetof(TexParameterf
, target
) == 4,
7916 "offset of TexParameterf target should be 4");
7917 static_assert(offsetof(TexParameterf
, pname
) == 8,
7918 "offset of TexParameterf pname should be 8");
7919 static_assert(offsetof(TexParameterf
, param
) == 12,
7920 "offset of TexParameterf param should be 12");
7922 struct TexParameterfvImmediate
{
7923 typedef TexParameterfvImmediate ValueType
;
7924 static const CommandId kCmdId
= kTexParameterfvImmediate
;
7925 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
7926 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7928 static uint32_t ComputeDataSize() {
7929 return static_cast<uint32_t>(sizeof(GLfloat
) * 1);
7932 static uint32_t ComputeSize() {
7933 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
7936 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
7938 void Init(GLenum _target
, GLenum _pname
, const GLfloat
* _params
) {
7942 memcpy(ImmediateDataAddress(this), _params
, ComputeDataSize());
7945 void* Set(void* cmd
, GLenum _target
, GLenum _pname
, const GLfloat
* _params
) {
7946 static_cast<ValueType
*>(cmd
)->Init(_target
, _pname
, _params
);
7947 const uint32_t size
= ComputeSize();
7948 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
7951 gpu::CommandHeader header
;
7956 static_assert(sizeof(TexParameterfvImmediate
) == 12,
7957 "size of TexParameterfvImmediate should be 12");
7958 static_assert(offsetof(TexParameterfvImmediate
, header
) == 0,
7959 "offset of TexParameterfvImmediate header should be 0");
7960 static_assert(offsetof(TexParameterfvImmediate
, target
) == 4,
7961 "offset of TexParameterfvImmediate target should be 4");
7962 static_assert(offsetof(TexParameterfvImmediate
, pname
) == 8,
7963 "offset of TexParameterfvImmediate pname should be 8");
7965 struct TexParameteri
{
7966 typedef TexParameteri ValueType
;
7967 static const CommandId kCmdId
= kTexParameteri
;
7968 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
7969 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
7971 static uint32_t ComputeSize() {
7972 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
7975 void SetHeader() { header
.SetCmd
<ValueType
>(); }
7977 void Init(GLenum _target
, GLenum _pname
, GLint _param
) {
7984 void* Set(void* cmd
, GLenum _target
, GLenum _pname
, GLint _param
) {
7985 static_cast<ValueType
*>(cmd
)->Init(_target
, _pname
, _param
);
7986 return NextCmdAddress
<ValueType
>(cmd
);
7989 gpu::CommandHeader header
;
7995 static_assert(sizeof(TexParameteri
) == 16,
7996 "size of TexParameteri should be 16");
7997 static_assert(offsetof(TexParameteri
, header
) == 0,
7998 "offset of TexParameteri header should be 0");
7999 static_assert(offsetof(TexParameteri
, target
) == 4,
8000 "offset of TexParameteri target should be 4");
8001 static_assert(offsetof(TexParameteri
, pname
) == 8,
8002 "offset of TexParameteri pname should be 8");
8003 static_assert(offsetof(TexParameteri
, param
) == 12,
8004 "offset of TexParameteri param should be 12");
8006 struct TexParameterivImmediate
{
8007 typedef TexParameterivImmediate ValueType
;
8008 static const CommandId kCmdId
= kTexParameterivImmediate
;
8009 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8010 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8012 static uint32_t ComputeDataSize() {
8013 return static_cast<uint32_t>(sizeof(GLint
) * 1);
8016 static uint32_t ComputeSize() {
8017 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
8020 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
8022 void Init(GLenum _target
, GLenum _pname
, const GLint
* _params
) {
8026 memcpy(ImmediateDataAddress(this), _params
, ComputeDataSize());
8029 void* Set(void* cmd
, GLenum _target
, GLenum _pname
, const GLint
* _params
) {
8030 static_cast<ValueType
*>(cmd
)->Init(_target
, _pname
, _params
);
8031 const uint32_t size
= ComputeSize();
8032 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8035 gpu::CommandHeader header
;
8040 static_assert(sizeof(TexParameterivImmediate
) == 12,
8041 "size of TexParameterivImmediate should be 12");
8042 static_assert(offsetof(TexParameterivImmediate
, header
) == 0,
8043 "offset of TexParameterivImmediate header should be 0");
8044 static_assert(offsetof(TexParameterivImmediate
, target
) == 4,
8045 "offset of TexParameterivImmediate target should be 4");
8046 static_assert(offsetof(TexParameterivImmediate
, pname
) == 8,
8047 "offset of TexParameterivImmediate pname should be 8");
8049 struct TexStorage3D
{
8050 typedef TexStorage3D ValueType
;
8051 static const CommandId kCmdId
= kTexStorage3D
;
8052 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8053 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
8055 static uint32_t ComputeSize() {
8056 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8059 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8061 void Init(GLenum _target
,
8063 GLenum _internalFormat
,
8070 internalFormat
= _internalFormat
;
8076 void* Set(void* cmd
,
8079 GLenum _internalFormat
,
8083 static_cast<ValueType
*>(cmd
)
8084 ->Init(_target
, _levels
, _internalFormat
, _width
, _height
, _depth
);
8085 return NextCmdAddress
<ValueType
>(cmd
);
8088 gpu::CommandHeader header
;
8091 uint32_t internalFormat
;
8097 static_assert(sizeof(TexStorage3D
) == 28, "size of TexStorage3D should be 28");
8098 static_assert(offsetof(TexStorage3D
, header
) == 0,
8099 "offset of TexStorage3D header should be 0");
8100 static_assert(offsetof(TexStorage3D
, target
) == 4,
8101 "offset of TexStorage3D target should be 4");
8102 static_assert(offsetof(TexStorage3D
, levels
) == 8,
8103 "offset of TexStorage3D levels should be 8");
8104 static_assert(offsetof(TexStorage3D
, internalFormat
) == 12,
8105 "offset of TexStorage3D internalFormat should be 12");
8106 static_assert(offsetof(TexStorage3D
, width
) == 16,
8107 "offset of TexStorage3D width should be 16");
8108 static_assert(offsetof(TexStorage3D
, height
) == 20,
8109 "offset of TexStorage3D height should be 20");
8110 static_assert(offsetof(TexStorage3D
, depth
) == 24,
8111 "offset of TexStorage3D depth should be 24");
8113 struct TexSubImage2D
{
8114 typedef TexSubImage2D ValueType
;
8115 static const CommandId kCmdId
= kTexSubImage2D
;
8116 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8117 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
8119 static uint32_t ComputeSize() {
8120 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8123 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8125 void Init(GLenum _target
,
8133 uint32_t _pixels_shm_id
,
8134 uint32_t _pixels_shm_offset
,
8135 GLboolean _internal
) {
8145 pixels_shm_id
= _pixels_shm_id
;
8146 pixels_shm_offset
= _pixels_shm_offset
;
8147 internal
= _internal
;
8150 void* Set(void* cmd
,
8159 uint32_t _pixels_shm_id
,
8160 uint32_t _pixels_shm_offset
,
8161 GLboolean _internal
) {
8162 static_cast<ValueType
*>(cmd
)
8163 ->Init(_target
, _level
, _xoffset
, _yoffset
, _width
, _height
, _format
,
8164 _type
, _pixels_shm_id
, _pixels_shm_offset
, _internal
);
8165 return NextCmdAddress
<ValueType
>(cmd
);
8168 gpu::CommandHeader header
;
8177 uint32_t pixels_shm_id
;
8178 uint32_t pixels_shm_offset
;
8182 static_assert(sizeof(TexSubImage2D
) == 48,
8183 "size of TexSubImage2D should be 48");
8184 static_assert(offsetof(TexSubImage2D
, header
) == 0,
8185 "offset of TexSubImage2D header should be 0");
8186 static_assert(offsetof(TexSubImage2D
, target
) == 4,
8187 "offset of TexSubImage2D target should be 4");
8188 static_assert(offsetof(TexSubImage2D
, level
) == 8,
8189 "offset of TexSubImage2D level should be 8");
8190 static_assert(offsetof(TexSubImage2D
, xoffset
) == 12,
8191 "offset of TexSubImage2D xoffset should be 12");
8192 static_assert(offsetof(TexSubImage2D
, yoffset
) == 16,
8193 "offset of TexSubImage2D yoffset should be 16");
8194 static_assert(offsetof(TexSubImage2D
, width
) == 20,
8195 "offset of TexSubImage2D width should be 20");
8196 static_assert(offsetof(TexSubImage2D
, height
) == 24,
8197 "offset of TexSubImage2D height should be 24");
8198 static_assert(offsetof(TexSubImage2D
, format
) == 28,
8199 "offset of TexSubImage2D format should be 28");
8200 static_assert(offsetof(TexSubImage2D
, type
) == 32,
8201 "offset of TexSubImage2D type should be 32");
8202 static_assert(offsetof(TexSubImage2D
, pixels_shm_id
) == 36,
8203 "offset of TexSubImage2D pixels_shm_id should be 36");
8204 static_assert(offsetof(TexSubImage2D
, pixels_shm_offset
) == 40,
8205 "offset of TexSubImage2D pixels_shm_offset should be 40");
8206 static_assert(offsetof(TexSubImage2D
, internal
) == 44,
8207 "offset of TexSubImage2D internal should be 44");
8209 struct TexSubImage3D
{
8210 typedef TexSubImage3D ValueType
;
8211 static const CommandId kCmdId
= kTexSubImage3D
;
8212 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8213 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
8215 static uint32_t ComputeSize() {
8216 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8219 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8221 void Init(GLenum _target
,
8231 uint32_t _pixels_shm_id
,
8232 uint32_t _pixels_shm_offset
,
8233 GLboolean _internal
) {
8245 pixels_shm_id
= _pixels_shm_id
;
8246 pixels_shm_offset
= _pixels_shm_offset
;
8247 internal
= _internal
;
8250 void* Set(void* cmd
,
8261 uint32_t _pixels_shm_id
,
8262 uint32_t _pixels_shm_offset
,
8263 GLboolean _internal
) {
8264 static_cast<ValueType
*>(cmd
)->Init(
8265 _target
, _level
, _xoffset
, _yoffset
, _zoffset
, _width
, _height
, _depth
,
8266 _format
, _type
, _pixels_shm_id
, _pixels_shm_offset
, _internal
);
8267 return NextCmdAddress
<ValueType
>(cmd
);
8270 gpu::CommandHeader header
;
8281 uint32_t pixels_shm_id
;
8282 uint32_t pixels_shm_offset
;
8286 static_assert(sizeof(TexSubImage3D
) == 56,
8287 "size of TexSubImage3D should be 56");
8288 static_assert(offsetof(TexSubImage3D
, header
) == 0,
8289 "offset of TexSubImage3D header should be 0");
8290 static_assert(offsetof(TexSubImage3D
, target
) == 4,
8291 "offset of TexSubImage3D target should be 4");
8292 static_assert(offsetof(TexSubImage3D
, level
) == 8,
8293 "offset of TexSubImage3D level should be 8");
8294 static_assert(offsetof(TexSubImage3D
, xoffset
) == 12,
8295 "offset of TexSubImage3D xoffset should be 12");
8296 static_assert(offsetof(TexSubImage3D
, yoffset
) == 16,
8297 "offset of TexSubImage3D yoffset should be 16");
8298 static_assert(offsetof(TexSubImage3D
, zoffset
) == 20,
8299 "offset of TexSubImage3D zoffset should be 20");
8300 static_assert(offsetof(TexSubImage3D
, width
) == 24,
8301 "offset of TexSubImage3D width should be 24");
8302 static_assert(offsetof(TexSubImage3D
, height
) == 28,
8303 "offset of TexSubImage3D height should be 28");
8304 static_assert(offsetof(TexSubImage3D
, depth
) == 32,
8305 "offset of TexSubImage3D depth should be 32");
8306 static_assert(offsetof(TexSubImage3D
, format
) == 36,
8307 "offset of TexSubImage3D format should be 36");
8308 static_assert(offsetof(TexSubImage3D
, type
) == 40,
8309 "offset of TexSubImage3D type should be 40");
8310 static_assert(offsetof(TexSubImage3D
, pixels_shm_id
) == 44,
8311 "offset of TexSubImage3D pixels_shm_id should be 44");
8312 static_assert(offsetof(TexSubImage3D
, pixels_shm_offset
) == 48,
8313 "offset of TexSubImage3D pixels_shm_offset should be 48");
8314 static_assert(offsetof(TexSubImage3D
, internal
) == 52,
8315 "offset of TexSubImage3D internal should be 52");
8317 struct TransformFeedbackVaryingsBucket
{
8318 typedef TransformFeedbackVaryingsBucket ValueType
;
8319 static const CommandId kCmdId
= kTransformFeedbackVaryingsBucket
;
8320 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8321 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8323 static uint32_t ComputeSize() {
8324 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8327 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8329 void Init(GLuint _program
, uint32_t _varyings_bucket_id
, GLenum _buffermode
) {
8332 varyings_bucket_id
= _varyings_bucket_id
;
8333 buffermode
= _buffermode
;
8336 void* Set(void* cmd
,
8338 uint32_t _varyings_bucket_id
,
8339 GLenum _buffermode
) {
8340 static_cast<ValueType
*>(cmd
)
8341 ->Init(_program
, _varyings_bucket_id
, _buffermode
);
8342 return NextCmdAddress
<ValueType
>(cmd
);
8345 gpu::CommandHeader header
;
8347 uint32_t varyings_bucket_id
;
8348 uint32_t buffermode
;
8351 static_assert(sizeof(TransformFeedbackVaryingsBucket
) == 16,
8352 "size of TransformFeedbackVaryingsBucket should be 16");
8353 static_assert(offsetof(TransformFeedbackVaryingsBucket
, header
) == 0,
8354 "offset of TransformFeedbackVaryingsBucket header should be 0");
8355 static_assert(offsetof(TransformFeedbackVaryingsBucket
, program
) == 4,
8356 "offset of TransformFeedbackVaryingsBucket program should be 4");
8358 offsetof(TransformFeedbackVaryingsBucket
, varyings_bucket_id
) == 8,
8359 "offset of TransformFeedbackVaryingsBucket varyings_bucket_id should be 8");
8361 offsetof(TransformFeedbackVaryingsBucket
, buffermode
) == 12,
8362 "offset of TransformFeedbackVaryingsBucket buffermode should be 12");
8365 typedef Uniform1f ValueType
;
8366 static const CommandId kCmdId
= kUniform1f
;
8367 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8368 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8370 static uint32_t ComputeSize() {
8371 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8374 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8376 void Init(GLint _location
, GLfloat _x
) {
8378 location
= _location
;
8382 void* Set(void* cmd
, GLint _location
, GLfloat _x
) {
8383 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
);
8384 return NextCmdAddress
<ValueType
>(cmd
);
8387 gpu::CommandHeader header
;
8392 static_assert(sizeof(Uniform1f
) == 12, "size of Uniform1f should be 12");
8393 static_assert(offsetof(Uniform1f
, header
) == 0,
8394 "offset of Uniform1f header should be 0");
8395 static_assert(offsetof(Uniform1f
, location
) == 4,
8396 "offset of Uniform1f location should be 4");
8397 static_assert(offsetof(Uniform1f
, x
) == 8, "offset of Uniform1f x should be 8");
8399 struct Uniform1fvImmediate
{
8400 typedef Uniform1fvImmediate ValueType
;
8401 static const CommandId kCmdId
= kUniform1fvImmediate
;
8402 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8403 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8405 static uint32_t ComputeDataSize(GLsizei count
) {
8406 return static_cast<uint32_t>(sizeof(GLfloat
) * 1 * count
); // NOLINT
8409 static uint32_t ComputeSize(GLsizei count
) {
8410 return static_cast<uint32_t>(sizeof(ValueType
) +
8411 ComputeDataSize(count
)); // NOLINT
8414 void SetHeader(GLsizei count
) {
8415 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8418 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8420 location
= _location
;
8422 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8425 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8426 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8427 const uint32_t size
= ComputeSize(_count
);
8428 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8431 gpu::CommandHeader header
;
8436 static_assert(sizeof(Uniform1fvImmediate
) == 12,
8437 "size of Uniform1fvImmediate should be 12");
8438 static_assert(offsetof(Uniform1fvImmediate
, header
) == 0,
8439 "offset of Uniform1fvImmediate header should be 0");
8440 static_assert(offsetof(Uniform1fvImmediate
, location
) == 4,
8441 "offset of Uniform1fvImmediate location should be 4");
8442 static_assert(offsetof(Uniform1fvImmediate
, count
) == 8,
8443 "offset of Uniform1fvImmediate count should be 8");
8446 typedef Uniform1i ValueType
;
8447 static const CommandId kCmdId
= kUniform1i
;
8448 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8449 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8451 static uint32_t ComputeSize() {
8452 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8455 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8457 void Init(GLint _location
, GLint _x
) {
8459 location
= _location
;
8463 void* Set(void* cmd
, GLint _location
, GLint _x
) {
8464 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
);
8465 return NextCmdAddress
<ValueType
>(cmd
);
8468 gpu::CommandHeader header
;
8473 static_assert(sizeof(Uniform1i
) == 12, "size of Uniform1i should be 12");
8474 static_assert(offsetof(Uniform1i
, header
) == 0,
8475 "offset of Uniform1i header should be 0");
8476 static_assert(offsetof(Uniform1i
, location
) == 4,
8477 "offset of Uniform1i location should be 4");
8478 static_assert(offsetof(Uniform1i
, x
) == 8, "offset of Uniform1i x should be 8");
8480 struct Uniform1ivImmediate
{
8481 typedef Uniform1ivImmediate ValueType
;
8482 static const CommandId kCmdId
= kUniform1ivImmediate
;
8483 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8484 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8486 static uint32_t ComputeDataSize(GLsizei count
) {
8487 return static_cast<uint32_t>(sizeof(GLint
) * 1 * count
); // NOLINT
8490 static uint32_t ComputeSize(GLsizei count
) {
8491 return static_cast<uint32_t>(sizeof(ValueType
) +
8492 ComputeDataSize(count
)); // NOLINT
8495 void SetHeader(GLsizei count
) {
8496 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8499 void Init(GLint _location
, GLsizei _count
, const GLint
* _v
) {
8501 location
= _location
;
8503 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8506 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLint
* _v
) {
8507 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8508 const uint32_t size
= ComputeSize(_count
);
8509 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8512 gpu::CommandHeader header
;
8517 static_assert(sizeof(Uniform1ivImmediate
) == 12,
8518 "size of Uniform1ivImmediate should be 12");
8519 static_assert(offsetof(Uniform1ivImmediate
, header
) == 0,
8520 "offset of Uniform1ivImmediate header should be 0");
8521 static_assert(offsetof(Uniform1ivImmediate
, location
) == 4,
8522 "offset of Uniform1ivImmediate location should be 4");
8523 static_assert(offsetof(Uniform1ivImmediate
, count
) == 8,
8524 "offset of Uniform1ivImmediate count should be 8");
8527 typedef Uniform1ui ValueType
;
8528 static const CommandId kCmdId
= kUniform1ui
;
8529 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8530 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8532 static uint32_t ComputeSize() {
8533 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8536 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8538 void Init(GLint _location
, GLuint _x
) {
8540 location
= _location
;
8544 void* Set(void* cmd
, GLint _location
, GLuint _x
) {
8545 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
);
8546 return NextCmdAddress
<ValueType
>(cmd
);
8549 gpu::CommandHeader header
;
8554 static_assert(sizeof(Uniform1ui
) == 12, "size of Uniform1ui should be 12");
8555 static_assert(offsetof(Uniform1ui
, header
) == 0,
8556 "offset of Uniform1ui header should be 0");
8557 static_assert(offsetof(Uniform1ui
, location
) == 4,
8558 "offset of Uniform1ui location should be 4");
8559 static_assert(offsetof(Uniform1ui
, x
) == 8,
8560 "offset of Uniform1ui x should be 8");
8562 struct Uniform1uivImmediate
{
8563 typedef Uniform1uivImmediate ValueType
;
8564 static const CommandId kCmdId
= kUniform1uivImmediate
;
8565 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8566 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8568 static uint32_t ComputeDataSize(GLsizei count
) {
8569 return static_cast<uint32_t>(sizeof(GLuint
) * 1 * count
); // NOLINT
8572 static uint32_t ComputeSize(GLsizei count
) {
8573 return static_cast<uint32_t>(sizeof(ValueType
) +
8574 ComputeDataSize(count
)); // NOLINT
8577 void SetHeader(GLsizei count
) {
8578 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8581 void Init(GLint _location
, GLsizei _count
, const GLuint
* _v
) {
8583 location
= _location
;
8585 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8588 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLuint
* _v
) {
8589 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8590 const uint32_t size
= ComputeSize(_count
);
8591 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8594 gpu::CommandHeader header
;
8599 static_assert(sizeof(Uniform1uivImmediate
) == 12,
8600 "size of Uniform1uivImmediate should be 12");
8601 static_assert(offsetof(Uniform1uivImmediate
, header
) == 0,
8602 "offset of Uniform1uivImmediate header should be 0");
8603 static_assert(offsetof(Uniform1uivImmediate
, location
) == 4,
8604 "offset of Uniform1uivImmediate location should be 4");
8605 static_assert(offsetof(Uniform1uivImmediate
, count
) == 8,
8606 "offset of Uniform1uivImmediate count should be 8");
8609 typedef Uniform2f ValueType
;
8610 static const CommandId kCmdId
= kUniform2f
;
8611 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8612 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8614 static uint32_t ComputeSize() {
8615 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8618 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8620 void Init(GLint _location
, GLfloat _x
, GLfloat _y
) {
8622 location
= _location
;
8627 void* Set(void* cmd
, GLint _location
, GLfloat _x
, GLfloat _y
) {
8628 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
);
8629 return NextCmdAddress
<ValueType
>(cmd
);
8632 gpu::CommandHeader header
;
8638 static_assert(sizeof(Uniform2f
) == 16, "size of Uniform2f should be 16");
8639 static_assert(offsetof(Uniform2f
, header
) == 0,
8640 "offset of Uniform2f header should be 0");
8641 static_assert(offsetof(Uniform2f
, location
) == 4,
8642 "offset of Uniform2f location should be 4");
8643 static_assert(offsetof(Uniform2f
, x
) == 8, "offset of Uniform2f x should be 8");
8644 static_assert(offsetof(Uniform2f
, y
) == 12,
8645 "offset of Uniform2f y should be 12");
8647 struct Uniform2fvImmediate
{
8648 typedef Uniform2fvImmediate ValueType
;
8649 static const CommandId kCmdId
= kUniform2fvImmediate
;
8650 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8651 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8653 static uint32_t ComputeDataSize(GLsizei count
) {
8654 return static_cast<uint32_t>(sizeof(GLfloat
) * 2 * count
); // NOLINT
8657 static uint32_t ComputeSize(GLsizei count
) {
8658 return static_cast<uint32_t>(sizeof(ValueType
) +
8659 ComputeDataSize(count
)); // NOLINT
8662 void SetHeader(GLsizei count
) {
8663 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8666 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8668 location
= _location
;
8670 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8673 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8674 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8675 const uint32_t size
= ComputeSize(_count
);
8676 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8679 gpu::CommandHeader header
;
8684 static_assert(sizeof(Uniform2fvImmediate
) == 12,
8685 "size of Uniform2fvImmediate should be 12");
8686 static_assert(offsetof(Uniform2fvImmediate
, header
) == 0,
8687 "offset of Uniform2fvImmediate header should be 0");
8688 static_assert(offsetof(Uniform2fvImmediate
, location
) == 4,
8689 "offset of Uniform2fvImmediate location should be 4");
8690 static_assert(offsetof(Uniform2fvImmediate
, count
) == 8,
8691 "offset of Uniform2fvImmediate count should be 8");
8694 typedef Uniform2i ValueType
;
8695 static const CommandId kCmdId
= kUniform2i
;
8696 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8697 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8699 static uint32_t ComputeSize() {
8700 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8703 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8705 void Init(GLint _location
, GLint _x
, GLint _y
) {
8707 location
= _location
;
8712 void* Set(void* cmd
, GLint _location
, GLint _x
, GLint _y
) {
8713 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
);
8714 return NextCmdAddress
<ValueType
>(cmd
);
8717 gpu::CommandHeader header
;
8723 static_assert(sizeof(Uniform2i
) == 16, "size of Uniform2i should be 16");
8724 static_assert(offsetof(Uniform2i
, header
) == 0,
8725 "offset of Uniform2i header should be 0");
8726 static_assert(offsetof(Uniform2i
, location
) == 4,
8727 "offset of Uniform2i location should be 4");
8728 static_assert(offsetof(Uniform2i
, x
) == 8, "offset of Uniform2i x should be 8");
8729 static_assert(offsetof(Uniform2i
, y
) == 12,
8730 "offset of Uniform2i y should be 12");
8732 struct Uniform2ivImmediate
{
8733 typedef Uniform2ivImmediate ValueType
;
8734 static const CommandId kCmdId
= kUniform2ivImmediate
;
8735 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8736 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8738 static uint32_t ComputeDataSize(GLsizei count
) {
8739 return static_cast<uint32_t>(sizeof(GLint
) * 2 * count
); // NOLINT
8742 static uint32_t ComputeSize(GLsizei count
) {
8743 return static_cast<uint32_t>(sizeof(ValueType
) +
8744 ComputeDataSize(count
)); // NOLINT
8747 void SetHeader(GLsizei count
) {
8748 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8751 void Init(GLint _location
, GLsizei _count
, const GLint
* _v
) {
8753 location
= _location
;
8755 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8758 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLint
* _v
) {
8759 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8760 const uint32_t size
= ComputeSize(_count
);
8761 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8764 gpu::CommandHeader header
;
8769 static_assert(sizeof(Uniform2ivImmediate
) == 12,
8770 "size of Uniform2ivImmediate should be 12");
8771 static_assert(offsetof(Uniform2ivImmediate
, header
) == 0,
8772 "offset of Uniform2ivImmediate header should be 0");
8773 static_assert(offsetof(Uniform2ivImmediate
, location
) == 4,
8774 "offset of Uniform2ivImmediate location should be 4");
8775 static_assert(offsetof(Uniform2ivImmediate
, count
) == 8,
8776 "offset of Uniform2ivImmediate count should be 8");
8779 typedef Uniform2ui ValueType
;
8780 static const CommandId kCmdId
= kUniform2ui
;
8781 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8782 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8784 static uint32_t ComputeSize() {
8785 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8788 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8790 void Init(GLint _location
, GLuint _x
, GLuint _y
) {
8792 location
= _location
;
8797 void* Set(void* cmd
, GLint _location
, GLuint _x
, GLuint _y
) {
8798 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
);
8799 return NextCmdAddress
<ValueType
>(cmd
);
8802 gpu::CommandHeader header
;
8808 static_assert(sizeof(Uniform2ui
) == 16, "size of Uniform2ui should be 16");
8809 static_assert(offsetof(Uniform2ui
, header
) == 0,
8810 "offset of Uniform2ui header should be 0");
8811 static_assert(offsetof(Uniform2ui
, location
) == 4,
8812 "offset of Uniform2ui location should be 4");
8813 static_assert(offsetof(Uniform2ui
, x
) == 8,
8814 "offset of Uniform2ui x should be 8");
8815 static_assert(offsetof(Uniform2ui
, y
) == 12,
8816 "offset of Uniform2ui y should be 12");
8818 struct Uniform2uivImmediate
{
8819 typedef Uniform2uivImmediate ValueType
;
8820 static const CommandId kCmdId
= kUniform2uivImmediate
;
8821 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8822 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8824 static uint32_t ComputeDataSize(GLsizei count
) {
8825 return static_cast<uint32_t>(sizeof(GLuint
) * 2 * count
); // NOLINT
8828 static uint32_t ComputeSize(GLsizei count
) {
8829 return static_cast<uint32_t>(sizeof(ValueType
) +
8830 ComputeDataSize(count
)); // NOLINT
8833 void SetHeader(GLsizei count
) {
8834 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8837 void Init(GLint _location
, GLsizei _count
, const GLuint
* _v
) {
8839 location
= _location
;
8841 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8844 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLuint
* _v
) {
8845 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8846 const uint32_t size
= ComputeSize(_count
);
8847 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8850 gpu::CommandHeader header
;
8855 static_assert(sizeof(Uniform2uivImmediate
) == 12,
8856 "size of Uniform2uivImmediate should be 12");
8857 static_assert(offsetof(Uniform2uivImmediate
, header
) == 0,
8858 "offset of Uniform2uivImmediate header should be 0");
8859 static_assert(offsetof(Uniform2uivImmediate
, location
) == 4,
8860 "offset of Uniform2uivImmediate location should be 4");
8861 static_assert(offsetof(Uniform2uivImmediate
, count
) == 8,
8862 "offset of Uniform2uivImmediate count should be 8");
8865 typedef Uniform3f ValueType
;
8866 static const CommandId kCmdId
= kUniform3f
;
8867 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8868 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8870 static uint32_t ComputeSize() {
8871 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8874 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8876 void Init(GLint _location
, GLfloat _x
, GLfloat _y
, GLfloat _z
) {
8878 location
= _location
;
8884 void* Set(void* cmd
, GLint _location
, GLfloat _x
, GLfloat _y
, GLfloat _z
) {
8885 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
);
8886 return NextCmdAddress
<ValueType
>(cmd
);
8889 gpu::CommandHeader header
;
8896 static_assert(sizeof(Uniform3f
) == 20, "size of Uniform3f should be 20");
8897 static_assert(offsetof(Uniform3f
, header
) == 0,
8898 "offset of Uniform3f header should be 0");
8899 static_assert(offsetof(Uniform3f
, location
) == 4,
8900 "offset of Uniform3f location should be 4");
8901 static_assert(offsetof(Uniform3f
, x
) == 8, "offset of Uniform3f x should be 8");
8902 static_assert(offsetof(Uniform3f
, y
) == 12,
8903 "offset of Uniform3f y should be 12");
8904 static_assert(offsetof(Uniform3f
, z
) == 16,
8905 "offset of Uniform3f z should be 16");
8907 struct Uniform3fvImmediate
{
8908 typedef Uniform3fvImmediate ValueType
;
8909 static const CommandId kCmdId
= kUniform3fvImmediate
;
8910 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
8911 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8913 static uint32_t ComputeDataSize(GLsizei count
) {
8914 return static_cast<uint32_t>(sizeof(GLfloat
) * 3 * count
); // NOLINT
8917 static uint32_t ComputeSize(GLsizei count
) {
8918 return static_cast<uint32_t>(sizeof(ValueType
) +
8919 ComputeDataSize(count
)); // NOLINT
8922 void SetHeader(GLsizei count
) {
8923 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
8926 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8928 location
= _location
;
8930 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
8933 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
8934 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
8935 const uint32_t size
= ComputeSize(_count
);
8936 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
8939 gpu::CommandHeader header
;
8944 static_assert(sizeof(Uniform3fvImmediate
) == 12,
8945 "size of Uniform3fvImmediate should be 12");
8946 static_assert(offsetof(Uniform3fvImmediate
, header
) == 0,
8947 "offset of Uniform3fvImmediate header should be 0");
8948 static_assert(offsetof(Uniform3fvImmediate
, location
) == 4,
8949 "offset of Uniform3fvImmediate location should be 4");
8950 static_assert(offsetof(Uniform3fvImmediate
, count
) == 8,
8951 "offset of Uniform3fvImmediate count should be 8");
8954 typedef Uniform3i ValueType
;
8955 static const CommandId kCmdId
= kUniform3i
;
8956 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
8957 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
8959 static uint32_t ComputeSize() {
8960 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
8963 void SetHeader() { header
.SetCmd
<ValueType
>(); }
8965 void Init(GLint _location
, GLint _x
, GLint _y
, GLint _z
) {
8967 location
= _location
;
8973 void* Set(void* cmd
, GLint _location
, GLint _x
, GLint _y
, GLint _z
) {
8974 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
);
8975 return NextCmdAddress
<ValueType
>(cmd
);
8978 gpu::CommandHeader header
;
8985 static_assert(sizeof(Uniform3i
) == 20, "size of Uniform3i should be 20");
8986 static_assert(offsetof(Uniform3i
, header
) == 0,
8987 "offset of Uniform3i header should be 0");
8988 static_assert(offsetof(Uniform3i
, location
) == 4,
8989 "offset of Uniform3i location should be 4");
8990 static_assert(offsetof(Uniform3i
, x
) == 8, "offset of Uniform3i x should be 8");
8991 static_assert(offsetof(Uniform3i
, y
) == 12,
8992 "offset of Uniform3i y should be 12");
8993 static_assert(offsetof(Uniform3i
, z
) == 16,
8994 "offset of Uniform3i z should be 16");
8996 struct Uniform3ivImmediate
{
8997 typedef Uniform3ivImmediate ValueType
;
8998 static const CommandId kCmdId
= kUniform3ivImmediate
;
8999 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9000 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9002 static uint32_t ComputeDataSize(GLsizei count
) {
9003 return static_cast<uint32_t>(sizeof(GLint
) * 3 * count
); // NOLINT
9006 static uint32_t ComputeSize(GLsizei count
) {
9007 return static_cast<uint32_t>(sizeof(ValueType
) +
9008 ComputeDataSize(count
)); // NOLINT
9011 void SetHeader(GLsizei count
) {
9012 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9015 void Init(GLint _location
, GLsizei _count
, const GLint
* _v
) {
9017 location
= _location
;
9019 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
9022 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLint
* _v
) {
9023 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
9024 const uint32_t size
= ComputeSize(_count
);
9025 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9028 gpu::CommandHeader header
;
9033 static_assert(sizeof(Uniform3ivImmediate
) == 12,
9034 "size of Uniform3ivImmediate should be 12");
9035 static_assert(offsetof(Uniform3ivImmediate
, header
) == 0,
9036 "offset of Uniform3ivImmediate header should be 0");
9037 static_assert(offsetof(Uniform3ivImmediate
, location
) == 4,
9038 "offset of Uniform3ivImmediate location should be 4");
9039 static_assert(offsetof(Uniform3ivImmediate
, count
) == 8,
9040 "offset of Uniform3ivImmediate count should be 8");
9043 typedef Uniform3ui ValueType
;
9044 static const CommandId kCmdId
= kUniform3ui
;
9045 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9046 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9048 static uint32_t ComputeSize() {
9049 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9052 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9054 void Init(GLint _location
, GLuint _x
, GLuint _y
, GLuint _z
) {
9056 location
= _location
;
9062 void* Set(void* cmd
, GLint _location
, GLuint _x
, GLuint _y
, GLuint _z
) {
9063 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
);
9064 return NextCmdAddress
<ValueType
>(cmd
);
9067 gpu::CommandHeader header
;
9074 static_assert(sizeof(Uniform3ui
) == 20, "size of Uniform3ui should be 20");
9075 static_assert(offsetof(Uniform3ui
, header
) == 0,
9076 "offset of Uniform3ui header should be 0");
9077 static_assert(offsetof(Uniform3ui
, location
) == 4,
9078 "offset of Uniform3ui location should be 4");
9079 static_assert(offsetof(Uniform3ui
, x
) == 8,
9080 "offset of Uniform3ui x should be 8");
9081 static_assert(offsetof(Uniform3ui
, y
) == 12,
9082 "offset of Uniform3ui y should be 12");
9083 static_assert(offsetof(Uniform3ui
, z
) == 16,
9084 "offset of Uniform3ui z should be 16");
9086 struct Uniform3uivImmediate
{
9087 typedef Uniform3uivImmediate ValueType
;
9088 static const CommandId kCmdId
= kUniform3uivImmediate
;
9089 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9090 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9092 static uint32_t ComputeDataSize(GLsizei count
) {
9093 return static_cast<uint32_t>(sizeof(GLuint
) * 3 * count
); // NOLINT
9096 static uint32_t ComputeSize(GLsizei count
) {
9097 return static_cast<uint32_t>(sizeof(ValueType
) +
9098 ComputeDataSize(count
)); // NOLINT
9101 void SetHeader(GLsizei count
) {
9102 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9105 void Init(GLint _location
, GLsizei _count
, const GLuint
* _v
) {
9107 location
= _location
;
9109 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
9112 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLuint
* _v
) {
9113 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
9114 const uint32_t size
= ComputeSize(_count
);
9115 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9118 gpu::CommandHeader header
;
9123 static_assert(sizeof(Uniform3uivImmediate
) == 12,
9124 "size of Uniform3uivImmediate should be 12");
9125 static_assert(offsetof(Uniform3uivImmediate
, header
) == 0,
9126 "offset of Uniform3uivImmediate header should be 0");
9127 static_assert(offsetof(Uniform3uivImmediate
, location
) == 4,
9128 "offset of Uniform3uivImmediate location should be 4");
9129 static_assert(offsetof(Uniform3uivImmediate
, count
) == 8,
9130 "offset of Uniform3uivImmediate count should be 8");
9133 typedef Uniform4f ValueType
;
9134 static const CommandId kCmdId
= kUniform4f
;
9135 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9136 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9138 static uint32_t ComputeSize() {
9139 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9142 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9144 void Init(GLint _location
, GLfloat _x
, GLfloat _y
, GLfloat _z
, GLfloat _w
) {
9146 location
= _location
;
9153 void* Set(void* cmd
,
9159 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
, _w
);
9160 return NextCmdAddress
<ValueType
>(cmd
);
9163 gpu::CommandHeader header
;
9171 static_assert(sizeof(Uniform4f
) == 24, "size of Uniform4f should be 24");
9172 static_assert(offsetof(Uniform4f
, header
) == 0,
9173 "offset of Uniform4f header should be 0");
9174 static_assert(offsetof(Uniform4f
, location
) == 4,
9175 "offset of Uniform4f location should be 4");
9176 static_assert(offsetof(Uniform4f
, x
) == 8, "offset of Uniform4f x should be 8");
9177 static_assert(offsetof(Uniform4f
, y
) == 12,
9178 "offset of Uniform4f y should be 12");
9179 static_assert(offsetof(Uniform4f
, z
) == 16,
9180 "offset of Uniform4f z should be 16");
9181 static_assert(offsetof(Uniform4f
, w
) == 20,
9182 "offset of Uniform4f w should be 20");
9184 struct Uniform4fvImmediate
{
9185 typedef Uniform4fvImmediate ValueType
;
9186 static const CommandId kCmdId
= kUniform4fvImmediate
;
9187 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9188 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9190 static uint32_t ComputeDataSize(GLsizei count
) {
9191 return static_cast<uint32_t>(sizeof(GLfloat
) * 4 * count
); // NOLINT
9194 static uint32_t ComputeSize(GLsizei count
) {
9195 return static_cast<uint32_t>(sizeof(ValueType
) +
9196 ComputeDataSize(count
)); // NOLINT
9199 void SetHeader(GLsizei count
) {
9200 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9203 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
9205 location
= _location
;
9207 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
9210 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _v
) {
9211 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
9212 const uint32_t size
= ComputeSize(_count
);
9213 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9216 gpu::CommandHeader header
;
9221 static_assert(sizeof(Uniform4fvImmediate
) == 12,
9222 "size of Uniform4fvImmediate should be 12");
9223 static_assert(offsetof(Uniform4fvImmediate
, header
) == 0,
9224 "offset of Uniform4fvImmediate header should be 0");
9225 static_assert(offsetof(Uniform4fvImmediate
, location
) == 4,
9226 "offset of Uniform4fvImmediate location should be 4");
9227 static_assert(offsetof(Uniform4fvImmediate
, count
) == 8,
9228 "offset of Uniform4fvImmediate count should be 8");
9231 typedef Uniform4i ValueType
;
9232 static const CommandId kCmdId
= kUniform4i
;
9233 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9234 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9236 static uint32_t ComputeSize() {
9237 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9240 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9242 void Init(GLint _location
, GLint _x
, GLint _y
, GLint _z
, GLint _w
) {
9244 location
= _location
;
9251 void* Set(void* cmd
,
9257 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
, _w
);
9258 return NextCmdAddress
<ValueType
>(cmd
);
9261 gpu::CommandHeader header
;
9269 static_assert(sizeof(Uniform4i
) == 24, "size of Uniform4i should be 24");
9270 static_assert(offsetof(Uniform4i
, header
) == 0,
9271 "offset of Uniform4i header should be 0");
9272 static_assert(offsetof(Uniform4i
, location
) == 4,
9273 "offset of Uniform4i location should be 4");
9274 static_assert(offsetof(Uniform4i
, x
) == 8, "offset of Uniform4i x should be 8");
9275 static_assert(offsetof(Uniform4i
, y
) == 12,
9276 "offset of Uniform4i y should be 12");
9277 static_assert(offsetof(Uniform4i
, z
) == 16,
9278 "offset of Uniform4i z should be 16");
9279 static_assert(offsetof(Uniform4i
, w
) == 20,
9280 "offset of Uniform4i w should be 20");
9282 struct Uniform4ivImmediate
{
9283 typedef Uniform4ivImmediate ValueType
;
9284 static const CommandId kCmdId
= kUniform4ivImmediate
;
9285 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9286 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9288 static uint32_t ComputeDataSize(GLsizei count
) {
9289 return static_cast<uint32_t>(sizeof(GLint
) * 4 * count
); // NOLINT
9292 static uint32_t ComputeSize(GLsizei count
) {
9293 return static_cast<uint32_t>(sizeof(ValueType
) +
9294 ComputeDataSize(count
)); // NOLINT
9297 void SetHeader(GLsizei count
) {
9298 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9301 void Init(GLint _location
, GLsizei _count
, const GLint
* _v
) {
9303 location
= _location
;
9305 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
9308 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLint
* _v
) {
9309 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
9310 const uint32_t size
= ComputeSize(_count
);
9311 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9314 gpu::CommandHeader header
;
9319 static_assert(sizeof(Uniform4ivImmediate
) == 12,
9320 "size of Uniform4ivImmediate should be 12");
9321 static_assert(offsetof(Uniform4ivImmediate
, header
) == 0,
9322 "offset of Uniform4ivImmediate header should be 0");
9323 static_assert(offsetof(Uniform4ivImmediate
, location
) == 4,
9324 "offset of Uniform4ivImmediate location should be 4");
9325 static_assert(offsetof(Uniform4ivImmediate
, count
) == 8,
9326 "offset of Uniform4ivImmediate count should be 8");
9329 typedef Uniform4ui ValueType
;
9330 static const CommandId kCmdId
= kUniform4ui
;
9331 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9332 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9334 static uint32_t ComputeSize() {
9335 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9338 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9340 void Init(GLint _location
, GLuint _x
, GLuint _y
, GLuint _z
, GLuint _w
) {
9342 location
= _location
;
9349 void* Set(void* cmd
,
9355 static_cast<ValueType
*>(cmd
)->Init(_location
, _x
, _y
, _z
, _w
);
9356 return NextCmdAddress
<ValueType
>(cmd
);
9359 gpu::CommandHeader header
;
9367 static_assert(sizeof(Uniform4ui
) == 24, "size of Uniform4ui should be 24");
9368 static_assert(offsetof(Uniform4ui
, header
) == 0,
9369 "offset of Uniform4ui header should be 0");
9370 static_assert(offsetof(Uniform4ui
, location
) == 4,
9371 "offset of Uniform4ui location should be 4");
9372 static_assert(offsetof(Uniform4ui
, x
) == 8,
9373 "offset of Uniform4ui x should be 8");
9374 static_assert(offsetof(Uniform4ui
, y
) == 12,
9375 "offset of Uniform4ui y should be 12");
9376 static_assert(offsetof(Uniform4ui
, z
) == 16,
9377 "offset of Uniform4ui z should be 16");
9378 static_assert(offsetof(Uniform4ui
, w
) == 20,
9379 "offset of Uniform4ui w should be 20");
9381 struct Uniform4uivImmediate
{
9382 typedef Uniform4uivImmediate ValueType
;
9383 static const CommandId kCmdId
= kUniform4uivImmediate
;
9384 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9385 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9387 static uint32_t ComputeDataSize(GLsizei count
) {
9388 return static_cast<uint32_t>(sizeof(GLuint
) * 4 * count
); // NOLINT
9391 static uint32_t ComputeSize(GLsizei count
) {
9392 return static_cast<uint32_t>(sizeof(ValueType
) +
9393 ComputeDataSize(count
)); // NOLINT
9396 void SetHeader(GLsizei count
) {
9397 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9400 void Init(GLint _location
, GLsizei _count
, const GLuint
* _v
) {
9402 location
= _location
;
9404 memcpy(ImmediateDataAddress(this), _v
, ComputeDataSize(_count
));
9407 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLuint
* _v
) {
9408 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _v
);
9409 const uint32_t size
= ComputeSize(_count
);
9410 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9413 gpu::CommandHeader header
;
9418 static_assert(sizeof(Uniform4uivImmediate
) == 12,
9419 "size of Uniform4uivImmediate should be 12");
9420 static_assert(offsetof(Uniform4uivImmediate
, header
) == 0,
9421 "offset of Uniform4uivImmediate header should be 0");
9422 static_assert(offsetof(Uniform4uivImmediate
, location
) == 4,
9423 "offset of Uniform4uivImmediate location should be 4");
9424 static_assert(offsetof(Uniform4uivImmediate
, count
) == 8,
9425 "offset of Uniform4uivImmediate count should be 8");
9427 struct UniformBlockBinding
{
9428 typedef UniformBlockBinding ValueType
;
9429 static const CommandId kCmdId
= kUniformBlockBinding
;
9430 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9431 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9433 static uint32_t ComputeSize() {
9434 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9437 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9439 void Init(GLuint _program
, GLuint _index
, GLuint _binding
) {
9446 void* Set(void* cmd
, GLuint _program
, GLuint _index
, GLuint _binding
) {
9447 static_cast<ValueType
*>(cmd
)->Init(_program
, _index
, _binding
);
9448 return NextCmdAddress
<ValueType
>(cmd
);
9451 gpu::CommandHeader header
;
9457 static_assert(sizeof(UniformBlockBinding
) == 16,
9458 "size of UniformBlockBinding should be 16");
9459 static_assert(offsetof(UniformBlockBinding
, header
) == 0,
9460 "offset of UniformBlockBinding header should be 0");
9461 static_assert(offsetof(UniformBlockBinding
, program
) == 4,
9462 "offset of UniformBlockBinding program should be 4");
9463 static_assert(offsetof(UniformBlockBinding
, index
) == 8,
9464 "offset of UniformBlockBinding index should be 8");
9465 static_assert(offsetof(UniformBlockBinding
, binding
) == 12,
9466 "offset of UniformBlockBinding binding should be 12");
9468 struct UniformMatrix2fvImmediate
{
9469 typedef UniformMatrix2fvImmediate ValueType
;
9470 static const CommandId kCmdId
= kUniformMatrix2fvImmediate
;
9471 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9472 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9474 static uint32_t ComputeDataSize(GLsizei count
) {
9475 return static_cast<uint32_t>(sizeof(GLfloat
) * 4 * count
); // NOLINT
9478 static uint32_t ComputeSize(GLsizei count
) {
9479 return static_cast<uint32_t>(sizeof(ValueType
) +
9480 ComputeDataSize(count
)); // NOLINT
9483 void SetHeader(GLsizei count
) {
9484 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9487 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9489 location
= _location
;
9491 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9494 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9495 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9496 const uint32_t size
= ComputeSize(_count
);
9497 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9500 gpu::CommandHeader header
;
9503 static const uint32_t transpose
= false;
9506 static_assert(sizeof(UniformMatrix2fvImmediate
) == 12,
9507 "size of UniformMatrix2fvImmediate should be 12");
9508 static_assert(offsetof(UniformMatrix2fvImmediate
, header
) == 0,
9509 "offset of UniformMatrix2fvImmediate header should be 0");
9510 static_assert(offsetof(UniformMatrix2fvImmediate
, location
) == 4,
9511 "offset of UniformMatrix2fvImmediate location should be 4");
9512 static_assert(offsetof(UniformMatrix2fvImmediate
, count
) == 8,
9513 "offset of UniformMatrix2fvImmediate count should be 8");
9515 struct UniformMatrix2x3fvImmediate
{
9516 typedef UniformMatrix2x3fvImmediate ValueType
;
9517 static const CommandId kCmdId
= kUniformMatrix2x3fvImmediate
;
9518 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9519 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9521 static uint32_t ComputeDataSize(GLsizei count
) {
9522 return static_cast<uint32_t>(sizeof(GLfloat
) * 6 * count
); // NOLINT
9525 static uint32_t ComputeSize(GLsizei count
) {
9526 return static_cast<uint32_t>(sizeof(ValueType
) +
9527 ComputeDataSize(count
)); // NOLINT
9530 void SetHeader(GLsizei count
) {
9531 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9534 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9536 location
= _location
;
9538 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9541 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9542 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9543 const uint32_t size
= ComputeSize(_count
);
9544 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9547 gpu::CommandHeader header
;
9550 static const uint32_t transpose
= false;
9553 static_assert(sizeof(UniformMatrix2x3fvImmediate
) == 12,
9554 "size of UniformMatrix2x3fvImmediate should be 12");
9555 static_assert(offsetof(UniformMatrix2x3fvImmediate
, header
) == 0,
9556 "offset of UniformMatrix2x3fvImmediate header should be 0");
9557 static_assert(offsetof(UniformMatrix2x3fvImmediate
, location
) == 4,
9558 "offset of UniformMatrix2x3fvImmediate location should be 4");
9559 static_assert(offsetof(UniformMatrix2x3fvImmediate
, count
) == 8,
9560 "offset of UniformMatrix2x3fvImmediate count should be 8");
9562 struct UniformMatrix2x4fvImmediate
{
9563 typedef UniformMatrix2x4fvImmediate ValueType
;
9564 static const CommandId kCmdId
= kUniformMatrix2x4fvImmediate
;
9565 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9566 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9568 static uint32_t ComputeDataSize(GLsizei count
) {
9569 return static_cast<uint32_t>(sizeof(GLfloat
) * 8 * count
); // NOLINT
9572 static uint32_t ComputeSize(GLsizei count
) {
9573 return static_cast<uint32_t>(sizeof(ValueType
) +
9574 ComputeDataSize(count
)); // NOLINT
9577 void SetHeader(GLsizei count
) {
9578 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9581 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9583 location
= _location
;
9585 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9588 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9589 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9590 const uint32_t size
= ComputeSize(_count
);
9591 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9594 gpu::CommandHeader header
;
9597 static const uint32_t transpose
= false;
9600 static_assert(sizeof(UniformMatrix2x4fvImmediate
) == 12,
9601 "size of UniformMatrix2x4fvImmediate should be 12");
9602 static_assert(offsetof(UniformMatrix2x4fvImmediate
, header
) == 0,
9603 "offset of UniformMatrix2x4fvImmediate header should be 0");
9604 static_assert(offsetof(UniformMatrix2x4fvImmediate
, location
) == 4,
9605 "offset of UniformMatrix2x4fvImmediate location should be 4");
9606 static_assert(offsetof(UniformMatrix2x4fvImmediate
, count
) == 8,
9607 "offset of UniformMatrix2x4fvImmediate count should be 8");
9609 struct UniformMatrix3fvImmediate
{
9610 typedef UniformMatrix3fvImmediate ValueType
;
9611 static const CommandId kCmdId
= kUniformMatrix3fvImmediate
;
9612 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9613 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9615 static uint32_t ComputeDataSize(GLsizei count
) {
9616 return static_cast<uint32_t>(sizeof(GLfloat
) * 9 * count
); // NOLINT
9619 static uint32_t ComputeSize(GLsizei count
) {
9620 return static_cast<uint32_t>(sizeof(ValueType
) +
9621 ComputeDataSize(count
)); // NOLINT
9624 void SetHeader(GLsizei count
) {
9625 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9628 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9630 location
= _location
;
9632 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9635 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9636 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9637 const uint32_t size
= ComputeSize(_count
);
9638 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9641 gpu::CommandHeader header
;
9644 static const uint32_t transpose
= false;
9647 static_assert(sizeof(UniformMatrix3fvImmediate
) == 12,
9648 "size of UniformMatrix3fvImmediate should be 12");
9649 static_assert(offsetof(UniformMatrix3fvImmediate
, header
) == 0,
9650 "offset of UniformMatrix3fvImmediate header should be 0");
9651 static_assert(offsetof(UniformMatrix3fvImmediate
, location
) == 4,
9652 "offset of UniformMatrix3fvImmediate location should be 4");
9653 static_assert(offsetof(UniformMatrix3fvImmediate
, count
) == 8,
9654 "offset of UniformMatrix3fvImmediate count should be 8");
9656 struct UniformMatrix3x2fvImmediate
{
9657 typedef UniformMatrix3x2fvImmediate ValueType
;
9658 static const CommandId kCmdId
= kUniformMatrix3x2fvImmediate
;
9659 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9660 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9662 static uint32_t ComputeDataSize(GLsizei count
) {
9663 return static_cast<uint32_t>(sizeof(GLfloat
) * 6 * count
); // NOLINT
9666 static uint32_t ComputeSize(GLsizei count
) {
9667 return static_cast<uint32_t>(sizeof(ValueType
) +
9668 ComputeDataSize(count
)); // NOLINT
9671 void SetHeader(GLsizei count
) {
9672 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9675 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9677 location
= _location
;
9679 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9682 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9683 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9684 const uint32_t size
= ComputeSize(_count
);
9685 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9688 gpu::CommandHeader header
;
9691 static const uint32_t transpose
= false;
9694 static_assert(sizeof(UniformMatrix3x2fvImmediate
) == 12,
9695 "size of UniformMatrix3x2fvImmediate should be 12");
9696 static_assert(offsetof(UniformMatrix3x2fvImmediate
, header
) == 0,
9697 "offset of UniformMatrix3x2fvImmediate header should be 0");
9698 static_assert(offsetof(UniformMatrix3x2fvImmediate
, location
) == 4,
9699 "offset of UniformMatrix3x2fvImmediate location should be 4");
9700 static_assert(offsetof(UniformMatrix3x2fvImmediate
, count
) == 8,
9701 "offset of UniformMatrix3x2fvImmediate count should be 8");
9703 struct UniformMatrix3x4fvImmediate
{
9704 typedef UniformMatrix3x4fvImmediate ValueType
;
9705 static const CommandId kCmdId
= kUniformMatrix3x4fvImmediate
;
9706 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9707 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9709 static uint32_t ComputeDataSize(GLsizei count
) {
9710 return static_cast<uint32_t>(sizeof(GLfloat
) * 12 * count
); // NOLINT
9713 static uint32_t ComputeSize(GLsizei count
) {
9714 return static_cast<uint32_t>(sizeof(ValueType
) +
9715 ComputeDataSize(count
)); // NOLINT
9718 void SetHeader(GLsizei count
) {
9719 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9722 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9724 location
= _location
;
9726 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9729 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9730 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9731 const uint32_t size
= ComputeSize(_count
);
9732 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9735 gpu::CommandHeader header
;
9738 static const uint32_t transpose
= false;
9741 static_assert(sizeof(UniformMatrix3x4fvImmediate
) == 12,
9742 "size of UniformMatrix3x4fvImmediate should be 12");
9743 static_assert(offsetof(UniformMatrix3x4fvImmediate
, header
) == 0,
9744 "offset of UniformMatrix3x4fvImmediate header should be 0");
9745 static_assert(offsetof(UniformMatrix3x4fvImmediate
, location
) == 4,
9746 "offset of UniformMatrix3x4fvImmediate location should be 4");
9747 static_assert(offsetof(UniformMatrix3x4fvImmediate
, count
) == 8,
9748 "offset of UniformMatrix3x4fvImmediate count should be 8");
9750 struct UniformMatrix4fvImmediate
{
9751 typedef UniformMatrix4fvImmediate ValueType
;
9752 static const CommandId kCmdId
= kUniformMatrix4fvImmediate
;
9753 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9754 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9756 static uint32_t ComputeDataSize(GLsizei count
) {
9757 return static_cast<uint32_t>(sizeof(GLfloat
) * 16 * count
); // NOLINT
9760 static uint32_t ComputeSize(GLsizei count
) {
9761 return static_cast<uint32_t>(sizeof(ValueType
) +
9762 ComputeDataSize(count
)); // NOLINT
9765 void SetHeader(GLsizei count
) {
9766 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9769 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9771 location
= _location
;
9773 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9776 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9777 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9778 const uint32_t size
= ComputeSize(_count
);
9779 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9782 gpu::CommandHeader header
;
9785 static const uint32_t transpose
= false;
9788 static_assert(sizeof(UniformMatrix4fvImmediate
) == 12,
9789 "size of UniformMatrix4fvImmediate should be 12");
9790 static_assert(offsetof(UniformMatrix4fvImmediate
, header
) == 0,
9791 "offset of UniformMatrix4fvImmediate header should be 0");
9792 static_assert(offsetof(UniformMatrix4fvImmediate
, location
) == 4,
9793 "offset of UniformMatrix4fvImmediate location should be 4");
9794 static_assert(offsetof(UniformMatrix4fvImmediate
, count
) == 8,
9795 "offset of UniformMatrix4fvImmediate count should be 8");
9797 struct UniformMatrix4x2fvImmediate
{
9798 typedef UniformMatrix4x2fvImmediate ValueType
;
9799 static const CommandId kCmdId
= kUniformMatrix4x2fvImmediate
;
9800 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9801 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9803 static uint32_t ComputeDataSize(GLsizei count
) {
9804 return static_cast<uint32_t>(sizeof(GLfloat
) * 8 * count
); // NOLINT
9807 static uint32_t ComputeSize(GLsizei count
) {
9808 return static_cast<uint32_t>(sizeof(ValueType
) +
9809 ComputeDataSize(count
)); // NOLINT
9812 void SetHeader(GLsizei count
) {
9813 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9816 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9818 location
= _location
;
9820 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9823 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9824 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9825 const uint32_t size
= ComputeSize(_count
);
9826 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9829 gpu::CommandHeader header
;
9832 static const uint32_t transpose
= false;
9835 static_assert(sizeof(UniformMatrix4x2fvImmediate
) == 12,
9836 "size of UniformMatrix4x2fvImmediate should be 12");
9837 static_assert(offsetof(UniformMatrix4x2fvImmediate
, header
) == 0,
9838 "offset of UniformMatrix4x2fvImmediate header should be 0");
9839 static_assert(offsetof(UniformMatrix4x2fvImmediate
, location
) == 4,
9840 "offset of UniformMatrix4x2fvImmediate location should be 4");
9841 static_assert(offsetof(UniformMatrix4x2fvImmediate
, count
) == 8,
9842 "offset of UniformMatrix4x2fvImmediate count should be 8");
9844 struct UniformMatrix4x3fvImmediate
{
9845 typedef UniformMatrix4x3fvImmediate ValueType
;
9846 static const CommandId kCmdId
= kUniformMatrix4x3fvImmediate
;
9847 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9848 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9850 static uint32_t ComputeDataSize(GLsizei count
) {
9851 return static_cast<uint32_t>(sizeof(GLfloat
) * 12 * count
); // NOLINT
9854 static uint32_t ComputeSize(GLsizei count
) {
9855 return static_cast<uint32_t>(sizeof(ValueType
) +
9856 ComputeDataSize(count
)); // NOLINT
9859 void SetHeader(GLsizei count
) {
9860 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
9863 void Init(GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9865 location
= _location
;
9867 memcpy(ImmediateDataAddress(this), _value
, ComputeDataSize(_count
));
9870 void* Set(void* cmd
, GLint _location
, GLsizei _count
, const GLfloat
* _value
) {
9871 static_cast<ValueType
*>(cmd
)->Init(_location
, _count
, _value
);
9872 const uint32_t size
= ComputeSize(_count
);
9873 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
9876 gpu::CommandHeader header
;
9879 static const uint32_t transpose
= false;
9882 static_assert(sizeof(UniformMatrix4x3fvImmediate
) == 12,
9883 "size of UniformMatrix4x3fvImmediate should be 12");
9884 static_assert(offsetof(UniformMatrix4x3fvImmediate
, header
) == 0,
9885 "offset of UniformMatrix4x3fvImmediate header should be 0");
9886 static_assert(offsetof(UniformMatrix4x3fvImmediate
, location
) == 4,
9887 "offset of UniformMatrix4x3fvImmediate location should be 4");
9888 static_assert(offsetof(UniformMatrix4x3fvImmediate
, count
) == 8,
9889 "offset of UniformMatrix4x3fvImmediate count should be 8");
9892 typedef UseProgram ValueType
;
9893 static const CommandId kCmdId
= kUseProgram
;
9894 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9895 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9897 static uint32_t ComputeSize() {
9898 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9901 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9903 void Init(GLuint _program
) {
9908 void* Set(void* cmd
, GLuint _program
) {
9909 static_cast<ValueType
*>(cmd
)->Init(_program
);
9910 return NextCmdAddress
<ValueType
>(cmd
);
9913 gpu::CommandHeader header
;
9917 static_assert(sizeof(UseProgram
) == 8, "size of UseProgram should be 8");
9918 static_assert(offsetof(UseProgram
, header
) == 0,
9919 "offset of UseProgram header should be 0");
9920 static_assert(offsetof(UseProgram
, program
) == 4,
9921 "offset of UseProgram program should be 4");
9923 struct ValidateProgram
{
9924 typedef ValidateProgram ValueType
;
9925 static const CommandId kCmdId
= kValidateProgram
;
9926 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9927 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9929 static uint32_t ComputeSize() {
9930 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9933 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9935 void Init(GLuint _program
) {
9940 void* Set(void* cmd
, GLuint _program
) {
9941 static_cast<ValueType
*>(cmd
)->Init(_program
);
9942 return NextCmdAddress
<ValueType
>(cmd
);
9945 gpu::CommandHeader header
;
9949 static_assert(sizeof(ValidateProgram
) == 8,
9950 "size of ValidateProgram should be 8");
9951 static_assert(offsetof(ValidateProgram
, header
) == 0,
9952 "offset of ValidateProgram header should be 0");
9953 static_assert(offsetof(ValidateProgram
, program
) == 4,
9954 "offset of ValidateProgram program should be 4");
9956 struct VertexAttrib1f
{
9957 typedef VertexAttrib1f ValueType
;
9958 static const CommandId kCmdId
= kVertexAttrib1f
;
9959 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
9960 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9962 static uint32_t ComputeSize() {
9963 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
9966 void SetHeader() { header
.SetCmd
<ValueType
>(); }
9968 void Init(GLuint _indx
, GLfloat _x
) {
9974 void* Set(void* cmd
, GLuint _indx
, GLfloat _x
) {
9975 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
);
9976 return NextCmdAddress
<ValueType
>(cmd
);
9979 gpu::CommandHeader header
;
9984 static_assert(sizeof(VertexAttrib1f
) == 12,
9985 "size of VertexAttrib1f should be 12");
9986 static_assert(offsetof(VertexAttrib1f
, header
) == 0,
9987 "offset of VertexAttrib1f header should be 0");
9988 static_assert(offsetof(VertexAttrib1f
, indx
) == 4,
9989 "offset of VertexAttrib1f indx should be 4");
9990 static_assert(offsetof(VertexAttrib1f
, x
) == 8,
9991 "offset of VertexAttrib1f x should be 8");
9993 struct VertexAttrib1fvImmediate
{
9994 typedef VertexAttrib1fvImmediate ValueType
;
9995 static const CommandId kCmdId
= kVertexAttrib1fvImmediate
;
9996 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
9997 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
9999 static uint32_t ComputeDataSize() {
10000 return static_cast<uint32_t>(sizeof(GLfloat
) * 1);
10003 static uint32_t ComputeSize() {
10004 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10007 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10009 void Init(GLuint _indx
, const GLfloat
* _values
) {
10012 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10015 void* Set(void* cmd
, GLuint _indx
, const GLfloat
* _values
) {
10016 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10017 const uint32_t size
= ComputeSize();
10018 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10021 gpu::CommandHeader header
;
10025 static_assert(sizeof(VertexAttrib1fvImmediate
) == 8,
10026 "size of VertexAttrib1fvImmediate should be 8");
10027 static_assert(offsetof(VertexAttrib1fvImmediate
, header
) == 0,
10028 "offset of VertexAttrib1fvImmediate header should be 0");
10029 static_assert(offsetof(VertexAttrib1fvImmediate
, indx
) == 4,
10030 "offset of VertexAttrib1fvImmediate indx should be 4");
10032 struct VertexAttrib2f
{
10033 typedef VertexAttrib2f ValueType
;
10034 static const CommandId kCmdId
= kVertexAttrib2f
;
10035 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10036 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10038 static uint32_t ComputeSize() {
10039 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10042 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10044 void Init(GLuint _indx
, GLfloat _x
, GLfloat _y
) {
10051 void* Set(void* cmd
, GLuint _indx
, GLfloat _x
, GLfloat _y
) {
10052 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
, _y
);
10053 return NextCmdAddress
<ValueType
>(cmd
);
10056 gpu::CommandHeader header
;
10062 static_assert(sizeof(VertexAttrib2f
) == 16,
10063 "size of VertexAttrib2f should be 16");
10064 static_assert(offsetof(VertexAttrib2f
, header
) == 0,
10065 "offset of VertexAttrib2f header should be 0");
10066 static_assert(offsetof(VertexAttrib2f
, indx
) == 4,
10067 "offset of VertexAttrib2f indx should be 4");
10068 static_assert(offsetof(VertexAttrib2f
, x
) == 8,
10069 "offset of VertexAttrib2f x should be 8");
10070 static_assert(offsetof(VertexAttrib2f
, y
) == 12,
10071 "offset of VertexAttrib2f y should be 12");
10073 struct VertexAttrib2fvImmediate
{
10074 typedef VertexAttrib2fvImmediate ValueType
;
10075 static const CommandId kCmdId
= kVertexAttrib2fvImmediate
;
10076 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
10077 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10079 static uint32_t ComputeDataSize() {
10080 return static_cast<uint32_t>(sizeof(GLfloat
) * 2);
10083 static uint32_t ComputeSize() {
10084 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10087 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10089 void Init(GLuint _indx
, const GLfloat
* _values
) {
10092 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10095 void* Set(void* cmd
, GLuint _indx
, const GLfloat
* _values
) {
10096 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10097 const uint32_t size
= ComputeSize();
10098 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10101 gpu::CommandHeader header
;
10105 static_assert(sizeof(VertexAttrib2fvImmediate
) == 8,
10106 "size of VertexAttrib2fvImmediate should be 8");
10107 static_assert(offsetof(VertexAttrib2fvImmediate
, header
) == 0,
10108 "offset of VertexAttrib2fvImmediate header should be 0");
10109 static_assert(offsetof(VertexAttrib2fvImmediate
, indx
) == 4,
10110 "offset of VertexAttrib2fvImmediate indx should be 4");
10112 struct VertexAttrib3f
{
10113 typedef VertexAttrib3f ValueType
;
10114 static const CommandId kCmdId
= kVertexAttrib3f
;
10115 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10116 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10118 static uint32_t ComputeSize() {
10119 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10122 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10124 void Init(GLuint _indx
, GLfloat _x
, GLfloat _y
, GLfloat _z
) {
10132 void* Set(void* cmd
, GLuint _indx
, GLfloat _x
, GLfloat _y
, GLfloat _z
) {
10133 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
, _y
, _z
);
10134 return NextCmdAddress
<ValueType
>(cmd
);
10137 gpu::CommandHeader header
;
10144 static_assert(sizeof(VertexAttrib3f
) == 20,
10145 "size of VertexAttrib3f should be 20");
10146 static_assert(offsetof(VertexAttrib3f
, header
) == 0,
10147 "offset of VertexAttrib3f header should be 0");
10148 static_assert(offsetof(VertexAttrib3f
, indx
) == 4,
10149 "offset of VertexAttrib3f indx should be 4");
10150 static_assert(offsetof(VertexAttrib3f
, x
) == 8,
10151 "offset of VertexAttrib3f x should be 8");
10152 static_assert(offsetof(VertexAttrib3f
, y
) == 12,
10153 "offset of VertexAttrib3f y should be 12");
10154 static_assert(offsetof(VertexAttrib3f
, z
) == 16,
10155 "offset of VertexAttrib3f z should be 16");
10157 struct VertexAttrib3fvImmediate
{
10158 typedef VertexAttrib3fvImmediate ValueType
;
10159 static const CommandId kCmdId
= kVertexAttrib3fvImmediate
;
10160 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
10161 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10163 static uint32_t ComputeDataSize() {
10164 return static_cast<uint32_t>(sizeof(GLfloat
) * 3);
10167 static uint32_t ComputeSize() {
10168 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10171 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10173 void Init(GLuint _indx
, const GLfloat
* _values
) {
10176 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10179 void* Set(void* cmd
, GLuint _indx
, const GLfloat
* _values
) {
10180 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10181 const uint32_t size
= ComputeSize();
10182 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10185 gpu::CommandHeader header
;
10189 static_assert(sizeof(VertexAttrib3fvImmediate
) == 8,
10190 "size of VertexAttrib3fvImmediate should be 8");
10191 static_assert(offsetof(VertexAttrib3fvImmediate
, header
) == 0,
10192 "offset of VertexAttrib3fvImmediate header should be 0");
10193 static_assert(offsetof(VertexAttrib3fvImmediate
, indx
) == 4,
10194 "offset of VertexAttrib3fvImmediate indx should be 4");
10196 struct VertexAttrib4f
{
10197 typedef VertexAttrib4f ValueType
;
10198 static const CommandId kCmdId
= kVertexAttrib4f
;
10199 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10200 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10202 static uint32_t ComputeSize() {
10203 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10206 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10208 void Init(GLuint _indx
, GLfloat _x
, GLfloat _y
, GLfloat _z
, GLfloat _w
) {
10217 void* Set(void* cmd
,
10223 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
, _y
, _z
, _w
);
10224 return NextCmdAddress
<ValueType
>(cmd
);
10227 gpu::CommandHeader header
;
10235 static_assert(sizeof(VertexAttrib4f
) == 24,
10236 "size of VertexAttrib4f should be 24");
10237 static_assert(offsetof(VertexAttrib4f
, header
) == 0,
10238 "offset of VertexAttrib4f header should be 0");
10239 static_assert(offsetof(VertexAttrib4f
, indx
) == 4,
10240 "offset of VertexAttrib4f indx should be 4");
10241 static_assert(offsetof(VertexAttrib4f
, x
) == 8,
10242 "offset of VertexAttrib4f x should be 8");
10243 static_assert(offsetof(VertexAttrib4f
, y
) == 12,
10244 "offset of VertexAttrib4f y should be 12");
10245 static_assert(offsetof(VertexAttrib4f
, z
) == 16,
10246 "offset of VertexAttrib4f z should be 16");
10247 static_assert(offsetof(VertexAttrib4f
, w
) == 20,
10248 "offset of VertexAttrib4f w should be 20");
10250 struct VertexAttrib4fvImmediate
{
10251 typedef VertexAttrib4fvImmediate ValueType
;
10252 static const CommandId kCmdId
= kVertexAttrib4fvImmediate
;
10253 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
10254 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10256 static uint32_t ComputeDataSize() {
10257 return static_cast<uint32_t>(sizeof(GLfloat
) * 4);
10260 static uint32_t ComputeSize() {
10261 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10264 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10266 void Init(GLuint _indx
, const GLfloat
* _values
) {
10269 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10272 void* Set(void* cmd
, GLuint _indx
, const GLfloat
* _values
) {
10273 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10274 const uint32_t size
= ComputeSize();
10275 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10278 gpu::CommandHeader header
;
10282 static_assert(sizeof(VertexAttrib4fvImmediate
) == 8,
10283 "size of VertexAttrib4fvImmediate should be 8");
10284 static_assert(offsetof(VertexAttrib4fvImmediate
, header
) == 0,
10285 "offset of VertexAttrib4fvImmediate header should be 0");
10286 static_assert(offsetof(VertexAttrib4fvImmediate
, indx
) == 4,
10287 "offset of VertexAttrib4fvImmediate indx should be 4");
10289 struct VertexAttribI4i
{
10290 typedef VertexAttribI4i ValueType
;
10291 static const CommandId kCmdId
= kVertexAttribI4i
;
10292 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10293 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10295 static uint32_t ComputeSize() {
10296 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10299 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10301 void Init(GLuint _indx
, GLint _x
, GLint _y
, GLint _z
, GLint _w
) {
10310 void* Set(void* cmd
, GLuint _indx
, GLint _x
, GLint _y
, GLint _z
, GLint _w
) {
10311 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
, _y
, _z
, _w
);
10312 return NextCmdAddress
<ValueType
>(cmd
);
10315 gpu::CommandHeader header
;
10323 static_assert(sizeof(VertexAttribI4i
) == 24,
10324 "size of VertexAttribI4i should be 24");
10325 static_assert(offsetof(VertexAttribI4i
, header
) == 0,
10326 "offset of VertexAttribI4i header should be 0");
10327 static_assert(offsetof(VertexAttribI4i
, indx
) == 4,
10328 "offset of VertexAttribI4i indx should be 4");
10329 static_assert(offsetof(VertexAttribI4i
, x
) == 8,
10330 "offset of VertexAttribI4i x should be 8");
10331 static_assert(offsetof(VertexAttribI4i
, y
) == 12,
10332 "offset of VertexAttribI4i y should be 12");
10333 static_assert(offsetof(VertexAttribI4i
, z
) == 16,
10334 "offset of VertexAttribI4i z should be 16");
10335 static_assert(offsetof(VertexAttribI4i
, w
) == 20,
10336 "offset of VertexAttribI4i w should be 20");
10338 struct VertexAttribI4ivImmediate
{
10339 typedef VertexAttribI4ivImmediate ValueType
;
10340 static const CommandId kCmdId
= kVertexAttribI4ivImmediate
;
10341 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
10342 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10344 static uint32_t ComputeDataSize() {
10345 return static_cast<uint32_t>(sizeof(GLint
) * 4);
10348 static uint32_t ComputeSize() {
10349 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10352 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10354 void Init(GLuint _indx
, const GLint
* _values
) {
10357 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10360 void* Set(void* cmd
, GLuint _indx
, const GLint
* _values
) {
10361 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10362 const uint32_t size
= ComputeSize();
10363 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10366 gpu::CommandHeader header
;
10370 static_assert(sizeof(VertexAttribI4ivImmediate
) == 8,
10371 "size of VertexAttribI4ivImmediate should be 8");
10372 static_assert(offsetof(VertexAttribI4ivImmediate
, header
) == 0,
10373 "offset of VertexAttribI4ivImmediate header should be 0");
10374 static_assert(offsetof(VertexAttribI4ivImmediate
, indx
) == 4,
10375 "offset of VertexAttribI4ivImmediate indx should be 4");
10377 struct VertexAttribI4ui
{
10378 typedef VertexAttribI4ui ValueType
;
10379 static const CommandId kCmdId
= kVertexAttribI4ui
;
10380 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10381 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10383 static uint32_t ComputeSize() {
10384 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10387 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10389 void Init(GLuint _indx
, GLuint _x
, GLuint _y
, GLuint _z
, GLuint _w
) {
10398 void* Set(void* cmd
,
10404 static_cast<ValueType
*>(cmd
)->Init(_indx
, _x
, _y
, _z
, _w
);
10405 return NextCmdAddress
<ValueType
>(cmd
);
10408 gpu::CommandHeader header
;
10416 static_assert(sizeof(VertexAttribI4ui
) == 24,
10417 "size of VertexAttribI4ui should be 24");
10418 static_assert(offsetof(VertexAttribI4ui
, header
) == 0,
10419 "offset of VertexAttribI4ui header should be 0");
10420 static_assert(offsetof(VertexAttribI4ui
, indx
) == 4,
10421 "offset of VertexAttribI4ui indx should be 4");
10422 static_assert(offsetof(VertexAttribI4ui
, x
) == 8,
10423 "offset of VertexAttribI4ui x should be 8");
10424 static_assert(offsetof(VertexAttribI4ui
, y
) == 12,
10425 "offset of VertexAttribI4ui y should be 12");
10426 static_assert(offsetof(VertexAttribI4ui
, z
) == 16,
10427 "offset of VertexAttribI4ui z should be 16");
10428 static_assert(offsetof(VertexAttribI4ui
, w
) == 20,
10429 "offset of VertexAttribI4ui w should be 20");
10431 struct VertexAttribI4uivImmediate
{
10432 typedef VertexAttribI4uivImmediate ValueType
;
10433 static const CommandId kCmdId
= kVertexAttribI4uivImmediate
;
10434 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
10435 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10437 static uint32_t ComputeDataSize() {
10438 return static_cast<uint32_t>(sizeof(GLuint
) * 4);
10441 static uint32_t ComputeSize() {
10442 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
10445 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
10447 void Init(GLuint _indx
, const GLuint
* _values
) {
10450 memcpy(ImmediateDataAddress(this), _values
, ComputeDataSize());
10453 void* Set(void* cmd
, GLuint _indx
, const GLuint
* _values
) {
10454 static_cast<ValueType
*>(cmd
)->Init(_indx
, _values
);
10455 const uint32_t size
= ComputeSize();
10456 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
10459 gpu::CommandHeader header
;
10463 static_assert(sizeof(VertexAttribI4uivImmediate
) == 8,
10464 "size of VertexAttribI4uivImmediate should be 8");
10465 static_assert(offsetof(VertexAttribI4uivImmediate
, header
) == 0,
10466 "offset of VertexAttribI4uivImmediate header should be 0");
10467 static_assert(offsetof(VertexAttribI4uivImmediate
, indx
) == 4,
10468 "offset of VertexAttribI4uivImmediate indx should be 4");
10470 struct VertexAttribIPointer
{
10471 typedef VertexAttribIPointer ValueType
;
10472 static const CommandId kCmdId
= kVertexAttribIPointer
;
10473 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10474 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10476 static uint32_t ComputeSize() {
10477 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10480 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10482 void Init(GLuint _indx
,
10495 void* Set(void* cmd
,
10501 static_cast<ValueType
*>(cmd
)->Init(_indx
, _size
, _type
, _stride
, _offset
);
10502 return NextCmdAddress
<ValueType
>(cmd
);
10505 gpu::CommandHeader header
;
10513 static_assert(sizeof(VertexAttribIPointer
) == 24,
10514 "size of VertexAttribIPointer should be 24");
10515 static_assert(offsetof(VertexAttribIPointer
, header
) == 0,
10516 "offset of VertexAttribIPointer header should be 0");
10517 static_assert(offsetof(VertexAttribIPointer
, indx
) == 4,
10518 "offset of VertexAttribIPointer indx should be 4");
10519 static_assert(offsetof(VertexAttribIPointer
, size
) == 8,
10520 "offset of VertexAttribIPointer size should be 8");
10521 static_assert(offsetof(VertexAttribIPointer
, type
) == 12,
10522 "offset of VertexAttribIPointer type should be 12");
10523 static_assert(offsetof(VertexAttribIPointer
, stride
) == 16,
10524 "offset of VertexAttribIPointer stride should be 16");
10525 static_assert(offsetof(VertexAttribIPointer
, offset
) == 20,
10526 "offset of VertexAttribIPointer offset should be 20");
10528 struct VertexAttribPointer
{
10529 typedef VertexAttribPointer ValueType
;
10530 static const CommandId kCmdId
= kVertexAttribPointer
;
10531 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10532 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10534 static uint32_t ComputeSize() {
10535 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10538 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10540 void Init(GLuint _indx
,
10543 GLboolean _normalized
,
10550 normalized
= _normalized
;
10555 void* Set(void* cmd
,
10559 GLboolean _normalized
,
10562 static_cast<ValueType
*>(cmd
)
10563 ->Init(_indx
, _size
, _type
, _normalized
, _stride
, _offset
);
10564 return NextCmdAddress
<ValueType
>(cmd
);
10567 gpu::CommandHeader header
;
10571 uint32_t normalized
;
10576 static_assert(sizeof(VertexAttribPointer
) == 28,
10577 "size of VertexAttribPointer should be 28");
10578 static_assert(offsetof(VertexAttribPointer
, header
) == 0,
10579 "offset of VertexAttribPointer header should be 0");
10580 static_assert(offsetof(VertexAttribPointer
, indx
) == 4,
10581 "offset of VertexAttribPointer indx should be 4");
10582 static_assert(offsetof(VertexAttribPointer
, size
) == 8,
10583 "offset of VertexAttribPointer size should be 8");
10584 static_assert(offsetof(VertexAttribPointer
, type
) == 12,
10585 "offset of VertexAttribPointer type should be 12");
10586 static_assert(offsetof(VertexAttribPointer
, normalized
) == 16,
10587 "offset of VertexAttribPointer normalized should be 16");
10588 static_assert(offsetof(VertexAttribPointer
, stride
) == 20,
10589 "offset of VertexAttribPointer stride should be 20");
10590 static_assert(offsetof(VertexAttribPointer
, offset
) == 24,
10591 "offset of VertexAttribPointer offset should be 24");
10594 typedef Viewport ValueType
;
10595 static const CommandId kCmdId
= kViewport
;
10596 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10597 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
10599 static uint32_t ComputeSize() {
10600 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10603 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10605 void Init(GLint _x
, GLint _y
, GLsizei _width
, GLsizei _height
) {
10613 void* Set(void* cmd
, GLint _x
, GLint _y
, GLsizei _width
, GLsizei _height
) {
10614 static_cast<ValueType
*>(cmd
)->Init(_x
, _y
, _width
, _height
);
10615 return NextCmdAddress
<ValueType
>(cmd
);
10618 gpu::CommandHeader header
;
10625 static_assert(sizeof(Viewport
) == 20, "size of Viewport should be 20");
10626 static_assert(offsetof(Viewport
, header
) == 0,
10627 "offset of Viewport header should be 0");
10628 static_assert(offsetof(Viewport
, x
) == 4, "offset of Viewport x should be 4");
10629 static_assert(offsetof(Viewport
, y
) == 8, "offset of Viewport y should be 8");
10630 static_assert(offsetof(Viewport
, width
) == 12,
10631 "offset of Viewport width should be 12");
10632 static_assert(offsetof(Viewport
, height
) == 16,
10633 "offset of Viewport height should be 16");
10636 typedef WaitSync ValueType
;
10637 static const CommandId kCmdId
= kWaitSync
;
10638 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10639 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
10641 static uint32_t ComputeSize() {
10642 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10645 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10647 void Init(GLuint _sync
,
10650 GLuint _timeout_1
) {
10654 timeout_0
= _timeout_0
;
10655 timeout_1
= _timeout_1
;
10658 void* Set(void* cmd
,
10662 GLuint _timeout_1
) {
10663 static_cast<ValueType
*>(cmd
)->Init(_sync
, _flags
, _timeout_0
, _timeout_1
);
10664 return NextCmdAddress
<ValueType
>(cmd
);
10667 gpu::CommandHeader header
;
10670 uint32_t timeout_0
;
10671 uint32_t timeout_1
;
10674 static_assert(sizeof(WaitSync
) == 20, "size of WaitSync should be 20");
10675 static_assert(offsetof(WaitSync
, header
) == 0,
10676 "offset of WaitSync header should be 0");
10677 static_assert(offsetof(WaitSync
, sync
) == 4,
10678 "offset of WaitSync sync should be 4");
10679 static_assert(offsetof(WaitSync
, flags
) == 8,
10680 "offset of WaitSync flags should be 8");
10681 static_assert(offsetof(WaitSync
, timeout_0
) == 12,
10682 "offset of WaitSync timeout_0 should be 12");
10683 static_assert(offsetof(WaitSync
, timeout_1
) == 16,
10684 "offset of WaitSync timeout_1 should be 16");
10686 struct BlitFramebufferCHROMIUM
{
10687 typedef BlitFramebufferCHROMIUM ValueType
;
10688 static const CommandId kCmdId
= kBlitFramebufferCHROMIUM
;
10689 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10690 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
10692 static uint32_t ComputeSize() {
10693 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10696 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10698 void Init(GLint _srcX0
,
10721 void* Set(void* cmd
,
10732 static_cast<ValueType
*>(cmd
)->Init(_srcX0
, _srcY0
, _srcX1
, _srcY1
, _dstX0
,
10733 _dstY0
, _dstX1
, _dstY1
, _mask
, _filter
);
10734 return NextCmdAddress
<ValueType
>(cmd
);
10737 gpu::CommandHeader header
;
10750 static_assert(sizeof(BlitFramebufferCHROMIUM
) == 44,
10751 "size of BlitFramebufferCHROMIUM should be 44");
10752 static_assert(offsetof(BlitFramebufferCHROMIUM
, header
) == 0,
10753 "offset of BlitFramebufferCHROMIUM header should be 0");
10754 static_assert(offsetof(BlitFramebufferCHROMIUM
, srcX0
) == 4,
10755 "offset of BlitFramebufferCHROMIUM srcX0 should be 4");
10756 static_assert(offsetof(BlitFramebufferCHROMIUM
, srcY0
) == 8,
10757 "offset of BlitFramebufferCHROMIUM srcY0 should be 8");
10758 static_assert(offsetof(BlitFramebufferCHROMIUM
, srcX1
) == 12,
10759 "offset of BlitFramebufferCHROMIUM srcX1 should be 12");
10760 static_assert(offsetof(BlitFramebufferCHROMIUM
, srcY1
) == 16,
10761 "offset of BlitFramebufferCHROMIUM srcY1 should be 16");
10762 static_assert(offsetof(BlitFramebufferCHROMIUM
, dstX0
) == 20,
10763 "offset of BlitFramebufferCHROMIUM dstX0 should be 20");
10764 static_assert(offsetof(BlitFramebufferCHROMIUM
, dstY0
) == 24,
10765 "offset of BlitFramebufferCHROMIUM dstY0 should be 24");
10766 static_assert(offsetof(BlitFramebufferCHROMIUM
, dstX1
) == 28,
10767 "offset of BlitFramebufferCHROMIUM dstX1 should be 28");
10768 static_assert(offsetof(BlitFramebufferCHROMIUM
, dstY1
) == 32,
10769 "offset of BlitFramebufferCHROMIUM dstY1 should be 32");
10770 static_assert(offsetof(BlitFramebufferCHROMIUM
, mask
) == 36,
10771 "offset of BlitFramebufferCHROMIUM mask should be 36");
10772 static_assert(offsetof(BlitFramebufferCHROMIUM
, filter
) == 40,
10773 "offset of BlitFramebufferCHROMIUM filter should be 40");
10775 // GL_CHROMIUM_framebuffer_multisample
10776 struct RenderbufferStorageMultisampleCHROMIUM
{
10777 typedef RenderbufferStorageMultisampleCHROMIUM ValueType
;
10778 static const CommandId kCmdId
= kRenderbufferStorageMultisampleCHROMIUM
;
10779 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10780 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
10782 static uint32_t ComputeSize() {
10783 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10786 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10788 void Init(GLenum _target
,
10790 GLenum _internalformat
,
10795 samples
= _samples
;
10796 internalformat
= _internalformat
;
10801 void* Set(void* cmd
,
10804 GLenum _internalformat
,
10807 static_cast<ValueType
*>(cmd
)
10808 ->Init(_target
, _samples
, _internalformat
, _width
, _height
);
10809 return NextCmdAddress
<ValueType
>(cmd
);
10812 gpu::CommandHeader header
;
10815 uint32_t internalformat
;
10820 static_assert(sizeof(RenderbufferStorageMultisampleCHROMIUM
) == 24,
10821 "size of RenderbufferStorageMultisampleCHROMIUM should be 24");
10823 offsetof(RenderbufferStorageMultisampleCHROMIUM
, header
) == 0,
10824 "offset of RenderbufferStorageMultisampleCHROMIUM header should be 0");
10826 offsetof(RenderbufferStorageMultisampleCHROMIUM
, target
) == 4,
10827 "offset of RenderbufferStorageMultisampleCHROMIUM target should be 4");
10829 offsetof(RenderbufferStorageMultisampleCHROMIUM
, samples
) == 8,
10830 "offset of RenderbufferStorageMultisampleCHROMIUM samples should be 8");
10831 static_assert(offsetof(RenderbufferStorageMultisampleCHROMIUM
,
10832 internalformat
) == 12,
10833 "offset of RenderbufferStorageMultisampleCHROMIUM internalformat "
10836 offsetof(RenderbufferStorageMultisampleCHROMIUM
, width
) == 16,
10837 "offset of RenderbufferStorageMultisampleCHROMIUM width should be 16");
10839 offsetof(RenderbufferStorageMultisampleCHROMIUM
, height
) == 20,
10840 "offset of RenderbufferStorageMultisampleCHROMIUM height should be 20");
10842 // GL_EXT_multisampled_render_to_texture
10843 struct RenderbufferStorageMultisampleEXT
{
10844 typedef RenderbufferStorageMultisampleEXT ValueType
;
10845 static const CommandId kCmdId
= kRenderbufferStorageMultisampleEXT
;
10846 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10847 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
10849 static uint32_t ComputeSize() {
10850 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10853 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10855 void Init(GLenum _target
,
10857 GLenum _internalformat
,
10862 samples
= _samples
;
10863 internalformat
= _internalformat
;
10868 void* Set(void* cmd
,
10871 GLenum _internalformat
,
10874 static_cast<ValueType
*>(cmd
)
10875 ->Init(_target
, _samples
, _internalformat
, _width
, _height
);
10876 return NextCmdAddress
<ValueType
>(cmd
);
10879 gpu::CommandHeader header
;
10882 uint32_t internalformat
;
10887 static_assert(sizeof(RenderbufferStorageMultisampleEXT
) == 24,
10888 "size of RenderbufferStorageMultisampleEXT should be 24");
10889 static_assert(offsetof(RenderbufferStorageMultisampleEXT
, header
) == 0,
10890 "offset of RenderbufferStorageMultisampleEXT header should be 0");
10891 static_assert(offsetof(RenderbufferStorageMultisampleEXT
, target
) == 4,
10892 "offset of RenderbufferStorageMultisampleEXT target should be 4");
10894 offsetof(RenderbufferStorageMultisampleEXT
, samples
) == 8,
10895 "offset of RenderbufferStorageMultisampleEXT samples should be 8");
10897 offsetof(RenderbufferStorageMultisampleEXT
, internalformat
) == 12,
10898 "offset of RenderbufferStorageMultisampleEXT internalformat should be 12");
10899 static_assert(offsetof(RenderbufferStorageMultisampleEXT
, width
) == 16,
10900 "offset of RenderbufferStorageMultisampleEXT width should be 16");
10902 offsetof(RenderbufferStorageMultisampleEXT
, height
) == 20,
10903 "offset of RenderbufferStorageMultisampleEXT height should be 20");
10905 struct FramebufferTexture2DMultisampleEXT
{
10906 typedef FramebufferTexture2DMultisampleEXT ValueType
;
10907 static const CommandId kCmdId
= kFramebufferTexture2DMultisampleEXT
;
10908 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10909 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
10911 static uint32_t ComputeSize() {
10912 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10915 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10917 void Init(GLenum _target
,
10918 GLenum _attachment
,
10921 GLsizei _samples
) {
10924 attachment
= _attachment
;
10925 textarget
= _textarget
;
10926 texture
= _texture
;
10927 samples
= _samples
;
10930 void* Set(void* cmd
,
10932 GLenum _attachment
,
10935 GLsizei _samples
) {
10936 static_cast<ValueType
*>(cmd
)
10937 ->Init(_target
, _attachment
, _textarget
, _texture
, _samples
);
10938 return NextCmdAddress
<ValueType
>(cmd
);
10941 gpu::CommandHeader header
;
10943 uint32_t attachment
;
10944 uint32_t textarget
;
10947 static const int32_t level
= 0;
10950 static_assert(sizeof(FramebufferTexture2DMultisampleEXT
) == 24,
10951 "size of FramebufferTexture2DMultisampleEXT should be 24");
10953 offsetof(FramebufferTexture2DMultisampleEXT
, header
) == 0,
10954 "offset of FramebufferTexture2DMultisampleEXT header should be 0");
10956 offsetof(FramebufferTexture2DMultisampleEXT
, target
) == 4,
10957 "offset of FramebufferTexture2DMultisampleEXT target should be 4");
10959 offsetof(FramebufferTexture2DMultisampleEXT
, attachment
) == 8,
10960 "offset of FramebufferTexture2DMultisampleEXT attachment should be 8");
10962 offsetof(FramebufferTexture2DMultisampleEXT
, textarget
) == 12,
10963 "offset of FramebufferTexture2DMultisampleEXT textarget should be 12");
10965 offsetof(FramebufferTexture2DMultisampleEXT
, texture
) == 16,
10966 "offset of FramebufferTexture2DMultisampleEXT texture should be 16");
10968 offsetof(FramebufferTexture2DMultisampleEXT
, samples
) == 20,
10969 "offset of FramebufferTexture2DMultisampleEXT samples should be 20");
10971 struct TexStorage2DEXT
{
10972 typedef TexStorage2DEXT ValueType
;
10973 static const CommandId kCmdId
= kTexStorage2DEXT
;
10974 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
10975 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
10977 static uint32_t ComputeSize() {
10978 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
10981 void SetHeader() { header
.SetCmd
<ValueType
>(); }
10983 void Init(GLenum _target
,
10985 GLenum _internalFormat
,
10991 internalFormat
= _internalFormat
;
10996 void* Set(void* cmd
,
10999 GLenum _internalFormat
,
11002 static_cast<ValueType
*>(cmd
)
11003 ->Init(_target
, _levels
, _internalFormat
, _width
, _height
);
11004 return NextCmdAddress
<ValueType
>(cmd
);
11007 gpu::CommandHeader header
;
11010 uint32_t internalFormat
;
11015 static_assert(sizeof(TexStorage2DEXT
) == 24,
11016 "size of TexStorage2DEXT should be 24");
11017 static_assert(offsetof(TexStorage2DEXT
, header
) == 0,
11018 "offset of TexStorage2DEXT header should be 0");
11019 static_assert(offsetof(TexStorage2DEXT
, target
) == 4,
11020 "offset of TexStorage2DEXT target should be 4");
11021 static_assert(offsetof(TexStorage2DEXT
, levels
) == 8,
11022 "offset of TexStorage2DEXT levels should be 8");
11023 static_assert(offsetof(TexStorage2DEXT
, internalFormat
) == 12,
11024 "offset of TexStorage2DEXT internalFormat should be 12");
11025 static_assert(offsetof(TexStorage2DEXT
, width
) == 16,
11026 "offset of TexStorage2DEXT width should be 16");
11027 static_assert(offsetof(TexStorage2DEXT
, height
) == 20,
11028 "offset of TexStorage2DEXT height should be 20");
11030 struct GenQueriesEXTImmediate
{
11031 typedef GenQueriesEXTImmediate ValueType
;
11032 static const CommandId kCmdId
= kGenQueriesEXTImmediate
;
11033 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
11034 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11036 static uint32_t ComputeDataSize(GLsizei n
) {
11037 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
11040 static uint32_t ComputeSize(GLsizei n
) {
11041 return static_cast<uint32_t>(sizeof(ValueType
) +
11042 ComputeDataSize(n
)); // NOLINT
11045 void SetHeader(GLsizei n
) {
11046 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
11049 void Init(GLsizei _n
, GLuint
* _queries
) {
11052 memcpy(ImmediateDataAddress(this), _queries
, ComputeDataSize(_n
));
11055 void* Set(void* cmd
, GLsizei _n
, GLuint
* _queries
) {
11056 static_cast<ValueType
*>(cmd
)->Init(_n
, _queries
);
11057 const uint32_t size
= ComputeSize(_n
);
11058 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
11061 gpu::CommandHeader header
;
11065 static_assert(sizeof(GenQueriesEXTImmediate
) == 8,
11066 "size of GenQueriesEXTImmediate should be 8");
11067 static_assert(offsetof(GenQueriesEXTImmediate
, header
) == 0,
11068 "offset of GenQueriesEXTImmediate header should be 0");
11069 static_assert(offsetof(GenQueriesEXTImmediate
, n
) == 4,
11070 "offset of GenQueriesEXTImmediate n should be 4");
11072 struct DeleteQueriesEXTImmediate
{
11073 typedef DeleteQueriesEXTImmediate ValueType
;
11074 static const CommandId kCmdId
= kDeleteQueriesEXTImmediate
;
11075 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
11076 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11078 static uint32_t ComputeDataSize(GLsizei n
) {
11079 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
11082 static uint32_t ComputeSize(GLsizei n
) {
11083 return static_cast<uint32_t>(sizeof(ValueType
) +
11084 ComputeDataSize(n
)); // NOLINT
11087 void SetHeader(GLsizei n
) {
11088 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
11091 void Init(GLsizei _n
, const GLuint
* _queries
) {
11094 memcpy(ImmediateDataAddress(this), _queries
, ComputeDataSize(_n
));
11097 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _queries
) {
11098 static_cast<ValueType
*>(cmd
)->Init(_n
, _queries
);
11099 const uint32_t size
= ComputeSize(_n
);
11100 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
11103 gpu::CommandHeader header
;
11107 static_assert(sizeof(DeleteQueriesEXTImmediate
) == 8,
11108 "size of DeleteQueriesEXTImmediate should be 8");
11109 static_assert(offsetof(DeleteQueriesEXTImmediate
, header
) == 0,
11110 "offset of DeleteQueriesEXTImmediate header should be 0");
11111 static_assert(offsetof(DeleteQueriesEXTImmediate
, n
) == 4,
11112 "offset of DeleteQueriesEXTImmediate n should be 4");
11114 struct QueryCounterEXT
{
11115 typedef QueryCounterEXT ValueType
;
11116 static const CommandId kCmdId
= kQueryCounterEXT
;
11117 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11118 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11120 static uint32_t ComputeSize() {
11121 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11124 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11126 void Init(GLuint _id
,
11128 uint32_t _sync_data_shm_id
,
11129 uint32_t _sync_data_shm_offset
,
11130 GLuint _submit_count
) {
11134 sync_data_shm_id
= _sync_data_shm_id
;
11135 sync_data_shm_offset
= _sync_data_shm_offset
;
11136 submit_count
= _submit_count
;
11139 void* Set(void* cmd
,
11142 uint32_t _sync_data_shm_id
,
11143 uint32_t _sync_data_shm_offset
,
11144 GLuint _submit_count
) {
11145 static_cast<ValueType
*>(cmd
)->Init(_id
, _target
, _sync_data_shm_id
,
11146 _sync_data_shm_offset
, _submit_count
);
11147 return NextCmdAddress
<ValueType
>(cmd
);
11150 gpu::CommandHeader header
;
11153 uint32_t sync_data_shm_id
;
11154 uint32_t sync_data_shm_offset
;
11155 uint32_t submit_count
;
11158 static_assert(sizeof(QueryCounterEXT
) == 24,
11159 "size of QueryCounterEXT should be 24");
11160 static_assert(offsetof(QueryCounterEXT
, header
) == 0,
11161 "offset of QueryCounterEXT header should be 0");
11162 static_assert(offsetof(QueryCounterEXT
, id
) == 4,
11163 "offset of QueryCounterEXT id should be 4");
11164 static_assert(offsetof(QueryCounterEXT
, target
) == 8,
11165 "offset of QueryCounterEXT target should be 8");
11166 static_assert(offsetof(QueryCounterEXT
, sync_data_shm_id
) == 12,
11167 "offset of QueryCounterEXT sync_data_shm_id should be 12");
11168 static_assert(offsetof(QueryCounterEXT
, sync_data_shm_offset
) == 16,
11169 "offset of QueryCounterEXT sync_data_shm_offset should be 16");
11170 static_assert(offsetof(QueryCounterEXT
, submit_count
) == 20,
11171 "offset of QueryCounterEXT submit_count should be 20");
11173 struct BeginQueryEXT
{
11174 typedef BeginQueryEXT ValueType
;
11175 static const CommandId kCmdId
= kBeginQueryEXT
;
11176 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11177 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11179 static uint32_t ComputeSize() {
11180 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11183 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11185 void Init(GLenum _target
,
11187 uint32_t _sync_data_shm_id
,
11188 uint32_t _sync_data_shm_offset
) {
11192 sync_data_shm_id
= _sync_data_shm_id
;
11193 sync_data_shm_offset
= _sync_data_shm_offset
;
11196 void* Set(void* cmd
,
11199 uint32_t _sync_data_shm_id
,
11200 uint32_t _sync_data_shm_offset
) {
11201 static_cast<ValueType
*>(cmd
)
11202 ->Init(_target
, _id
, _sync_data_shm_id
, _sync_data_shm_offset
);
11203 return NextCmdAddress
<ValueType
>(cmd
);
11206 gpu::CommandHeader header
;
11209 uint32_t sync_data_shm_id
;
11210 uint32_t sync_data_shm_offset
;
11213 static_assert(sizeof(BeginQueryEXT
) == 20,
11214 "size of BeginQueryEXT should be 20");
11215 static_assert(offsetof(BeginQueryEXT
, header
) == 0,
11216 "offset of BeginQueryEXT header should be 0");
11217 static_assert(offsetof(BeginQueryEXT
, target
) == 4,
11218 "offset of BeginQueryEXT target should be 4");
11219 static_assert(offsetof(BeginQueryEXT
, id
) == 8,
11220 "offset of BeginQueryEXT id should be 8");
11221 static_assert(offsetof(BeginQueryEXT
, sync_data_shm_id
) == 12,
11222 "offset of BeginQueryEXT sync_data_shm_id should be 12");
11223 static_assert(offsetof(BeginQueryEXT
, sync_data_shm_offset
) == 16,
11224 "offset of BeginQueryEXT sync_data_shm_offset should be 16");
11226 struct BeginTransformFeedback
{
11227 typedef BeginTransformFeedback ValueType
;
11228 static const CommandId kCmdId
= kBeginTransformFeedback
;
11229 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11230 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11232 static uint32_t ComputeSize() {
11233 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11236 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11238 void Init(GLenum _primitivemode
) {
11240 primitivemode
= _primitivemode
;
11243 void* Set(void* cmd
, GLenum _primitivemode
) {
11244 static_cast<ValueType
*>(cmd
)->Init(_primitivemode
);
11245 return NextCmdAddress
<ValueType
>(cmd
);
11248 gpu::CommandHeader header
;
11249 uint32_t primitivemode
;
11252 static_assert(sizeof(BeginTransformFeedback
) == 8,
11253 "size of BeginTransformFeedback should be 8");
11254 static_assert(offsetof(BeginTransformFeedback
, header
) == 0,
11255 "offset of BeginTransformFeedback header should be 0");
11256 static_assert(offsetof(BeginTransformFeedback
, primitivemode
) == 4,
11257 "offset of BeginTransformFeedback primitivemode should be 4");
11259 struct EndQueryEXT
{
11260 typedef EndQueryEXT ValueType
;
11261 static const CommandId kCmdId
= kEndQueryEXT
;
11262 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11263 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11265 static uint32_t ComputeSize() {
11266 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11269 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11271 void Init(GLenum _target
, GLuint _submit_count
) {
11274 submit_count
= _submit_count
;
11277 void* Set(void* cmd
, GLenum _target
, GLuint _submit_count
) {
11278 static_cast<ValueType
*>(cmd
)->Init(_target
, _submit_count
);
11279 return NextCmdAddress
<ValueType
>(cmd
);
11282 gpu::CommandHeader header
;
11284 uint32_t submit_count
;
11287 static_assert(sizeof(EndQueryEXT
) == 12, "size of EndQueryEXT should be 12");
11288 static_assert(offsetof(EndQueryEXT
, header
) == 0,
11289 "offset of EndQueryEXT header should be 0");
11290 static_assert(offsetof(EndQueryEXT
, target
) == 4,
11291 "offset of EndQueryEXT target should be 4");
11292 static_assert(offsetof(EndQueryEXT
, submit_count
) == 8,
11293 "offset of EndQueryEXT submit_count should be 8");
11295 struct EndTransformFeedback
{
11296 typedef EndTransformFeedback ValueType
;
11297 static const CommandId kCmdId
= kEndTransformFeedback
;
11298 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11299 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11301 static uint32_t ComputeSize() {
11302 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11305 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11307 void Init() { SetHeader(); }
11309 void* Set(void* cmd
) {
11310 static_cast<ValueType
*>(cmd
)->Init();
11311 return NextCmdAddress
<ValueType
>(cmd
);
11314 gpu::CommandHeader header
;
11317 static_assert(sizeof(EndTransformFeedback
) == 4,
11318 "size of EndTransformFeedback should be 4");
11319 static_assert(offsetof(EndTransformFeedback
, header
) == 0,
11320 "offset of EndTransformFeedback header should be 0");
11322 struct InsertEventMarkerEXT
{
11323 typedef InsertEventMarkerEXT ValueType
;
11324 static const CommandId kCmdId
= kInsertEventMarkerEXT
;
11325 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11326 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11328 static uint32_t ComputeSize() {
11329 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11332 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11334 void Init(GLuint _bucket_id
) {
11336 bucket_id
= _bucket_id
;
11339 void* Set(void* cmd
, GLuint _bucket_id
) {
11340 static_cast<ValueType
*>(cmd
)->Init(_bucket_id
);
11341 return NextCmdAddress
<ValueType
>(cmd
);
11344 gpu::CommandHeader header
;
11345 uint32_t bucket_id
;
11348 static_assert(sizeof(InsertEventMarkerEXT
) == 8,
11349 "size of InsertEventMarkerEXT should be 8");
11350 static_assert(offsetof(InsertEventMarkerEXT
, header
) == 0,
11351 "offset of InsertEventMarkerEXT header should be 0");
11352 static_assert(offsetof(InsertEventMarkerEXT
, bucket_id
) == 4,
11353 "offset of InsertEventMarkerEXT bucket_id should be 4");
11355 struct PushGroupMarkerEXT
{
11356 typedef PushGroupMarkerEXT ValueType
;
11357 static const CommandId kCmdId
= kPushGroupMarkerEXT
;
11358 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11359 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11361 static uint32_t ComputeSize() {
11362 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11365 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11367 void Init(GLuint _bucket_id
) {
11369 bucket_id
= _bucket_id
;
11372 void* Set(void* cmd
, GLuint _bucket_id
) {
11373 static_cast<ValueType
*>(cmd
)->Init(_bucket_id
);
11374 return NextCmdAddress
<ValueType
>(cmd
);
11377 gpu::CommandHeader header
;
11378 uint32_t bucket_id
;
11381 static_assert(sizeof(PushGroupMarkerEXT
) == 8,
11382 "size of PushGroupMarkerEXT should be 8");
11383 static_assert(offsetof(PushGroupMarkerEXT
, header
) == 0,
11384 "offset of PushGroupMarkerEXT header should be 0");
11385 static_assert(offsetof(PushGroupMarkerEXT
, bucket_id
) == 4,
11386 "offset of PushGroupMarkerEXT bucket_id should be 4");
11388 struct PopGroupMarkerEXT
{
11389 typedef PopGroupMarkerEXT ValueType
;
11390 static const CommandId kCmdId
= kPopGroupMarkerEXT
;
11391 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11392 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11394 static uint32_t ComputeSize() {
11395 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11398 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11400 void Init() { SetHeader(); }
11402 void* Set(void* cmd
) {
11403 static_cast<ValueType
*>(cmd
)->Init();
11404 return NextCmdAddress
<ValueType
>(cmd
);
11407 gpu::CommandHeader header
;
11410 static_assert(sizeof(PopGroupMarkerEXT
) == 4,
11411 "size of PopGroupMarkerEXT should be 4");
11412 static_assert(offsetof(PopGroupMarkerEXT
, header
) == 0,
11413 "offset of PopGroupMarkerEXT header should be 0");
11415 struct GenVertexArraysOESImmediate
{
11416 typedef GenVertexArraysOESImmediate ValueType
;
11417 static const CommandId kCmdId
= kGenVertexArraysOESImmediate
;
11418 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
11419 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11421 static uint32_t ComputeDataSize(GLsizei n
) {
11422 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
11425 static uint32_t ComputeSize(GLsizei n
) {
11426 return static_cast<uint32_t>(sizeof(ValueType
) +
11427 ComputeDataSize(n
)); // NOLINT
11430 void SetHeader(GLsizei n
) {
11431 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
11434 void Init(GLsizei _n
, GLuint
* _arrays
) {
11437 memcpy(ImmediateDataAddress(this), _arrays
, ComputeDataSize(_n
));
11440 void* Set(void* cmd
, GLsizei _n
, GLuint
* _arrays
) {
11441 static_cast<ValueType
*>(cmd
)->Init(_n
, _arrays
);
11442 const uint32_t size
= ComputeSize(_n
);
11443 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
11446 gpu::CommandHeader header
;
11450 static_assert(sizeof(GenVertexArraysOESImmediate
) == 8,
11451 "size of GenVertexArraysOESImmediate should be 8");
11452 static_assert(offsetof(GenVertexArraysOESImmediate
, header
) == 0,
11453 "offset of GenVertexArraysOESImmediate header should be 0");
11454 static_assert(offsetof(GenVertexArraysOESImmediate
, n
) == 4,
11455 "offset of GenVertexArraysOESImmediate n should be 4");
11457 struct DeleteVertexArraysOESImmediate
{
11458 typedef DeleteVertexArraysOESImmediate ValueType
;
11459 static const CommandId kCmdId
= kDeleteVertexArraysOESImmediate
;
11460 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
11461 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11463 static uint32_t ComputeDataSize(GLsizei n
) {
11464 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
11467 static uint32_t ComputeSize(GLsizei n
) {
11468 return static_cast<uint32_t>(sizeof(ValueType
) +
11469 ComputeDataSize(n
)); // NOLINT
11472 void SetHeader(GLsizei n
) {
11473 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
11476 void Init(GLsizei _n
, const GLuint
* _arrays
) {
11479 memcpy(ImmediateDataAddress(this), _arrays
, ComputeDataSize(_n
));
11482 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _arrays
) {
11483 static_cast<ValueType
*>(cmd
)->Init(_n
, _arrays
);
11484 const uint32_t size
= ComputeSize(_n
);
11485 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
11488 gpu::CommandHeader header
;
11492 static_assert(sizeof(DeleteVertexArraysOESImmediate
) == 8,
11493 "size of DeleteVertexArraysOESImmediate should be 8");
11494 static_assert(offsetof(DeleteVertexArraysOESImmediate
, header
) == 0,
11495 "offset of DeleteVertexArraysOESImmediate header should be 0");
11496 static_assert(offsetof(DeleteVertexArraysOESImmediate
, n
) == 4,
11497 "offset of DeleteVertexArraysOESImmediate n should be 4");
11499 struct IsVertexArrayOES
{
11500 typedef IsVertexArrayOES ValueType
;
11501 static const CommandId kCmdId
= kIsVertexArrayOES
;
11502 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11503 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11505 typedef uint32_t Result
;
11507 static uint32_t ComputeSize() {
11508 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11511 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11513 void Init(GLuint _array
,
11514 uint32_t _result_shm_id
,
11515 uint32_t _result_shm_offset
) {
11518 result_shm_id
= _result_shm_id
;
11519 result_shm_offset
= _result_shm_offset
;
11522 void* Set(void* cmd
,
11524 uint32_t _result_shm_id
,
11525 uint32_t _result_shm_offset
) {
11526 static_cast<ValueType
*>(cmd
)
11527 ->Init(_array
, _result_shm_id
, _result_shm_offset
);
11528 return NextCmdAddress
<ValueType
>(cmd
);
11531 gpu::CommandHeader header
;
11533 uint32_t result_shm_id
;
11534 uint32_t result_shm_offset
;
11537 static_assert(sizeof(IsVertexArrayOES
) == 16,
11538 "size of IsVertexArrayOES should be 16");
11539 static_assert(offsetof(IsVertexArrayOES
, header
) == 0,
11540 "offset of IsVertexArrayOES header should be 0");
11541 static_assert(offsetof(IsVertexArrayOES
, array
) == 4,
11542 "offset of IsVertexArrayOES array should be 4");
11543 static_assert(offsetof(IsVertexArrayOES
, result_shm_id
) == 8,
11544 "offset of IsVertexArrayOES result_shm_id should be 8");
11545 static_assert(offsetof(IsVertexArrayOES
, result_shm_offset
) == 12,
11546 "offset of IsVertexArrayOES result_shm_offset should be 12");
11548 struct BindVertexArrayOES
{
11549 typedef BindVertexArrayOES ValueType
;
11550 static const CommandId kCmdId
= kBindVertexArrayOES
;
11551 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11552 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11554 static uint32_t ComputeSize() {
11555 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11558 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11560 void Init(GLuint _array
) {
11565 void* Set(void* cmd
, GLuint _array
) {
11566 static_cast<ValueType
*>(cmd
)->Init(_array
);
11567 return NextCmdAddress
<ValueType
>(cmd
);
11570 gpu::CommandHeader header
;
11574 static_assert(sizeof(BindVertexArrayOES
) == 8,
11575 "size of BindVertexArrayOES should be 8");
11576 static_assert(offsetof(BindVertexArrayOES
, header
) == 0,
11577 "offset of BindVertexArrayOES header should be 0");
11578 static_assert(offsetof(BindVertexArrayOES
, array
) == 4,
11579 "offset of BindVertexArrayOES array should be 4");
11581 struct SwapBuffers
{
11582 typedef SwapBuffers ValueType
;
11583 static const CommandId kCmdId
= kSwapBuffers
;
11584 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11585 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
11587 static uint32_t ComputeSize() {
11588 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11591 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11593 void Init() { SetHeader(); }
11595 void* Set(void* cmd
) {
11596 static_cast<ValueType
*>(cmd
)->Init();
11597 return NextCmdAddress
<ValueType
>(cmd
);
11600 gpu::CommandHeader header
;
11603 static_assert(sizeof(SwapBuffers
) == 4, "size of SwapBuffers should be 4");
11604 static_assert(offsetof(SwapBuffers
, header
) == 0,
11605 "offset of SwapBuffers header should be 0");
11607 struct GetMaxValueInBufferCHROMIUM
{
11608 typedef GetMaxValueInBufferCHROMIUM ValueType
;
11609 static const CommandId kCmdId
= kGetMaxValueInBufferCHROMIUM
;
11610 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11611 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11613 typedef GLuint Result
;
11615 static uint32_t ComputeSize() {
11616 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11619 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11621 void Init(GLuint _buffer_id
,
11625 uint32_t _result_shm_id
,
11626 uint32_t _result_shm_offset
) {
11628 buffer_id
= _buffer_id
;
11632 result_shm_id
= _result_shm_id
;
11633 result_shm_offset
= _result_shm_offset
;
11636 void* Set(void* cmd
,
11641 uint32_t _result_shm_id
,
11642 uint32_t _result_shm_offset
) {
11643 static_cast<ValueType
*>(cmd
)->Init(_buffer_id
, _count
, _type
, _offset
,
11644 _result_shm_id
, _result_shm_offset
);
11645 return NextCmdAddress
<ValueType
>(cmd
);
11648 gpu::CommandHeader header
;
11649 uint32_t buffer_id
;
11653 uint32_t result_shm_id
;
11654 uint32_t result_shm_offset
;
11657 static_assert(sizeof(GetMaxValueInBufferCHROMIUM
) == 28,
11658 "size of GetMaxValueInBufferCHROMIUM should be 28");
11659 static_assert(offsetof(GetMaxValueInBufferCHROMIUM
, header
) == 0,
11660 "offset of GetMaxValueInBufferCHROMIUM header should be 0");
11661 static_assert(offsetof(GetMaxValueInBufferCHROMIUM
, buffer_id
) == 4,
11662 "offset of GetMaxValueInBufferCHROMIUM buffer_id should be 4");
11663 static_assert(offsetof(GetMaxValueInBufferCHROMIUM
, count
) == 8,
11664 "offset of GetMaxValueInBufferCHROMIUM count should be 8");
11665 static_assert(offsetof(GetMaxValueInBufferCHROMIUM
, type
) == 12,
11666 "offset of GetMaxValueInBufferCHROMIUM type should be 12");
11667 static_assert(offsetof(GetMaxValueInBufferCHROMIUM
, offset
) == 16,
11668 "offset of GetMaxValueInBufferCHROMIUM offset should be 16");
11670 offsetof(GetMaxValueInBufferCHROMIUM
, result_shm_id
) == 20,
11671 "offset of GetMaxValueInBufferCHROMIUM result_shm_id should be 20");
11673 offsetof(GetMaxValueInBufferCHROMIUM
, result_shm_offset
) == 24,
11674 "offset of GetMaxValueInBufferCHROMIUM result_shm_offset should be 24");
11676 struct EnableFeatureCHROMIUM
{
11677 typedef EnableFeatureCHROMIUM ValueType
;
11678 static const CommandId kCmdId
= kEnableFeatureCHROMIUM
;
11679 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11680 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11682 typedef GLint Result
;
11684 static uint32_t ComputeSize() {
11685 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11688 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11690 void Init(GLuint _bucket_id
,
11691 uint32_t _result_shm_id
,
11692 uint32_t _result_shm_offset
) {
11694 bucket_id
= _bucket_id
;
11695 result_shm_id
= _result_shm_id
;
11696 result_shm_offset
= _result_shm_offset
;
11699 void* Set(void* cmd
,
11701 uint32_t _result_shm_id
,
11702 uint32_t _result_shm_offset
) {
11703 static_cast<ValueType
*>(cmd
)
11704 ->Init(_bucket_id
, _result_shm_id
, _result_shm_offset
);
11705 return NextCmdAddress
<ValueType
>(cmd
);
11708 gpu::CommandHeader header
;
11709 uint32_t bucket_id
;
11710 uint32_t result_shm_id
;
11711 uint32_t result_shm_offset
;
11714 static_assert(sizeof(EnableFeatureCHROMIUM
) == 16,
11715 "size of EnableFeatureCHROMIUM should be 16");
11716 static_assert(offsetof(EnableFeatureCHROMIUM
, header
) == 0,
11717 "offset of EnableFeatureCHROMIUM header should be 0");
11718 static_assert(offsetof(EnableFeatureCHROMIUM
, bucket_id
) == 4,
11719 "offset of EnableFeatureCHROMIUM bucket_id should be 4");
11720 static_assert(offsetof(EnableFeatureCHROMIUM
, result_shm_id
) == 8,
11721 "offset of EnableFeatureCHROMIUM result_shm_id should be 8");
11722 static_assert(offsetof(EnableFeatureCHROMIUM
, result_shm_offset
) == 12,
11723 "offset of EnableFeatureCHROMIUM result_shm_offset should be 12");
11725 struct MapBufferRange
{
11726 typedef MapBufferRange ValueType
;
11727 static const CommandId kCmdId
= kMapBufferRange
;
11728 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11729 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
11731 typedef uint32_t Result
;
11733 static uint32_t ComputeSize() {
11734 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11737 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11739 void Init(GLenum _target
,
11742 GLbitfield _access
,
11743 uint32_t _data_shm_id
,
11744 uint32_t _data_shm_offset
,
11745 uint32_t _result_shm_id
,
11746 uint32_t _result_shm_offset
) {
11752 data_shm_id
= _data_shm_id
;
11753 data_shm_offset
= _data_shm_offset
;
11754 result_shm_id
= _result_shm_id
;
11755 result_shm_offset
= _result_shm_offset
;
11758 void* Set(void* cmd
,
11762 GLbitfield _access
,
11763 uint32_t _data_shm_id
,
11764 uint32_t _data_shm_offset
,
11765 uint32_t _result_shm_id
,
11766 uint32_t _result_shm_offset
) {
11767 static_cast<ValueType
*>(cmd
)->Init(_target
, _offset
, _size
, _access
,
11768 _data_shm_id
, _data_shm_offset
,
11769 _result_shm_id
, _result_shm_offset
);
11770 return NextCmdAddress
<ValueType
>(cmd
);
11773 gpu::CommandHeader header
;
11778 uint32_t data_shm_id
;
11779 uint32_t data_shm_offset
;
11780 uint32_t result_shm_id
;
11781 uint32_t result_shm_offset
;
11784 static_assert(sizeof(MapBufferRange
) == 36,
11785 "size of MapBufferRange should be 36");
11786 static_assert(offsetof(MapBufferRange
, header
) == 0,
11787 "offset of MapBufferRange header should be 0");
11788 static_assert(offsetof(MapBufferRange
, target
) == 4,
11789 "offset of MapBufferRange target should be 4");
11790 static_assert(offsetof(MapBufferRange
, offset
) == 8,
11791 "offset of MapBufferRange offset should be 8");
11792 static_assert(offsetof(MapBufferRange
, size
) == 12,
11793 "offset of MapBufferRange size should be 12");
11794 static_assert(offsetof(MapBufferRange
, access
) == 16,
11795 "offset of MapBufferRange access should be 16");
11796 static_assert(offsetof(MapBufferRange
, data_shm_id
) == 20,
11797 "offset of MapBufferRange data_shm_id should be 20");
11798 static_assert(offsetof(MapBufferRange
, data_shm_offset
) == 24,
11799 "offset of MapBufferRange data_shm_offset should be 24");
11800 static_assert(offsetof(MapBufferRange
, result_shm_id
) == 28,
11801 "offset of MapBufferRange result_shm_id should be 28");
11802 static_assert(offsetof(MapBufferRange
, result_shm_offset
) == 32,
11803 "offset of MapBufferRange result_shm_offset should be 32");
11805 struct UnmapBuffer
{
11806 typedef UnmapBuffer ValueType
;
11807 static const CommandId kCmdId
= kUnmapBuffer
;
11808 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11809 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
11811 static uint32_t ComputeSize() {
11812 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11815 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11817 void Init(GLenum _target
) {
11822 void* Set(void* cmd
, GLenum _target
) {
11823 static_cast<ValueType
*>(cmd
)->Init(_target
);
11824 return NextCmdAddress
<ValueType
>(cmd
);
11827 gpu::CommandHeader header
;
11831 static_assert(sizeof(UnmapBuffer
) == 8, "size of UnmapBuffer should be 8");
11832 static_assert(offsetof(UnmapBuffer
, header
) == 0,
11833 "offset of UnmapBuffer header should be 0");
11834 static_assert(offsetof(UnmapBuffer
, target
) == 4,
11835 "offset of UnmapBuffer target should be 4");
11837 struct ResizeCHROMIUM
{
11838 typedef ResizeCHROMIUM ValueType
;
11839 static const CommandId kCmdId
= kResizeCHROMIUM
;
11840 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11841 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
11843 static uint32_t ComputeSize() {
11844 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11847 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11849 void Init(GLuint _width
, GLuint _height
, GLfloat _scale_factor
) {
11853 scale_factor
= _scale_factor
;
11856 void* Set(void* cmd
, GLuint _width
, GLuint _height
, GLfloat _scale_factor
) {
11857 static_cast<ValueType
*>(cmd
)->Init(_width
, _height
, _scale_factor
);
11858 return NextCmdAddress
<ValueType
>(cmd
);
11861 gpu::CommandHeader header
;
11864 float scale_factor
;
11867 static_assert(sizeof(ResizeCHROMIUM
) == 16,
11868 "size of ResizeCHROMIUM should be 16");
11869 static_assert(offsetof(ResizeCHROMIUM
, header
) == 0,
11870 "offset of ResizeCHROMIUM header should be 0");
11871 static_assert(offsetof(ResizeCHROMIUM
, width
) == 4,
11872 "offset of ResizeCHROMIUM width should be 4");
11873 static_assert(offsetof(ResizeCHROMIUM
, height
) == 8,
11874 "offset of ResizeCHROMIUM height should be 8");
11875 static_assert(offsetof(ResizeCHROMIUM
, scale_factor
) == 12,
11876 "offset of ResizeCHROMIUM scale_factor should be 12");
11878 struct GetRequestableExtensionsCHROMIUM
{
11879 typedef GetRequestableExtensionsCHROMIUM ValueType
;
11880 static const CommandId kCmdId
= kGetRequestableExtensionsCHROMIUM
;
11881 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11882 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11884 static uint32_t ComputeSize() {
11885 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11888 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11890 void Init(uint32_t _bucket_id
) {
11892 bucket_id
= _bucket_id
;
11895 void* Set(void* cmd
, uint32_t _bucket_id
) {
11896 static_cast<ValueType
*>(cmd
)->Init(_bucket_id
);
11897 return NextCmdAddress
<ValueType
>(cmd
);
11900 gpu::CommandHeader header
;
11901 uint32_t bucket_id
;
11904 static_assert(sizeof(GetRequestableExtensionsCHROMIUM
) == 8,
11905 "size of GetRequestableExtensionsCHROMIUM should be 8");
11906 static_assert(offsetof(GetRequestableExtensionsCHROMIUM
, header
) == 0,
11907 "offset of GetRequestableExtensionsCHROMIUM header should be 0");
11909 offsetof(GetRequestableExtensionsCHROMIUM
, bucket_id
) == 4,
11910 "offset of GetRequestableExtensionsCHROMIUM bucket_id should be 4");
11912 struct RequestExtensionCHROMIUM
{
11913 typedef RequestExtensionCHROMIUM ValueType
;
11914 static const CommandId kCmdId
= kRequestExtensionCHROMIUM
;
11915 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11916 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11918 static uint32_t ComputeSize() {
11919 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11922 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11924 void Init(uint32_t _bucket_id
) {
11926 bucket_id
= _bucket_id
;
11929 void* Set(void* cmd
, uint32_t _bucket_id
) {
11930 static_cast<ValueType
*>(cmd
)->Init(_bucket_id
);
11931 return NextCmdAddress
<ValueType
>(cmd
);
11934 gpu::CommandHeader header
;
11935 uint32_t bucket_id
;
11938 static_assert(sizeof(RequestExtensionCHROMIUM
) == 8,
11939 "size of RequestExtensionCHROMIUM should be 8");
11940 static_assert(offsetof(RequestExtensionCHROMIUM
, header
) == 0,
11941 "offset of RequestExtensionCHROMIUM header should be 0");
11942 static_assert(offsetof(RequestExtensionCHROMIUM
, bucket_id
) == 4,
11943 "offset of RequestExtensionCHROMIUM bucket_id should be 4");
11945 struct GetProgramInfoCHROMIUM
{
11946 typedef GetProgramInfoCHROMIUM ValueType
;
11947 static const CommandId kCmdId
= kGetProgramInfoCHROMIUM
;
11948 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
11949 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
11952 uint32_t link_status
;
11953 uint32_t num_attribs
;
11954 uint32_t num_uniforms
;
11957 static uint32_t ComputeSize() {
11958 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
11961 void SetHeader() { header
.SetCmd
<ValueType
>(); }
11963 void Init(GLuint _program
, uint32_t _bucket_id
) {
11965 program
= _program
;
11966 bucket_id
= _bucket_id
;
11969 void* Set(void* cmd
, GLuint _program
, uint32_t _bucket_id
) {
11970 static_cast<ValueType
*>(cmd
)->Init(_program
, _bucket_id
);
11971 return NextCmdAddress
<ValueType
>(cmd
);
11974 gpu::CommandHeader header
;
11976 uint32_t bucket_id
;
11979 static_assert(sizeof(GetProgramInfoCHROMIUM
) == 12,
11980 "size of GetProgramInfoCHROMIUM should be 12");
11981 static_assert(offsetof(GetProgramInfoCHROMIUM
, header
) == 0,
11982 "offset of GetProgramInfoCHROMIUM header should be 0");
11983 static_assert(offsetof(GetProgramInfoCHROMIUM
, program
) == 4,
11984 "offset of GetProgramInfoCHROMIUM program should be 4");
11985 static_assert(offsetof(GetProgramInfoCHROMIUM
, bucket_id
) == 8,
11986 "offset of GetProgramInfoCHROMIUM bucket_id should be 8");
11987 static_assert(offsetof(GetProgramInfoCHROMIUM::Result
, link_status
) == 0,
11988 "offset of GetProgramInfoCHROMIUM Result link_status should be "
11990 static_assert(offsetof(GetProgramInfoCHROMIUM::Result
, num_attribs
) == 4,
11991 "offset of GetProgramInfoCHROMIUM Result num_attribs should be "
11993 static_assert(offsetof(GetProgramInfoCHROMIUM::Result
, num_uniforms
) == 8,
11994 "offset of GetProgramInfoCHROMIUM Result num_uniforms should be "
11997 struct GetUniformBlocksCHROMIUM
{
11998 typedef GetUniformBlocksCHROMIUM ValueType
;
11999 static const CommandId kCmdId
= kGetUniformBlocksCHROMIUM
;
12000 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12001 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12003 typedef uint32_t Result
;
12005 static uint32_t ComputeSize() {
12006 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12009 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12011 void Init(GLuint _program
, uint32_t _bucket_id
) {
12013 program
= _program
;
12014 bucket_id
= _bucket_id
;
12017 void* Set(void* cmd
, GLuint _program
, uint32_t _bucket_id
) {
12018 static_cast<ValueType
*>(cmd
)->Init(_program
, _bucket_id
);
12019 return NextCmdAddress
<ValueType
>(cmd
);
12022 gpu::CommandHeader header
;
12024 uint32_t bucket_id
;
12027 static_assert(sizeof(GetUniformBlocksCHROMIUM
) == 12,
12028 "size of GetUniformBlocksCHROMIUM should be 12");
12029 static_assert(offsetof(GetUniformBlocksCHROMIUM
, header
) == 0,
12030 "offset of GetUniformBlocksCHROMIUM header should be 0");
12031 static_assert(offsetof(GetUniformBlocksCHROMIUM
, program
) == 4,
12032 "offset of GetUniformBlocksCHROMIUM program should be 4");
12033 static_assert(offsetof(GetUniformBlocksCHROMIUM
, bucket_id
) == 8,
12034 "offset of GetUniformBlocksCHROMIUM bucket_id should be 8");
12036 struct GetTransformFeedbackVaryingsCHROMIUM
{
12037 typedef GetTransformFeedbackVaryingsCHROMIUM ValueType
;
12038 static const CommandId kCmdId
= kGetTransformFeedbackVaryingsCHROMIUM
;
12039 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12040 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12042 typedef uint32_t Result
;
12044 static uint32_t ComputeSize() {
12045 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12048 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12050 void Init(GLuint _program
, uint32_t _bucket_id
) {
12052 program
= _program
;
12053 bucket_id
= _bucket_id
;
12056 void* Set(void* cmd
, GLuint _program
, uint32_t _bucket_id
) {
12057 static_cast<ValueType
*>(cmd
)->Init(_program
, _bucket_id
);
12058 return NextCmdAddress
<ValueType
>(cmd
);
12061 gpu::CommandHeader header
;
12063 uint32_t bucket_id
;
12066 static_assert(sizeof(GetTransformFeedbackVaryingsCHROMIUM
) == 12,
12067 "size of GetTransformFeedbackVaryingsCHROMIUM should be 12");
12069 offsetof(GetTransformFeedbackVaryingsCHROMIUM
, header
) == 0,
12070 "offset of GetTransformFeedbackVaryingsCHROMIUM header should be 0");
12072 offsetof(GetTransformFeedbackVaryingsCHROMIUM
, program
) == 4,
12073 "offset of GetTransformFeedbackVaryingsCHROMIUM program should be 4");
12075 offsetof(GetTransformFeedbackVaryingsCHROMIUM
, bucket_id
) == 8,
12076 "offset of GetTransformFeedbackVaryingsCHROMIUM bucket_id should be 8");
12078 struct GetUniformsES3CHROMIUM
{
12079 typedef GetUniformsES3CHROMIUM ValueType
;
12080 static const CommandId kCmdId
= kGetUniformsES3CHROMIUM
;
12081 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12082 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12084 typedef uint32_t Result
;
12086 static uint32_t ComputeSize() {
12087 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12090 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12092 void Init(GLuint _program
, uint32_t _bucket_id
) {
12094 program
= _program
;
12095 bucket_id
= _bucket_id
;
12098 void* Set(void* cmd
, GLuint _program
, uint32_t _bucket_id
) {
12099 static_cast<ValueType
*>(cmd
)->Init(_program
, _bucket_id
);
12100 return NextCmdAddress
<ValueType
>(cmd
);
12103 gpu::CommandHeader header
;
12105 uint32_t bucket_id
;
12108 static_assert(sizeof(GetUniformsES3CHROMIUM
) == 12,
12109 "size of GetUniformsES3CHROMIUM should be 12");
12110 static_assert(offsetof(GetUniformsES3CHROMIUM
, header
) == 0,
12111 "offset of GetUniformsES3CHROMIUM header should be 0");
12112 static_assert(offsetof(GetUniformsES3CHROMIUM
, program
) == 4,
12113 "offset of GetUniformsES3CHROMIUM program should be 4");
12114 static_assert(offsetof(GetUniformsES3CHROMIUM
, bucket_id
) == 8,
12115 "offset of GetUniformsES3CHROMIUM bucket_id should be 8");
12117 struct GetTranslatedShaderSourceANGLE
{
12118 typedef GetTranslatedShaderSourceANGLE ValueType
;
12119 static const CommandId kCmdId
= kGetTranslatedShaderSourceANGLE
;
12120 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12121 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12123 static uint32_t ComputeSize() {
12124 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12127 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12129 void Init(GLuint _shader
, uint32_t _bucket_id
) {
12132 bucket_id
= _bucket_id
;
12135 void* Set(void* cmd
, GLuint _shader
, uint32_t _bucket_id
) {
12136 static_cast<ValueType
*>(cmd
)->Init(_shader
, _bucket_id
);
12137 return NextCmdAddress
<ValueType
>(cmd
);
12140 gpu::CommandHeader header
;
12142 uint32_t bucket_id
;
12145 static_assert(sizeof(GetTranslatedShaderSourceANGLE
) == 12,
12146 "size of GetTranslatedShaderSourceANGLE should be 12");
12147 static_assert(offsetof(GetTranslatedShaderSourceANGLE
, header
) == 0,
12148 "offset of GetTranslatedShaderSourceANGLE header should be 0");
12149 static_assert(offsetof(GetTranslatedShaderSourceANGLE
, shader
) == 4,
12150 "offset of GetTranslatedShaderSourceANGLE shader should be 4");
12151 static_assert(offsetof(GetTranslatedShaderSourceANGLE
, bucket_id
) == 8,
12152 "offset of GetTranslatedShaderSourceANGLE bucket_id should be 8");
12154 struct PostSubBufferCHROMIUM
{
12155 typedef PostSubBufferCHROMIUM ValueType
;
12156 static const CommandId kCmdId
= kPostSubBufferCHROMIUM
;
12157 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12158 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12160 static uint32_t ComputeSize() {
12161 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12164 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12166 void Init(GLint _x
, GLint _y
, GLint _width
, GLint _height
) {
12174 void* Set(void* cmd
, GLint _x
, GLint _y
, GLint _width
, GLint _height
) {
12175 static_cast<ValueType
*>(cmd
)->Init(_x
, _y
, _width
, _height
);
12176 return NextCmdAddress
<ValueType
>(cmd
);
12179 gpu::CommandHeader header
;
12186 static_assert(sizeof(PostSubBufferCHROMIUM
) == 20,
12187 "size of PostSubBufferCHROMIUM should be 20");
12188 static_assert(offsetof(PostSubBufferCHROMIUM
, header
) == 0,
12189 "offset of PostSubBufferCHROMIUM header should be 0");
12190 static_assert(offsetof(PostSubBufferCHROMIUM
, x
) == 4,
12191 "offset of PostSubBufferCHROMIUM x should be 4");
12192 static_assert(offsetof(PostSubBufferCHROMIUM
, y
) == 8,
12193 "offset of PostSubBufferCHROMIUM y should be 8");
12194 static_assert(offsetof(PostSubBufferCHROMIUM
, width
) == 12,
12195 "offset of PostSubBufferCHROMIUM width should be 12");
12196 static_assert(offsetof(PostSubBufferCHROMIUM
, height
) == 16,
12197 "offset of PostSubBufferCHROMIUM height should be 16");
12199 struct TexImageIOSurface2DCHROMIUM
{
12200 typedef TexImageIOSurface2DCHROMIUM ValueType
;
12201 static const CommandId kCmdId
= kTexImageIOSurface2DCHROMIUM
;
12202 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12203 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
12205 static uint32_t ComputeSize() {
12206 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12209 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12211 void Init(GLenum _target
,
12214 GLuint _ioSurfaceId
,
12220 ioSurfaceId
= _ioSurfaceId
;
12224 void* Set(void* cmd
,
12228 GLuint _ioSurfaceId
,
12230 static_cast<ValueType
*>(cmd
)
12231 ->Init(_target
, _width
, _height
, _ioSurfaceId
, _plane
);
12232 return NextCmdAddress
<ValueType
>(cmd
);
12235 gpu::CommandHeader header
;
12239 uint32_t ioSurfaceId
;
12243 static_assert(sizeof(TexImageIOSurface2DCHROMIUM
) == 24,
12244 "size of TexImageIOSurface2DCHROMIUM should be 24");
12245 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, header
) == 0,
12246 "offset of TexImageIOSurface2DCHROMIUM header should be 0");
12247 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, target
) == 4,
12248 "offset of TexImageIOSurface2DCHROMIUM target should be 4");
12249 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, width
) == 8,
12250 "offset of TexImageIOSurface2DCHROMIUM width should be 8");
12251 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, height
) == 12,
12252 "offset of TexImageIOSurface2DCHROMIUM height should be 12");
12253 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, ioSurfaceId
) == 16,
12254 "offset of TexImageIOSurface2DCHROMIUM ioSurfaceId should be 16");
12255 static_assert(offsetof(TexImageIOSurface2DCHROMIUM
, plane
) == 20,
12256 "offset of TexImageIOSurface2DCHROMIUM plane should be 20");
12258 struct CopyTextureCHROMIUM
{
12259 typedef CopyTextureCHROMIUM ValueType
;
12260 static const CommandId kCmdId
= kCopyTextureCHROMIUM
;
12261 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12262 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
12264 static uint32_t ComputeSize() {
12265 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12268 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12270 void Init(GLenum _target
,
12273 GLint _internalformat
,
12275 GLboolean _unpack_flip_y
,
12276 GLboolean _unpack_premultiply_alpha
,
12277 GLboolean _unpack_unmultiply_alpha
) {
12280 source_id
= _source_id
;
12281 dest_id
= _dest_id
;
12282 internalformat
= _internalformat
;
12283 dest_type
= _dest_type
;
12284 unpack_flip_y
= _unpack_flip_y
;
12285 unpack_premultiply_alpha
= _unpack_premultiply_alpha
;
12286 unpack_unmultiply_alpha
= _unpack_unmultiply_alpha
;
12289 void* Set(void* cmd
,
12293 GLint _internalformat
,
12295 GLboolean _unpack_flip_y
,
12296 GLboolean _unpack_premultiply_alpha
,
12297 GLboolean _unpack_unmultiply_alpha
) {
12298 static_cast<ValueType
*>(cmd
)->Init(
12299 _target
, _source_id
, _dest_id
, _internalformat
, _dest_type
,
12300 _unpack_flip_y
, _unpack_premultiply_alpha
, _unpack_unmultiply_alpha
);
12301 return NextCmdAddress
<ValueType
>(cmd
);
12304 gpu::CommandHeader header
;
12306 uint32_t source_id
;
12308 int32_t internalformat
;
12309 uint32_t dest_type
;
12310 uint32_t unpack_flip_y
;
12311 uint32_t unpack_premultiply_alpha
;
12312 uint32_t unpack_unmultiply_alpha
;
12315 static_assert(sizeof(CopyTextureCHROMIUM
) == 36,
12316 "size of CopyTextureCHROMIUM should be 36");
12317 static_assert(offsetof(CopyTextureCHROMIUM
, header
) == 0,
12318 "offset of CopyTextureCHROMIUM header should be 0");
12319 static_assert(offsetof(CopyTextureCHROMIUM
, target
) == 4,
12320 "offset of CopyTextureCHROMIUM target should be 4");
12321 static_assert(offsetof(CopyTextureCHROMIUM
, source_id
) == 8,
12322 "offset of CopyTextureCHROMIUM source_id should be 8");
12323 static_assert(offsetof(CopyTextureCHROMIUM
, dest_id
) == 12,
12324 "offset of CopyTextureCHROMIUM dest_id should be 12");
12325 static_assert(offsetof(CopyTextureCHROMIUM
, internalformat
) == 16,
12326 "offset of CopyTextureCHROMIUM internalformat should be 16");
12327 static_assert(offsetof(CopyTextureCHROMIUM
, dest_type
) == 20,
12328 "offset of CopyTextureCHROMIUM dest_type should be 20");
12329 static_assert(offsetof(CopyTextureCHROMIUM
, unpack_flip_y
) == 24,
12330 "offset of CopyTextureCHROMIUM unpack_flip_y should be 24");
12332 offsetof(CopyTextureCHROMIUM
, unpack_premultiply_alpha
) == 28,
12333 "offset of CopyTextureCHROMIUM unpack_premultiply_alpha should be 28");
12335 offsetof(CopyTextureCHROMIUM
, unpack_unmultiply_alpha
) == 32,
12336 "offset of CopyTextureCHROMIUM unpack_unmultiply_alpha should be 32");
12338 struct CopySubTextureCHROMIUM
{
12339 typedef CopySubTextureCHROMIUM ValueType
;
12340 static const CommandId kCmdId
= kCopySubTextureCHROMIUM
;
12341 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12342 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
12344 static uint32_t ComputeSize() {
12345 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12348 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12350 void Init(GLenum _target
,
12359 GLboolean _unpack_flip_y
,
12360 GLboolean _unpack_premultiply_alpha
,
12361 GLboolean _unpack_unmultiply_alpha
) {
12364 source_id
= _source_id
;
12365 dest_id
= _dest_id
;
12366 xoffset
= _xoffset
;
12367 yoffset
= _yoffset
;
12372 unpack_flip_y
= _unpack_flip_y
;
12373 unpack_premultiply_alpha
= _unpack_premultiply_alpha
;
12374 unpack_unmultiply_alpha
= _unpack_unmultiply_alpha
;
12377 void* Set(void* cmd
,
12387 GLboolean _unpack_flip_y
,
12388 GLboolean _unpack_premultiply_alpha
,
12389 GLboolean _unpack_unmultiply_alpha
) {
12390 static_cast<ValueType
*>(cmd
)
12391 ->Init(_target
, _source_id
, _dest_id
, _xoffset
, _yoffset
, _x
, _y
,
12392 _width
, _height
, _unpack_flip_y
, _unpack_premultiply_alpha
,
12393 _unpack_unmultiply_alpha
);
12394 return NextCmdAddress
<ValueType
>(cmd
);
12397 gpu::CommandHeader header
;
12399 uint32_t source_id
;
12407 uint32_t unpack_flip_y
;
12408 uint32_t unpack_premultiply_alpha
;
12409 uint32_t unpack_unmultiply_alpha
;
12412 static_assert(sizeof(CopySubTextureCHROMIUM
) == 52,
12413 "size of CopySubTextureCHROMIUM should be 52");
12414 static_assert(offsetof(CopySubTextureCHROMIUM
, header
) == 0,
12415 "offset of CopySubTextureCHROMIUM header should be 0");
12416 static_assert(offsetof(CopySubTextureCHROMIUM
, target
) == 4,
12417 "offset of CopySubTextureCHROMIUM target should be 4");
12418 static_assert(offsetof(CopySubTextureCHROMIUM
, source_id
) == 8,
12419 "offset of CopySubTextureCHROMIUM source_id should be 8");
12420 static_assert(offsetof(CopySubTextureCHROMIUM
, dest_id
) == 12,
12421 "offset of CopySubTextureCHROMIUM dest_id should be 12");
12422 static_assert(offsetof(CopySubTextureCHROMIUM
, xoffset
) == 16,
12423 "offset of CopySubTextureCHROMIUM xoffset should be 16");
12424 static_assert(offsetof(CopySubTextureCHROMIUM
, yoffset
) == 20,
12425 "offset of CopySubTextureCHROMIUM yoffset should be 20");
12426 static_assert(offsetof(CopySubTextureCHROMIUM
, x
) == 24,
12427 "offset of CopySubTextureCHROMIUM x should be 24");
12428 static_assert(offsetof(CopySubTextureCHROMIUM
, y
) == 28,
12429 "offset of CopySubTextureCHROMIUM y should be 28");
12430 static_assert(offsetof(CopySubTextureCHROMIUM
, width
) == 32,
12431 "offset of CopySubTextureCHROMIUM width should be 32");
12432 static_assert(offsetof(CopySubTextureCHROMIUM
, height
) == 36,
12433 "offset of CopySubTextureCHROMIUM height should be 36");
12434 static_assert(offsetof(CopySubTextureCHROMIUM
, unpack_flip_y
) == 40,
12435 "offset of CopySubTextureCHROMIUM unpack_flip_y should be 40");
12437 offsetof(CopySubTextureCHROMIUM
, unpack_premultiply_alpha
) == 44,
12438 "offset of CopySubTextureCHROMIUM unpack_premultiply_alpha should be 44");
12440 offsetof(CopySubTextureCHROMIUM
, unpack_unmultiply_alpha
) == 48,
12441 "offset of CopySubTextureCHROMIUM unpack_unmultiply_alpha should be 48");
12443 struct CompressedCopyTextureCHROMIUM
{
12444 typedef CompressedCopyTextureCHROMIUM ValueType
;
12445 static const CommandId kCmdId
= kCompressedCopyTextureCHROMIUM
;
12446 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12447 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12449 static uint32_t ComputeSize() {
12450 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12453 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12455 void Init(GLenum _target
, GLenum _source_id
, GLenum _dest_id
) {
12458 source_id
= _source_id
;
12459 dest_id
= _dest_id
;
12462 void* Set(void* cmd
, GLenum _target
, GLenum _source_id
, GLenum _dest_id
) {
12463 static_cast<ValueType
*>(cmd
)->Init(_target
, _source_id
, _dest_id
);
12464 return NextCmdAddress
<ValueType
>(cmd
);
12467 gpu::CommandHeader header
;
12469 uint32_t source_id
;
12473 static_assert(sizeof(CompressedCopyTextureCHROMIUM
) == 16,
12474 "size of CompressedCopyTextureCHROMIUM should be 16");
12475 static_assert(offsetof(CompressedCopyTextureCHROMIUM
, header
) == 0,
12476 "offset of CompressedCopyTextureCHROMIUM header should be 0");
12477 static_assert(offsetof(CompressedCopyTextureCHROMIUM
, target
) == 4,
12478 "offset of CompressedCopyTextureCHROMIUM target should be 4");
12479 static_assert(offsetof(CompressedCopyTextureCHROMIUM
, source_id
) == 8,
12480 "offset of CompressedCopyTextureCHROMIUM source_id should be 8");
12481 static_assert(offsetof(CompressedCopyTextureCHROMIUM
, dest_id
) == 12,
12482 "offset of CompressedCopyTextureCHROMIUM dest_id should be 12");
12484 struct DrawArraysInstancedANGLE
{
12485 typedef DrawArraysInstancedANGLE ValueType
;
12486 static const CommandId kCmdId
= kDrawArraysInstancedANGLE
;
12487 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12488 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
12490 static uint32_t ComputeSize() {
12491 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12494 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12496 void Init(GLenum _mode
, GLint _first
, GLsizei _count
, GLsizei _primcount
) {
12501 primcount
= _primcount
;
12504 void* Set(void* cmd
,
12508 GLsizei _primcount
) {
12509 static_cast<ValueType
*>(cmd
)->Init(_mode
, _first
, _count
, _primcount
);
12510 return NextCmdAddress
<ValueType
>(cmd
);
12513 gpu::CommandHeader header
;
12520 static_assert(sizeof(DrawArraysInstancedANGLE
) == 20,
12521 "size of DrawArraysInstancedANGLE should be 20");
12522 static_assert(offsetof(DrawArraysInstancedANGLE
, header
) == 0,
12523 "offset of DrawArraysInstancedANGLE header should be 0");
12524 static_assert(offsetof(DrawArraysInstancedANGLE
, mode
) == 4,
12525 "offset of DrawArraysInstancedANGLE mode should be 4");
12526 static_assert(offsetof(DrawArraysInstancedANGLE
, first
) == 8,
12527 "offset of DrawArraysInstancedANGLE first should be 8");
12528 static_assert(offsetof(DrawArraysInstancedANGLE
, count
) == 12,
12529 "offset of DrawArraysInstancedANGLE count should be 12");
12530 static_assert(offsetof(DrawArraysInstancedANGLE
, primcount
) == 16,
12531 "offset of DrawArraysInstancedANGLE primcount should be 16");
12533 struct DrawElementsInstancedANGLE
{
12534 typedef DrawElementsInstancedANGLE ValueType
;
12535 static const CommandId kCmdId
= kDrawElementsInstancedANGLE
;
12536 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12537 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
12539 static uint32_t ComputeSize() {
12540 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12543 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12545 void Init(GLenum _mode
,
12548 GLuint _index_offset
,
12549 GLsizei _primcount
) {
12554 index_offset
= _index_offset
;
12555 primcount
= _primcount
;
12558 void* Set(void* cmd
,
12562 GLuint _index_offset
,
12563 GLsizei _primcount
) {
12564 static_cast<ValueType
*>(cmd
)
12565 ->Init(_mode
, _count
, _type
, _index_offset
, _primcount
);
12566 return NextCmdAddress
<ValueType
>(cmd
);
12569 gpu::CommandHeader header
;
12573 uint32_t index_offset
;
12577 static_assert(sizeof(DrawElementsInstancedANGLE
) == 24,
12578 "size of DrawElementsInstancedANGLE should be 24");
12579 static_assert(offsetof(DrawElementsInstancedANGLE
, header
) == 0,
12580 "offset of DrawElementsInstancedANGLE header should be 0");
12581 static_assert(offsetof(DrawElementsInstancedANGLE
, mode
) == 4,
12582 "offset of DrawElementsInstancedANGLE mode should be 4");
12583 static_assert(offsetof(DrawElementsInstancedANGLE
, count
) == 8,
12584 "offset of DrawElementsInstancedANGLE count should be 8");
12585 static_assert(offsetof(DrawElementsInstancedANGLE
, type
) == 12,
12586 "offset of DrawElementsInstancedANGLE type should be 12");
12587 static_assert(offsetof(DrawElementsInstancedANGLE
, index_offset
) == 16,
12588 "offset of DrawElementsInstancedANGLE index_offset should be 16");
12589 static_assert(offsetof(DrawElementsInstancedANGLE
, primcount
) == 20,
12590 "offset of DrawElementsInstancedANGLE primcount should be 20");
12592 struct VertexAttribDivisorANGLE
{
12593 typedef VertexAttribDivisorANGLE ValueType
;
12594 static const CommandId kCmdId
= kVertexAttribDivisorANGLE
;
12595 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12596 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12598 static uint32_t ComputeSize() {
12599 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12602 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12604 void Init(GLuint _index
, GLuint _divisor
) {
12607 divisor
= _divisor
;
12610 void* Set(void* cmd
, GLuint _index
, GLuint _divisor
) {
12611 static_cast<ValueType
*>(cmd
)->Init(_index
, _divisor
);
12612 return NextCmdAddress
<ValueType
>(cmd
);
12615 gpu::CommandHeader header
;
12620 static_assert(sizeof(VertexAttribDivisorANGLE
) == 12,
12621 "size of VertexAttribDivisorANGLE should be 12");
12622 static_assert(offsetof(VertexAttribDivisorANGLE
, header
) == 0,
12623 "offset of VertexAttribDivisorANGLE header should be 0");
12624 static_assert(offsetof(VertexAttribDivisorANGLE
, index
) == 4,
12625 "offset of VertexAttribDivisorANGLE index should be 4");
12626 static_assert(offsetof(VertexAttribDivisorANGLE
, divisor
) == 8,
12627 "offset of VertexAttribDivisorANGLE divisor should be 8");
12629 struct ProduceTextureCHROMIUMImmediate
{
12630 typedef ProduceTextureCHROMIUMImmediate ValueType
;
12631 static const CommandId kCmdId
= kProduceTextureCHROMIUMImmediate
;
12632 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
12633 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
12635 static uint32_t ComputeDataSize() {
12636 return static_cast<uint32_t>(sizeof(GLbyte
) * 64);
12639 static uint32_t ComputeSize() {
12640 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
12643 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
12645 void Init(GLenum _target
, const GLbyte
* _mailbox
) {
12648 memcpy(ImmediateDataAddress(this), _mailbox
, ComputeDataSize());
12651 void* Set(void* cmd
, GLenum _target
, const GLbyte
* _mailbox
) {
12652 static_cast<ValueType
*>(cmd
)->Init(_target
, _mailbox
);
12653 const uint32_t size
= ComputeSize();
12654 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
12657 gpu::CommandHeader header
;
12661 static_assert(sizeof(ProduceTextureCHROMIUMImmediate
) == 8,
12662 "size of ProduceTextureCHROMIUMImmediate should be 8");
12663 static_assert(offsetof(ProduceTextureCHROMIUMImmediate
, header
) == 0,
12664 "offset of ProduceTextureCHROMIUMImmediate header should be 0");
12665 static_assert(offsetof(ProduceTextureCHROMIUMImmediate
, target
) == 4,
12666 "offset of ProduceTextureCHROMIUMImmediate target should be 4");
12668 struct ProduceTextureDirectCHROMIUMImmediate
{
12669 typedef ProduceTextureDirectCHROMIUMImmediate ValueType
;
12670 static const CommandId kCmdId
= kProduceTextureDirectCHROMIUMImmediate
;
12671 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
12672 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
12674 static uint32_t ComputeDataSize() {
12675 return static_cast<uint32_t>(sizeof(GLbyte
) * 64);
12678 static uint32_t ComputeSize() {
12679 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
12682 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
12684 void Init(GLuint _texture
, GLenum _target
, const GLbyte
* _mailbox
) {
12686 texture
= _texture
;
12688 memcpy(ImmediateDataAddress(this), _mailbox
, ComputeDataSize());
12691 void* Set(void* cmd
,
12694 const GLbyte
* _mailbox
) {
12695 static_cast<ValueType
*>(cmd
)->Init(_texture
, _target
, _mailbox
);
12696 const uint32_t size
= ComputeSize();
12697 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
12700 gpu::CommandHeader header
;
12705 static_assert(sizeof(ProduceTextureDirectCHROMIUMImmediate
) == 12,
12706 "size of ProduceTextureDirectCHROMIUMImmediate should be 12");
12708 offsetof(ProduceTextureDirectCHROMIUMImmediate
, header
) == 0,
12709 "offset of ProduceTextureDirectCHROMIUMImmediate header should be 0");
12711 offsetof(ProduceTextureDirectCHROMIUMImmediate
, texture
) == 4,
12712 "offset of ProduceTextureDirectCHROMIUMImmediate texture should be 4");
12714 offsetof(ProduceTextureDirectCHROMIUMImmediate
, target
) == 8,
12715 "offset of ProduceTextureDirectCHROMIUMImmediate target should be 8");
12717 struct ConsumeTextureCHROMIUMImmediate
{
12718 typedef ConsumeTextureCHROMIUMImmediate ValueType
;
12719 static const CommandId kCmdId
= kConsumeTextureCHROMIUMImmediate
;
12720 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
12721 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
12723 static uint32_t ComputeDataSize() {
12724 return static_cast<uint32_t>(sizeof(GLbyte
) * 64);
12727 static uint32_t ComputeSize() {
12728 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
12731 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
12733 void Init(GLenum _target
, const GLbyte
* _mailbox
) {
12736 memcpy(ImmediateDataAddress(this), _mailbox
, ComputeDataSize());
12739 void* Set(void* cmd
, GLenum _target
, const GLbyte
* _mailbox
) {
12740 static_cast<ValueType
*>(cmd
)->Init(_target
, _mailbox
);
12741 const uint32_t size
= ComputeSize();
12742 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
12745 gpu::CommandHeader header
;
12749 static_assert(sizeof(ConsumeTextureCHROMIUMImmediate
) == 8,
12750 "size of ConsumeTextureCHROMIUMImmediate should be 8");
12751 static_assert(offsetof(ConsumeTextureCHROMIUMImmediate
, header
) == 0,
12752 "offset of ConsumeTextureCHROMIUMImmediate header should be 0");
12753 static_assert(offsetof(ConsumeTextureCHROMIUMImmediate
, target
) == 4,
12754 "offset of ConsumeTextureCHROMIUMImmediate target should be 4");
12756 struct BindUniformLocationCHROMIUMBucket
{
12757 typedef BindUniformLocationCHROMIUMBucket ValueType
;
12758 static const CommandId kCmdId
= kBindUniformLocationCHROMIUMBucket
;
12759 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12760 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12762 static uint32_t ComputeSize() {
12763 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12766 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12768 void Init(GLuint _program
, GLint _location
, uint32_t _name_bucket_id
) {
12770 program
= _program
;
12771 location
= _location
;
12772 name_bucket_id
= _name_bucket_id
;
12775 void* Set(void* cmd
,
12778 uint32_t _name_bucket_id
) {
12779 static_cast<ValueType
*>(cmd
)->Init(_program
, _location
, _name_bucket_id
);
12780 return NextCmdAddress
<ValueType
>(cmd
);
12783 gpu::CommandHeader header
;
12786 uint32_t name_bucket_id
;
12789 static_assert(sizeof(BindUniformLocationCHROMIUMBucket
) == 16,
12790 "size of BindUniformLocationCHROMIUMBucket should be 16");
12791 static_assert(offsetof(BindUniformLocationCHROMIUMBucket
, header
) == 0,
12792 "offset of BindUniformLocationCHROMIUMBucket header should be 0");
12794 offsetof(BindUniformLocationCHROMIUMBucket
, program
) == 4,
12795 "offset of BindUniformLocationCHROMIUMBucket program should be 4");
12797 offsetof(BindUniformLocationCHROMIUMBucket
, location
) == 8,
12798 "offset of BindUniformLocationCHROMIUMBucket location should be 8");
12800 offsetof(BindUniformLocationCHROMIUMBucket
, name_bucket_id
) == 12,
12801 "offset of BindUniformLocationCHROMIUMBucket name_bucket_id should be 12");
12803 struct GenValuebuffersCHROMIUMImmediate
{
12804 typedef GenValuebuffersCHROMIUMImmediate ValueType
;
12805 static const CommandId kCmdId
= kGenValuebuffersCHROMIUMImmediate
;
12806 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
12807 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12809 static uint32_t ComputeDataSize(GLsizei n
) {
12810 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
12813 static uint32_t ComputeSize(GLsizei n
) {
12814 return static_cast<uint32_t>(sizeof(ValueType
) +
12815 ComputeDataSize(n
)); // NOLINT
12818 void SetHeader(GLsizei n
) {
12819 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
12822 void Init(GLsizei _n
, GLuint
* _buffers
) {
12825 memcpy(ImmediateDataAddress(this), _buffers
, ComputeDataSize(_n
));
12828 void* Set(void* cmd
, GLsizei _n
, GLuint
* _buffers
) {
12829 static_cast<ValueType
*>(cmd
)->Init(_n
, _buffers
);
12830 const uint32_t size
= ComputeSize(_n
);
12831 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
12834 gpu::CommandHeader header
;
12838 static_assert(sizeof(GenValuebuffersCHROMIUMImmediate
) == 8,
12839 "size of GenValuebuffersCHROMIUMImmediate should be 8");
12840 static_assert(offsetof(GenValuebuffersCHROMIUMImmediate
, header
) == 0,
12841 "offset of GenValuebuffersCHROMIUMImmediate header should be 0");
12842 static_assert(offsetof(GenValuebuffersCHROMIUMImmediate
, n
) == 4,
12843 "offset of GenValuebuffersCHROMIUMImmediate n should be 4");
12845 struct DeleteValuebuffersCHROMIUMImmediate
{
12846 typedef DeleteValuebuffersCHROMIUMImmediate ValueType
;
12847 static const CommandId kCmdId
= kDeleteValuebuffersCHROMIUMImmediate
;
12848 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
12849 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12851 static uint32_t ComputeDataSize(GLsizei n
) {
12852 return static_cast<uint32_t>(sizeof(GLuint
) * n
); // NOLINT
12855 static uint32_t ComputeSize(GLsizei n
) {
12856 return static_cast<uint32_t>(sizeof(ValueType
) +
12857 ComputeDataSize(n
)); // NOLINT
12860 void SetHeader(GLsizei n
) {
12861 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(n
));
12864 void Init(GLsizei _n
, const GLuint
* _valuebuffers
) {
12867 memcpy(ImmediateDataAddress(this), _valuebuffers
, ComputeDataSize(_n
));
12870 void* Set(void* cmd
, GLsizei _n
, const GLuint
* _valuebuffers
) {
12871 static_cast<ValueType
*>(cmd
)->Init(_n
, _valuebuffers
);
12872 const uint32_t size
= ComputeSize(_n
);
12873 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
12876 gpu::CommandHeader header
;
12880 static_assert(sizeof(DeleteValuebuffersCHROMIUMImmediate
) == 8,
12881 "size of DeleteValuebuffersCHROMIUMImmediate should be 8");
12883 offsetof(DeleteValuebuffersCHROMIUMImmediate
, header
) == 0,
12884 "offset of DeleteValuebuffersCHROMIUMImmediate header should be 0");
12885 static_assert(offsetof(DeleteValuebuffersCHROMIUMImmediate
, n
) == 4,
12886 "offset of DeleteValuebuffersCHROMIUMImmediate n should be 4");
12888 struct IsValuebufferCHROMIUM
{
12889 typedef IsValuebufferCHROMIUM ValueType
;
12890 static const CommandId kCmdId
= kIsValuebufferCHROMIUM
;
12891 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12892 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12894 typedef uint32_t Result
;
12896 static uint32_t ComputeSize() {
12897 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12900 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12902 void Init(GLuint _valuebuffer
,
12903 uint32_t _result_shm_id
,
12904 uint32_t _result_shm_offset
) {
12906 valuebuffer
= _valuebuffer
;
12907 result_shm_id
= _result_shm_id
;
12908 result_shm_offset
= _result_shm_offset
;
12911 void* Set(void* cmd
,
12912 GLuint _valuebuffer
,
12913 uint32_t _result_shm_id
,
12914 uint32_t _result_shm_offset
) {
12915 static_cast<ValueType
*>(cmd
)
12916 ->Init(_valuebuffer
, _result_shm_id
, _result_shm_offset
);
12917 return NextCmdAddress
<ValueType
>(cmd
);
12920 gpu::CommandHeader header
;
12921 uint32_t valuebuffer
;
12922 uint32_t result_shm_id
;
12923 uint32_t result_shm_offset
;
12926 static_assert(sizeof(IsValuebufferCHROMIUM
) == 16,
12927 "size of IsValuebufferCHROMIUM should be 16");
12928 static_assert(offsetof(IsValuebufferCHROMIUM
, header
) == 0,
12929 "offset of IsValuebufferCHROMIUM header should be 0");
12930 static_assert(offsetof(IsValuebufferCHROMIUM
, valuebuffer
) == 4,
12931 "offset of IsValuebufferCHROMIUM valuebuffer should be 4");
12932 static_assert(offsetof(IsValuebufferCHROMIUM
, result_shm_id
) == 8,
12933 "offset of IsValuebufferCHROMIUM result_shm_id should be 8");
12934 static_assert(offsetof(IsValuebufferCHROMIUM
, result_shm_offset
) == 12,
12935 "offset of IsValuebufferCHROMIUM result_shm_offset should be 12");
12937 struct BindValuebufferCHROMIUM
{
12938 typedef BindValuebufferCHROMIUM ValueType
;
12939 static const CommandId kCmdId
= kBindValuebufferCHROMIUM
;
12940 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12941 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12943 static uint32_t ComputeSize() {
12944 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12947 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12949 void Init(GLenum _target
, GLuint _valuebuffer
) {
12952 valuebuffer
= _valuebuffer
;
12955 void* Set(void* cmd
, GLenum _target
, GLuint _valuebuffer
) {
12956 static_cast<ValueType
*>(cmd
)->Init(_target
, _valuebuffer
);
12957 return NextCmdAddress
<ValueType
>(cmd
);
12960 gpu::CommandHeader header
;
12962 uint32_t valuebuffer
;
12965 static_assert(sizeof(BindValuebufferCHROMIUM
) == 12,
12966 "size of BindValuebufferCHROMIUM should be 12");
12967 static_assert(offsetof(BindValuebufferCHROMIUM
, header
) == 0,
12968 "offset of BindValuebufferCHROMIUM header should be 0");
12969 static_assert(offsetof(BindValuebufferCHROMIUM
, target
) == 4,
12970 "offset of BindValuebufferCHROMIUM target should be 4");
12971 static_assert(offsetof(BindValuebufferCHROMIUM
, valuebuffer
) == 8,
12972 "offset of BindValuebufferCHROMIUM valuebuffer should be 8");
12974 struct SubscribeValueCHROMIUM
{
12975 typedef SubscribeValueCHROMIUM ValueType
;
12976 static const CommandId kCmdId
= kSubscribeValueCHROMIUM
;
12977 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
12978 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
12980 static uint32_t ComputeSize() {
12981 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
12984 void SetHeader() { header
.SetCmd
<ValueType
>(); }
12986 void Init(GLenum _target
, GLenum _subscription
) {
12989 subscription
= _subscription
;
12992 void* Set(void* cmd
, GLenum _target
, GLenum _subscription
) {
12993 static_cast<ValueType
*>(cmd
)->Init(_target
, _subscription
);
12994 return NextCmdAddress
<ValueType
>(cmd
);
12997 gpu::CommandHeader header
;
12999 uint32_t subscription
;
13002 static_assert(sizeof(SubscribeValueCHROMIUM
) == 12,
13003 "size of SubscribeValueCHROMIUM should be 12");
13004 static_assert(offsetof(SubscribeValueCHROMIUM
, header
) == 0,
13005 "offset of SubscribeValueCHROMIUM header should be 0");
13006 static_assert(offsetof(SubscribeValueCHROMIUM
, target
) == 4,
13007 "offset of SubscribeValueCHROMIUM target should be 4");
13008 static_assert(offsetof(SubscribeValueCHROMIUM
, subscription
) == 8,
13009 "offset of SubscribeValueCHROMIUM subscription should be 8");
13011 struct PopulateSubscribedValuesCHROMIUM
{
13012 typedef PopulateSubscribedValuesCHROMIUM ValueType
;
13013 static const CommandId kCmdId
= kPopulateSubscribedValuesCHROMIUM
;
13014 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13015 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13017 static uint32_t ComputeSize() {
13018 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13021 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13023 void Init(GLenum _target
) {
13028 void* Set(void* cmd
, GLenum _target
) {
13029 static_cast<ValueType
*>(cmd
)->Init(_target
);
13030 return NextCmdAddress
<ValueType
>(cmd
);
13033 gpu::CommandHeader header
;
13037 static_assert(sizeof(PopulateSubscribedValuesCHROMIUM
) == 8,
13038 "size of PopulateSubscribedValuesCHROMIUM should be 8");
13039 static_assert(offsetof(PopulateSubscribedValuesCHROMIUM
, header
) == 0,
13040 "offset of PopulateSubscribedValuesCHROMIUM header should be 0");
13041 static_assert(offsetof(PopulateSubscribedValuesCHROMIUM
, target
) == 4,
13042 "offset of PopulateSubscribedValuesCHROMIUM target should be 4");
13044 struct UniformValuebufferCHROMIUM
{
13045 typedef UniformValuebufferCHROMIUM ValueType
;
13046 static const CommandId kCmdId
= kUniformValuebufferCHROMIUM
;
13047 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13048 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13050 static uint32_t ComputeSize() {
13051 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13054 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13056 void Init(GLint _location
, GLenum _target
, GLenum _subscription
) {
13058 location
= _location
;
13060 subscription
= _subscription
;
13063 void* Set(void* cmd
, GLint _location
, GLenum _target
, GLenum _subscription
) {
13064 static_cast<ValueType
*>(cmd
)->Init(_location
, _target
, _subscription
);
13065 return NextCmdAddress
<ValueType
>(cmd
);
13068 gpu::CommandHeader header
;
13071 uint32_t subscription
;
13074 static_assert(sizeof(UniformValuebufferCHROMIUM
) == 16,
13075 "size of UniformValuebufferCHROMIUM should be 16");
13076 static_assert(offsetof(UniformValuebufferCHROMIUM
, header
) == 0,
13077 "offset of UniformValuebufferCHROMIUM header should be 0");
13078 static_assert(offsetof(UniformValuebufferCHROMIUM
, location
) == 4,
13079 "offset of UniformValuebufferCHROMIUM location should be 4");
13080 static_assert(offsetof(UniformValuebufferCHROMIUM
, target
) == 8,
13081 "offset of UniformValuebufferCHROMIUM target should be 8");
13082 static_assert(offsetof(UniformValuebufferCHROMIUM
, subscription
) == 12,
13083 "offset of UniformValuebufferCHROMIUM subscription should be 12");
13085 struct BindTexImage2DCHROMIUM
{
13086 typedef BindTexImage2DCHROMIUM ValueType
;
13087 static const CommandId kCmdId
= kBindTexImage2DCHROMIUM
;
13088 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13089 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13091 static uint32_t ComputeSize() {
13092 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13095 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13097 void Init(GLenum _target
, GLint _imageId
) {
13100 imageId
= _imageId
;
13103 void* Set(void* cmd
, GLenum _target
, GLint _imageId
) {
13104 static_cast<ValueType
*>(cmd
)->Init(_target
, _imageId
);
13105 return NextCmdAddress
<ValueType
>(cmd
);
13108 gpu::CommandHeader header
;
13113 static_assert(sizeof(BindTexImage2DCHROMIUM
) == 12,
13114 "size of BindTexImage2DCHROMIUM should be 12");
13115 static_assert(offsetof(BindTexImage2DCHROMIUM
, header
) == 0,
13116 "offset of BindTexImage2DCHROMIUM header should be 0");
13117 static_assert(offsetof(BindTexImage2DCHROMIUM
, target
) == 4,
13118 "offset of BindTexImage2DCHROMIUM target should be 4");
13119 static_assert(offsetof(BindTexImage2DCHROMIUM
, imageId
) == 8,
13120 "offset of BindTexImage2DCHROMIUM imageId should be 8");
13122 struct ReleaseTexImage2DCHROMIUM
{
13123 typedef ReleaseTexImage2DCHROMIUM ValueType
;
13124 static const CommandId kCmdId
= kReleaseTexImage2DCHROMIUM
;
13125 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13126 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13128 static uint32_t ComputeSize() {
13129 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13132 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13134 void Init(GLenum _target
, GLint _imageId
) {
13137 imageId
= _imageId
;
13140 void* Set(void* cmd
, GLenum _target
, GLint _imageId
) {
13141 static_cast<ValueType
*>(cmd
)->Init(_target
, _imageId
);
13142 return NextCmdAddress
<ValueType
>(cmd
);
13145 gpu::CommandHeader header
;
13150 static_assert(sizeof(ReleaseTexImage2DCHROMIUM
) == 12,
13151 "size of ReleaseTexImage2DCHROMIUM should be 12");
13152 static_assert(offsetof(ReleaseTexImage2DCHROMIUM
, header
) == 0,
13153 "offset of ReleaseTexImage2DCHROMIUM header should be 0");
13154 static_assert(offsetof(ReleaseTexImage2DCHROMIUM
, target
) == 4,
13155 "offset of ReleaseTexImage2DCHROMIUM target should be 4");
13156 static_assert(offsetof(ReleaseTexImage2DCHROMIUM
, imageId
) == 8,
13157 "offset of ReleaseTexImage2DCHROMIUM imageId should be 8");
13159 struct TraceBeginCHROMIUM
{
13160 typedef TraceBeginCHROMIUM ValueType
;
13161 static const CommandId kCmdId
= kTraceBeginCHROMIUM
;
13162 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13163 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13165 static uint32_t ComputeSize() {
13166 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13169 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13171 void Init(GLuint _category_bucket_id
, GLuint _name_bucket_id
) {
13173 category_bucket_id
= _category_bucket_id
;
13174 name_bucket_id
= _name_bucket_id
;
13177 void* Set(void* cmd
, GLuint _category_bucket_id
, GLuint _name_bucket_id
) {
13178 static_cast<ValueType
*>(cmd
)->Init(_category_bucket_id
, _name_bucket_id
);
13179 return NextCmdAddress
<ValueType
>(cmd
);
13182 gpu::CommandHeader header
;
13183 uint32_t category_bucket_id
;
13184 uint32_t name_bucket_id
;
13187 static_assert(sizeof(TraceBeginCHROMIUM
) == 12,
13188 "size of TraceBeginCHROMIUM should be 12");
13189 static_assert(offsetof(TraceBeginCHROMIUM
, header
) == 0,
13190 "offset of TraceBeginCHROMIUM header should be 0");
13191 static_assert(offsetof(TraceBeginCHROMIUM
, category_bucket_id
) == 4,
13192 "offset of TraceBeginCHROMIUM category_bucket_id should be 4");
13193 static_assert(offsetof(TraceBeginCHROMIUM
, name_bucket_id
) == 8,
13194 "offset of TraceBeginCHROMIUM name_bucket_id should be 8");
13196 struct TraceEndCHROMIUM
{
13197 typedef TraceEndCHROMIUM ValueType
;
13198 static const CommandId kCmdId
= kTraceEndCHROMIUM
;
13199 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13200 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13202 static uint32_t ComputeSize() {
13203 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13206 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13208 void Init() { SetHeader(); }
13210 void* Set(void* cmd
) {
13211 static_cast<ValueType
*>(cmd
)->Init();
13212 return NextCmdAddress
<ValueType
>(cmd
);
13215 gpu::CommandHeader header
;
13218 static_assert(sizeof(TraceEndCHROMIUM
) == 4,
13219 "size of TraceEndCHROMIUM should be 4");
13220 static_assert(offsetof(TraceEndCHROMIUM
, header
) == 0,
13221 "offset of TraceEndCHROMIUM header should be 0");
13223 struct AsyncTexSubImage2DCHROMIUM
{
13224 typedef AsyncTexSubImage2DCHROMIUM ValueType
;
13225 static const CommandId kCmdId
= kAsyncTexSubImage2DCHROMIUM
;
13226 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13227 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
13229 static uint32_t ComputeSize() {
13230 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13233 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13235 void Init(GLenum _target
,
13243 uint32_t _data_shm_id
,
13244 uint32_t _data_shm_offset
,
13245 uint32_t _async_upload_token
,
13246 uint32_t _sync_data_shm_id
,
13247 uint32_t _sync_data_shm_offset
) {
13251 xoffset
= _xoffset
;
13252 yoffset
= _yoffset
;
13257 data_shm_id
= _data_shm_id
;
13258 data_shm_offset
= _data_shm_offset
;
13259 async_upload_token
= _async_upload_token
;
13260 sync_data_shm_id
= _sync_data_shm_id
;
13261 sync_data_shm_offset
= _sync_data_shm_offset
;
13264 void* Set(void* cmd
,
13273 uint32_t _data_shm_id
,
13274 uint32_t _data_shm_offset
,
13275 uint32_t _async_upload_token
,
13276 uint32_t _sync_data_shm_id
,
13277 uint32_t _sync_data_shm_offset
) {
13278 static_cast<ValueType
*>(cmd
)
13279 ->Init(_target
, _level
, _xoffset
, _yoffset
, _width
, _height
, _format
,
13280 _type
, _data_shm_id
, _data_shm_offset
, _async_upload_token
,
13281 _sync_data_shm_id
, _sync_data_shm_offset
);
13282 return NextCmdAddress
<ValueType
>(cmd
);
13285 gpu::CommandHeader header
;
13294 uint32_t data_shm_id
;
13295 uint32_t data_shm_offset
;
13296 uint32_t async_upload_token
;
13297 uint32_t sync_data_shm_id
;
13298 uint32_t sync_data_shm_offset
;
13301 static_assert(sizeof(AsyncTexSubImage2DCHROMIUM
) == 56,
13302 "size of AsyncTexSubImage2DCHROMIUM should be 56");
13303 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, header
) == 0,
13304 "offset of AsyncTexSubImage2DCHROMIUM header should be 0");
13305 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, target
) == 4,
13306 "offset of AsyncTexSubImage2DCHROMIUM target should be 4");
13307 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, level
) == 8,
13308 "offset of AsyncTexSubImage2DCHROMIUM level should be 8");
13309 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, xoffset
) == 12,
13310 "offset of AsyncTexSubImage2DCHROMIUM xoffset should be 12");
13311 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, yoffset
) == 16,
13312 "offset of AsyncTexSubImage2DCHROMIUM yoffset should be 16");
13313 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, width
) == 20,
13314 "offset of AsyncTexSubImage2DCHROMIUM width should be 20");
13315 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, height
) == 24,
13316 "offset of AsyncTexSubImage2DCHROMIUM height should be 24");
13317 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, format
) == 28,
13318 "offset of AsyncTexSubImage2DCHROMIUM format should be 28");
13319 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, type
) == 32,
13320 "offset of AsyncTexSubImage2DCHROMIUM type should be 32");
13321 static_assert(offsetof(AsyncTexSubImage2DCHROMIUM
, data_shm_id
) == 36,
13322 "offset of AsyncTexSubImage2DCHROMIUM data_shm_id should be 36");
13324 offsetof(AsyncTexSubImage2DCHROMIUM
, data_shm_offset
) == 40,
13325 "offset of AsyncTexSubImage2DCHROMIUM data_shm_offset should be 40");
13327 offsetof(AsyncTexSubImage2DCHROMIUM
, async_upload_token
) == 44,
13328 "offset of AsyncTexSubImage2DCHROMIUM async_upload_token should be 44");
13330 offsetof(AsyncTexSubImage2DCHROMIUM
, sync_data_shm_id
) == 48,
13331 "offset of AsyncTexSubImage2DCHROMIUM sync_data_shm_id should be 48");
13333 offsetof(AsyncTexSubImage2DCHROMIUM
, sync_data_shm_offset
) == 52,
13334 "offset of AsyncTexSubImage2DCHROMIUM sync_data_shm_offset should be 52");
13336 struct AsyncTexImage2DCHROMIUM
{
13337 typedef AsyncTexImage2DCHROMIUM ValueType
;
13338 static const CommandId kCmdId
= kAsyncTexImage2DCHROMIUM
;
13339 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13340 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
13342 static uint32_t ComputeSize() {
13343 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13346 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13348 void Init(GLenum _target
,
13350 GLint _internalformat
,
13355 uint32_t _pixels_shm_id
,
13356 uint32_t _pixels_shm_offset
,
13357 uint32_t _async_upload_token
,
13358 uint32_t _sync_data_shm_id
,
13359 uint32_t _sync_data_shm_offset
) {
13363 internalformat
= _internalformat
;
13368 pixels_shm_id
= _pixels_shm_id
;
13369 pixels_shm_offset
= _pixels_shm_offset
;
13370 async_upload_token
= _async_upload_token
;
13371 sync_data_shm_id
= _sync_data_shm_id
;
13372 sync_data_shm_offset
= _sync_data_shm_offset
;
13375 void* Set(void* cmd
,
13378 GLint _internalformat
,
13383 uint32_t _pixels_shm_id
,
13384 uint32_t _pixels_shm_offset
,
13385 uint32_t _async_upload_token
,
13386 uint32_t _sync_data_shm_id
,
13387 uint32_t _sync_data_shm_offset
) {
13388 static_cast<ValueType
*>(cmd
)
13389 ->Init(_target
, _level
, _internalformat
, _width
, _height
, _format
,
13390 _type
, _pixels_shm_id
, _pixels_shm_offset
, _async_upload_token
,
13391 _sync_data_shm_id
, _sync_data_shm_offset
);
13392 return NextCmdAddress
<ValueType
>(cmd
);
13395 gpu::CommandHeader header
;
13398 int32_t internalformat
;
13403 uint32_t pixels_shm_id
;
13404 uint32_t pixels_shm_offset
;
13405 uint32_t async_upload_token
;
13406 uint32_t sync_data_shm_id
;
13407 uint32_t sync_data_shm_offset
;
13408 static const int32_t border
= 0;
13411 static_assert(sizeof(AsyncTexImage2DCHROMIUM
) == 52,
13412 "size of AsyncTexImage2DCHROMIUM should be 52");
13413 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, header
) == 0,
13414 "offset of AsyncTexImage2DCHROMIUM header should be 0");
13415 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, target
) == 4,
13416 "offset of AsyncTexImage2DCHROMIUM target should be 4");
13417 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, level
) == 8,
13418 "offset of AsyncTexImage2DCHROMIUM level should be 8");
13419 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, internalformat
) == 12,
13420 "offset of AsyncTexImage2DCHROMIUM internalformat should be 12");
13421 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, width
) == 16,
13422 "offset of AsyncTexImage2DCHROMIUM width should be 16");
13423 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, height
) == 20,
13424 "offset of AsyncTexImage2DCHROMIUM height should be 20");
13425 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, format
) == 24,
13426 "offset of AsyncTexImage2DCHROMIUM format should be 24");
13427 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, type
) == 28,
13428 "offset of AsyncTexImage2DCHROMIUM type should be 28");
13429 static_assert(offsetof(AsyncTexImage2DCHROMIUM
, pixels_shm_id
) == 32,
13430 "offset of AsyncTexImage2DCHROMIUM pixels_shm_id should be 32");
13432 offsetof(AsyncTexImage2DCHROMIUM
, pixels_shm_offset
) == 36,
13433 "offset of AsyncTexImage2DCHROMIUM pixels_shm_offset should be 36");
13435 offsetof(AsyncTexImage2DCHROMIUM
, async_upload_token
) == 40,
13436 "offset of AsyncTexImage2DCHROMIUM async_upload_token should be 40");
13438 offsetof(AsyncTexImage2DCHROMIUM
, sync_data_shm_id
) == 44,
13439 "offset of AsyncTexImage2DCHROMIUM sync_data_shm_id should be 44");
13441 offsetof(AsyncTexImage2DCHROMIUM
, sync_data_shm_offset
) == 48,
13442 "offset of AsyncTexImage2DCHROMIUM sync_data_shm_offset should be 48");
13444 struct WaitAsyncTexImage2DCHROMIUM
{
13445 typedef WaitAsyncTexImage2DCHROMIUM ValueType
;
13446 static const CommandId kCmdId
= kWaitAsyncTexImage2DCHROMIUM
;
13447 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13448 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13450 static uint32_t ComputeSize() {
13451 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13454 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13456 void Init(GLenum _target
) {
13461 void* Set(void* cmd
, GLenum _target
) {
13462 static_cast<ValueType
*>(cmd
)->Init(_target
);
13463 return NextCmdAddress
<ValueType
>(cmd
);
13466 gpu::CommandHeader header
;
13470 static_assert(sizeof(WaitAsyncTexImage2DCHROMIUM
) == 8,
13471 "size of WaitAsyncTexImage2DCHROMIUM should be 8");
13472 static_assert(offsetof(WaitAsyncTexImage2DCHROMIUM
, header
) == 0,
13473 "offset of WaitAsyncTexImage2DCHROMIUM header should be 0");
13474 static_assert(offsetof(WaitAsyncTexImage2DCHROMIUM
, target
) == 4,
13475 "offset of WaitAsyncTexImage2DCHROMIUM target should be 4");
13477 struct WaitAllAsyncTexImage2DCHROMIUM
{
13478 typedef WaitAllAsyncTexImage2DCHROMIUM ValueType
;
13479 static const CommandId kCmdId
= kWaitAllAsyncTexImage2DCHROMIUM
;
13480 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13481 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13483 static uint32_t ComputeSize() {
13484 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13487 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13489 void Init() { SetHeader(); }
13491 void* Set(void* cmd
) {
13492 static_cast<ValueType
*>(cmd
)->Init();
13493 return NextCmdAddress
<ValueType
>(cmd
);
13496 gpu::CommandHeader header
;
13499 static_assert(sizeof(WaitAllAsyncTexImage2DCHROMIUM
) == 4,
13500 "size of WaitAllAsyncTexImage2DCHROMIUM should be 4");
13501 static_assert(offsetof(WaitAllAsyncTexImage2DCHROMIUM
, header
) == 0,
13502 "offset of WaitAllAsyncTexImage2DCHROMIUM header should be 0");
13504 struct DiscardFramebufferEXTImmediate
{
13505 typedef DiscardFramebufferEXTImmediate ValueType
;
13506 static const CommandId kCmdId
= kDiscardFramebufferEXTImmediate
;
13507 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
13508 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
13510 static uint32_t ComputeDataSize(GLsizei count
) {
13511 return static_cast<uint32_t>(sizeof(GLenum
) * 1 * count
); // NOLINT
13514 static uint32_t ComputeSize(GLsizei count
) {
13515 return static_cast<uint32_t>(sizeof(ValueType
) +
13516 ComputeDataSize(count
)); // NOLINT
13519 void SetHeader(GLsizei count
) {
13520 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
13523 void Init(GLenum _target
, GLsizei _count
, const GLenum
* _attachments
) {
13527 memcpy(ImmediateDataAddress(this), _attachments
, ComputeDataSize(_count
));
13530 void* Set(void* cmd
,
13533 const GLenum
* _attachments
) {
13534 static_cast<ValueType
*>(cmd
)->Init(_target
, _count
, _attachments
);
13535 const uint32_t size
= ComputeSize(_count
);
13536 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
13539 gpu::CommandHeader header
;
13544 static_assert(sizeof(DiscardFramebufferEXTImmediate
) == 12,
13545 "size of DiscardFramebufferEXTImmediate should be 12");
13546 static_assert(offsetof(DiscardFramebufferEXTImmediate
, header
) == 0,
13547 "offset of DiscardFramebufferEXTImmediate header should be 0");
13548 static_assert(offsetof(DiscardFramebufferEXTImmediate
, target
) == 4,
13549 "offset of DiscardFramebufferEXTImmediate target should be 4");
13550 static_assert(offsetof(DiscardFramebufferEXTImmediate
, count
) == 8,
13551 "offset of DiscardFramebufferEXTImmediate count should be 8");
13553 struct LoseContextCHROMIUM
{
13554 typedef LoseContextCHROMIUM ValueType
;
13555 static const CommandId kCmdId
= kLoseContextCHROMIUM
;
13556 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13557 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13559 static uint32_t ComputeSize() {
13560 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13563 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13565 void Init(GLenum _current
, GLenum _other
) {
13567 current
= _current
;
13571 void* Set(void* cmd
, GLenum _current
, GLenum _other
) {
13572 static_cast<ValueType
*>(cmd
)->Init(_current
, _other
);
13573 return NextCmdAddress
<ValueType
>(cmd
);
13576 gpu::CommandHeader header
;
13581 static_assert(sizeof(LoseContextCHROMIUM
) == 12,
13582 "size of LoseContextCHROMIUM should be 12");
13583 static_assert(offsetof(LoseContextCHROMIUM
, header
) == 0,
13584 "offset of LoseContextCHROMIUM header should be 0");
13585 static_assert(offsetof(LoseContextCHROMIUM
, current
) == 4,
13586 "offset of LoseContextCHROMIUM current should be 4");
13587 static_assert(offsetof(LoseContextCHROMIUM
, other
) == 8,
13588 "offset of LoseContextCHROMIUM other should be 8");
13590 struct WaitSyncPointCHROMIUM
{
13591 typedef WaitSyncPointCHROMIUM ValueType
;
13592 static const CommandId kCmdId
= kWaitSyncPointCHROMIUM
;
13593 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13594 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13596 static uint32_t ComputeSize() {
13597 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13600 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13602 void Init(GLuint _sync_point
) {
13604 sync_point
= _sync_point
;
13607 void* Set(void* cmd
, GLuint _sync_point
) {
13608 static_cast<ValueType
*>(cmd
)->Init(_sync_point
);
13609 return NextCmdAddress
<ValueType
>(cmd
);
13612 gpu::CommandHeader header
;
13613 uint32_t sync_point
;
13616 static_assert(sizeof(WaitSyncPointCHROMIUM
) == 8,
13617 "size of WaitSyncPointCHROMIUM should be 8");
13618 static_assert(offsetof(WaitSyncPointCHROMIUM
, header
) == 0,
13619 "offset of WaitSyncPointCHROMIUM header should be 0");
13620 static_assert(offsetof(WaitSyncPointCHROMIUM
, sync_point
) == 4,
13621 "offset of WaitSyncPointCHROMIUM sync_point should be 4");
13623 struct DrawBuffersEXTImmediate
{
13624 typedef DrawBuffersEXTImmediate ValueType
;
13625 static const CommandId kCmdId
= kDrawBuffersEXTImmediate
;
13626 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
13627 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
13629 static uint32_t ComputeDataSize(GLsizei count
) {
13630 return static_cast<uint32_t>(sizeof(GLenum
) * 1 * count
); // NOLINT
13633 static uint32_t ComputeSize(GLsizei count
) {
13634 return static_cast<uint32_t>(sizeof(ValueType
) +
13635 ComputeDataSize(count
)); // NOLINT
13638 void SetHeader(GLsizei count
) {
13639 header
.SetCmdByTotalSize
<ValueType
>(ComputeSize(count
));
13642 void Init(GLsizei _count
, const GLenum
* _bufs
) {
13645 memcpy(ImmediateDataAddress(this), _bufs
, ComputeDataSize(_count
));
13648 void* Set(void* cmd
, GLsizei _count
, const GLenum
* _bufs
) {
13649 static_cast<ValueType
*>(cmd
)->Init(_count
, _bufs
);
13650 const uint32_t size
= ComputeSize(_count
);
13651 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
13654 gpu::CommandHeader header
;
13658 static_assert(sizeof(DrawBuffersEXTImmediate
) == 8,
13659 "size of DrawBuffersEXTImmediate should be 8");
13660 static_assert(offsetof(DrawBuffersEXTImmediate
, header
) == 0,
13661 "offset of DrawBuffersEXTImmediate header should be 0");
13662 static_assert(offsetof(DrawBuffersEXTImmediate
, count
) == 4,
13663 "offset of DrawBuffersEXTImmediate count should be 4");
13665 struct DiscardBackbufferCHROMIUM
{
13666 typedef DiscardBackbufferCHROMIUM ValueType
;
13667 static const CommandId kCmdId
= kDiscardBackbufferCHROMIUM
;
13668 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13669 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(2);
13671 static uint32_t ComputeSize() {
13672 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13675 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13677 void Init() { SetHeader(); }
13679 void* Set(void* cmd
) {
13680 static_cast<ValueType
*>(cmd
)->Init();
13681 return NextCmdAddress
<ValueType
>(cmd
);
13684 gpu::CommandHeader header
;
13687 static_assert(sizeof(DiscardBackbufferCHROMIUM
) == 4,
13688 "size of DiscardBackbufferCHROMIUM should be 4");
13689 static_assert(offsetof(DiscardBackbufferCHROMIUM
, header
) == 0,
13690 "offset of DiscardBackbufferCHROMIUM header should be 0");
13692 struct ScheduleOverlayPlaneCHROMIUM
{
13693 typedef ScheduleOverlayPlaneCHROMIUM ValueType
;
13694 static const CommandId kCmdId
= kScheduleOverlayPlaneCHROMIUM
;
13695 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13696 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13698 static uint32_t ComputeSize() {
13699 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13702 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13704 void Init(GLint _plane_z_order
,
13705 GLenum _plane_transform
,
13706 GLuint _overlay_texture_id
,
13709 GLint _bounds_width
,
13710 GLint _bounds_height
,
13714 GLfloat _uv_height
) {
13716 plane_z_order
= _plane_z_order
;
13717 plane_transform
= _plane_transform
;
13718 overlay_texture_id
= _overlay_texture_id
;
13719 bounds_x
= _bounds_x
;
13720 bounds_y
= _bounds_y
;
13721 bounds_width
= _bounds_width
;
13722 bounds_height
= _bounds_height
;
13725 uv_width
= _uv_width
;
13726 uv_height
= _uv_height
;
13729 void* Set(void* cmd
,
13730 GLint _plane_z_order
,
13731 GLenum _plane_transform
,
13732 GLuint _overlay_texture_id
,
13735 GLint _bounds_width
,
13736 GLint _bounds_height
,
13740 GLfloat _uv_height
) {
13741 static_cast<ValueType
*>(cmd
)->Init(_plane_z_order
, _plane_transform
,
13742 _overlay_texture_id
, _bounds_x
,
13743 _bounds_y
, _bounds_width
, _bounds_height
,
13744 _uv_x
, _uv_y
, _uv_width
, _uv_height
);
13745 return NextCmdAddress
<ValueType
>(cmd
);
13748 gpu::CommandHeader header
;
13749 int32_t plane_z_order
;
13750 uint32_t plane_transform
;
13751 uint32_t overlay_texture_id
;
13754 int32_t bounds_width
;
13755 int32_t bounds_height
;
13762 static_assert(sizeof(ScheduleOverlayPlaneCHROMIUM
) == 48,
13763 "size of ScheduleOverlayPlaneCHROMIUM should be 48");
13764 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, header
) == 0,
13765 "offset of ScheduleOverlayPlaneCHROMIUM header should be 0");
13767 offsetof(ScheduleOverlayPlaneCHROMIUM
, plane_z_order
) == 4,
13768 "offset of ScheduleOverlayPlaneCHROMIUM plane_z_order should be 4");
13770 offsetof(ScheduleOverlayPlaneCHROMIUM
, plane_transform
) == 8,
13771 "offset of ScheduleOverlayPlaneCHROMIUM plane_transform should be 8");
13773 offsetof(ScheduleOverlayPlaneCHROMIUM
, overlay_texture_id
) == 12,
13774 "offset of ScheduleOverlayPlaneCHROMIUM overlay_texture_id should be 12");
13775 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, bounds_x
) == 16,
13776 "offset of ScheduleOverlayPlaneCHROMIUM bounds_x should be 16");
13777 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, bounds_y
) == 20,
13778 "offset of ScheduleOverlayPlaneCHROMIUM bounds_y should be 20");
13780 offsetof(ScheduleOverlayPlaneCHROMIUM
, bounds_width
) == 24,
13781 "offset of ScheduleOverlayPlaneCHROMIUM bounds_width should be 24");
13783 offsetof(ScheduleOverlayPlaneCHROMIUM
, bounds_height
) == 28,
13784 "offset of ScheduleOverlayPlaneCHROMIUM bounds_height should be 28");
13785 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, uv_x
) == 32,
13786 "offset of ScheduleOverlayPlaneCHROMIUM uv_x should be 32");
13787 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, uv_y
) == 36,
13788 "offset of ScheduleOverlayPlaneCHROMIUM uv_y should be 36");
13789 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, uv_width
) == 40,
13790 "offset of ScheduleOverlayPlaneCHROMIUM uv_width should be 40");
13791 static_assert(offsetof(ScheduleOverlayPlaneCHROMIUM
, uv_height
) == 44,
13792 "offset of ScheduleOverlayPlaneCHROMIUM uv_height should be 44");
13794 struct SwapInterval
{
13795 typedef SwapInterval ValueType
;
13796 static const CommandId kCmdId
= kSwapInterval
;
13797 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13798 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13800 static uint32_t ComputeSize() {
13801 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13804 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13806 void Init(GLint _interval
) {
13808 interval
= _interval
;
13811 void* Set(void* cmd
, GLint _interval
) {
13812 static_cast<ValueType
*>(cmd
)->Init(_interval
);
13813 return NextCmdAddress
<ValueType
>(cmd
);
13816 gpu::CommandHeader header
;
13820 static_assert(sizeof(SwapInterval
) == 8, "size of SwapInterval should be 8");
13821 static_assert(offsetof(SwapInterval
, header
) == 0,
13822 "offset of SwapInterval header should be 0");
13823 static_assert(offsetof(SwapInterval
, interval
) == 4,
13824 "offset of SwapInterval interval should be 4");
13826 struct FlushDriverCachesCHROMIUM
{
13827 typedef FlushDriverCachesCHROMIUM ValueType
;
13828 static const CommandId kCmdId
= kFlushDriverCachesCHROMIUM
;
13829 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13830 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(1);
13832 static uint32_t ComputeSize() {
13833 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13836 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13838 void Init() { SetHeader(); }
13840 void* Set(void* cmd
) {
13841 static_cast<ValueType
*>(cmd
)->Init();
13842 return NextCmdAddress
<ValueType
>(cmd
);
13845 gpu::CommandHeader header
;
13848 static_assert(sizeof(FlushDriverCachesCHROMIUM
) == 4,
13849 "size of FlushDriverCachesCHROMIUM should be 4");
13850 static_assert(offsetof(FlushDriverCachesCHROMIUM
, header
) == 0,
13851 "offset of FlushDriverCachesCHROMIUM header should be 0");
13853 struct MatrixLoadfCHROMIUMImmediate
{
13854 typedef MatrixLoadfCHROMIUMImmediate ValueType
;
13855 static const CommandId kCmdId
= kMatrixLoadfCHROMIUMImmediate
;
13856 static const cmd::ArgFlags kArgFlags
= cmd::kAtLeastN
;
13857 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13859 static uint32_t ComputeDataSize() {
13860 return static_cast<uint32_t>(sizeof(GLfloat
) * 16);
13863 static uint32_t ComputeSize() {
13864 return static_cast<uint32_t>(sizeof(ValueType
) + ComputeDataSize());
13867 void SetHeader() { header
.SetCmdByTotalSize
<ValueType
>(ComputeSize()); }
13869 void Init(GLenum _matrixMode
, const GLfloat
* _m
) {
13871 matrixMode
= _matrixMode
;
13872 memcpy(ImmediateDataAddress(this), _m
, ComputeDataSize());
13875 void* Set(void* cmd
, GLenum _matrixMode
, const GLfloat
* _m
) {
13876 static_cast<ValueType
*>(cmd
)->Init(_matrixMode
, _m
);
13877 const uint32_t size
= ComputeSize();
13878 return NextImmediateCmdAddressTotalSize
<ValueType
>(cmd
, size
);
13881 gpu::CommandHeader header
;
13882 uint32_t matrixMode
;
13885 static_assert(sizeof(MatrixLoadfCHROMIUMImmediate
) == 8,
13886 "size of MatrixLoadfCHROMIUMImmediate should be 8");
13887 static_assert(offsetof(MatrixLoadfCHROMIUMImmediate
, header
) == 0,
13888 "offset of MatrixLoadfCHROMIUMImmediate header should be 0");
13889 static_assert(offsetof(MatrixLoadfCHROMIUMImmediate
, matrixMode
) == 4,
13890 "offset of MatrixLoadfCHROMIUMImmediate matrixMode should be 4");
13892 struct MatrixLoadIdentityCHROMIUM
{
13893 typedef MatrixLoadIdentityCHROMIUM ValueType
;
13894 static const CommandId kCmdId
= kMatrixLoadIdentityCHROMIUM
;
13895 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13896 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13898 static uint32_t ComputeSize() {
13899 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13902 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13904 void Init(GLenum _matrixMode
) {
13906 matrixMode
= _matrixMode
;
13909 void* Set(void* cmd
, GLenum _matrixMode
) {
13910 static_cast<ValueType
*>(cmd
)->Init(_matrixMode
);
13911 return NextCmdAddress
<ValueType
>(cmd
);
13914 gpu::CommandHeader header
;
13915 uint32_t matrixMode
;
13918 static_assert(sizeof(MatrixLoadIdentityCHROMIUM
) == 8,
13919 "size of MatrixLoadIdentityCHROMIUM should be 8");
13920 static_assert(offsetof(MatrixLoadIdentityCHROMIUM
, header
) == 0,
13921 "offset of MatrixLoadIdentityCHROMIUM header should be 0");
13922 static_assert(offsetof(MatrixLoadIdentityCHROMIUM
, matrixMode
) == 4,
13923 "offset of MatrixLoadIdentityCHROMIUM matrixMode should be 4");
13925 struct GenPathsCHROMIUM
{
13926 typedef GenPathsCHROMIUM ValueType
;
13927 static const CommandId kCmdId
= kGenPathsCHROMIUM
;
13928 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13929 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13931 static uint32_t ComputeSize() {
13932 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13935 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13937 void Init(GLuint _first_client_id
, GLsizei _range
) {
13939 first_client_id
= _first_client_id
;
13943 void* Set(void* cmd
, GLuint _first_client_id
, GLsizei _range
) {
13944 static_cast<ValueType
*>(cmd
)->Init(_first_client_id
, _range
);
13945 return NextCmdAddress
<ValueType
>(cmd
);
13948 gpu::CommandHeader header
;
13949 uint32_t first_client_id
;
13953 static_assert(sizeof(GenPathsCHROMIUM
) == 12,
13954 "size of GenPathsCHROMIUM should be 12");
13955 static_assert(offsetof(GenPathsCHROMIUM
, header
) == 0,
13956 "offset of GenPathsCHROMIUM header should be 0");
13957 static_assert(offsetof(GenPathsCHROMIUM
, first_client_id
) == 4,
13958 "offset of GenPathsCHROMIUM first_client_id should be 4");
13959 static_assert(offsetof(GenPathsCHROMIUM
, range
) == 8,
13960 "offset of GenPathsCHROMIUM range should be 8");
13962 struct DeletePathsCHROMIUM
{
13963 typedef DeletePathsCHROMIUM ValueType
;
13964 static const CommandId kCmdId
= kDeletePathsCHROMIUM
;
13965 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
13966 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
13968 static uint32_t ComputeSize() {
13969 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
13972 void SetHeader() { header
.SetCmd
<ValueType
>(); }
13974 void Init(GLuint _first_client_id
, GLsizei _range
) {
13976 first_client_id
= _first_client_id
;
13980 void* Set(void* cmd
, GLuint _first_client_id
, GLsizei _range
) {
13981 static_cast<ValueType
*>(cmd
)->Init(_first_client_id
, _range
);
13982 return NextCmdAddress
<ValueType
>(cmd
);
13985 gpu::CommandHeader header
;
13986 uint32_t first_client_id
;
13990 static_assert(sizeof(DeletePathsCHROMIUM
) == 12,
13991 "size of DeletePathsCHROMIUM should be 12");
13992 static_assert(offsetof(DeletePathsCHROMIUM
, header
) == 0,
13993 "offset of DeletePathsCHROMIUM header should be 0");
13994 static_assert(offsetof(DeletePathsCHROMIUM
, first_client_id
) == 4,
13995 "offset of DeletePathsCHROMIUM first_client_id should be 4");
13996 static_assert(offsetof(DeletePathsCHROMIUM
, range
) == 8,
13997 "offset of DeletePathsCHROMIUM range should be 8");
13999 struct IsPathCHROMIUM
{
14000 typedef IsPathCHROMIUM ValueType
;
14001 static const CommandId kCmdId
= kIsPathCHROMIUM
;
14002 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14003 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14005 typedef uint32_t Result
;
14007 static uint32_t ComputeSize() {
14008 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14011 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14013 void Init(GLuint _path
,
14014 uint32_t _result_shm_id
,
14015 uint32_t _result_shm_offset
) {
14018 result_shm_id
= _result_shm_id
;
14019 result_shm_offset
= _result_shm_offset
;
14022 void* Set(void* cmd
,
14024 uint32_t _result_shm_id
,
14025 uint32_t _result_shm_offset
) {
14026 static_cast<ValueType
*>(cmd
)
14027 ->Init(_path
, _result_shm_id
, _result_shm_offset
);
14028 return NextCmdAddress
<ValueType
>(cmd
);
14031 gpu::CommandHeader header
;
14033 uint32_t result_shm_id
;
14034 uint32_t result_shm_offset
;
14037 static_assert(sizeof(IsPathCHROMIUM
) == 16,
14038 "size of IsPathCHROMIUM should be 16");
14039 static_assert(offsetof(IsPathCHROMIUM
, header
) == 0,
14040 "offset of IsPathCHROMIUM header should be 0");
14041 static_assert(offsetof(IsPathCHROMIUM
, path
) == 4,
14042 "offset of IsPathCHROMIUM path should be 4");
14043 static_assert(offsetof(IsPathCHROMIUM
, result_shm_id
) == 8,
14044 "offset of IsPathCHROMIUM result_shm_id should be 8");
14045 static_assert(offsetof(IsPathCHROMIUM
, result_shm_offset
) == 12,
14046 "offset of IsPathCHROMIUM result_shm_offset should be 12");
14048 struct PathCommandsCHROMIUM
{
14049 typedef PathCommandsCHROMIUM ValueType
;
14050 static const CommandId kCmdId
= kPathCommandsCHROMIUM
;
14051 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14052 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14054 static uint32_t ComputeSize() {
14055 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14058 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14060 void Init(GLuint _path
,
14061 GLsizei _numCommands
,
14062 uint32_t _commands_shm_id
,
14063 uint32_t _commands_shm_offset
,
14064 GLsizei _numCoords
,
14066 uint32_t _coords_shm_id
,
14067 uint32_t _coords_shm_offset
) {
14070 numCommands
= _numCommands
;
14071 commands_shm_id
= _commands_shm_id
;
14072 commands_shm_offset
= _commands_shm_offset
;
14073 numCoords
= _numCoords
;
14074 coordType
= _coordType
;
14075 coords_shm_id
= _coords_shm_id
;
14076 coords_shm_offset
= _coords_shm_offset
;
14079 void* Set(void* cmd
,
14081 GLsizei _numCommands
,
14082 uint32_t _commands_shm_id
,
14083 uint32_t _commands_shm_offset
,
14084 GLsizei _numCoords
,
14086 uint32_t _coords_shm_id
,
14087 uint32_t _coords_shm_offset
) {
14088 static_cast<ValueType
*>(cmd
)
14089 ->Init(_path
, _numCommands
, _commands_shm_id
, _commands_shm_offset
,
14090 _numCoords
, _coordType
, _coords_shm_id
, _coords_shm_offset
);
14091 return NextCmdAddress
<ValueType
>(cmd
);
14094 gpu::CommandHeader header
;
14096 int32_t numCommands
;
14097 uint32_t commands_shm_id
;
14098 uint32_t commands_shm_offset
;
14100 uint32_t coordType
;
14101 uint32_t coords_shm_id
;
14102 uint32_t coords_shm_offset
;
14105 static_assert(sizeof(PathCommandsCHROMIUM
) == 36,
14106 "size of PathCommandsCHROMIUM should be 36");
14107 static_assert(offsetof(PathCommandsCHROMIUM
, header
) == 0,
14108 "offset of PathCommandsCHROMIUM header should be 0");
14109 static_assert(offsetof(PathCommandsCHROMIUM
, path
) == 4,
14110 "offset of PathCommandsCHROMIUM path should be 4");
14111 static_assert(offsetof(PathCommandsCHROMIUM
, numCommands
) == 8,
14112 "offset of PathCommandsCHROMIUM numCommands should be 8");
14113 static_assert(offsetof(PathCommandsCHROMIUM
, commands_shm_id
) == 12,
14114 "offset of PathCommandsCHROMIUM commands_shm_id should be 12");
14116 offsetof(PathCommandsCHROMIUM
, commands_shm_offset
) == 16,
14117 "offset of PathCommandsCHROMIUM commands_shm_offset should be 16");
14118 static_assert(offsetof(PathCommandsCHROMIUM
, numCoords
) == 20,
14119 "offset of PathCommandsCHROMIUM numCoords should be 20");
14120 static_assert(offsetof(PathCommandsCHROMIUM
, coordType
) == 24,
14121 "offset of PathCommandsCHROMIUM coordType should be 24");
14122 static_assert(offsetof(PathCommandsCHROMIUM
, coords_shm_id
) == 28,
14123 "offset of PathCommandsCHROMIUM coords_shm_id should be 28");
14124 static_assert(offsetof(PathCommandsCHROMIUM
, coords_shm_offset
) == 32,
14125 "offset of PathCommandsCHROMIUM coords_shm_offset should be 32");
14127 struct PathParameterfCHROMIUM
{
14128 typedef PathParameterfCHROMIUM ValueType
;
14129 static const CommandId kCmdId
= kPathParameterfCHROMIUM
;
14130 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14131 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14133 static uint32_t ComputeSize() {
14134 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14137 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14139 void Init(GLuint _path
, GLenum _pname
, GLfloat _value
) {
14146 void* Set(void* cmd
, GLuint _path
, GLenum _pname
, GLfloat _value
) {
14147 static_cast<ValueType
*>(cmd
)->Init(_path
, _pname
, _value
);
14148 return NextCmdAddress
<ValueType
>(cmd
);
14151 gpu::CommandHeader header
;
14157 static_assert(sizeof(PathParameterfCHROMIUM
) == 16,
14158 "size of PathParameterfCHROMIUM should be 16");
14159 static_assert(offsetof(PathParameterfCHROMIUM
, header
) == 0,
14160 "offset of PathParameterfCHROMIUM header should be 0");
14161 static_assert(offsetof(PathParameterfCHROMIUM
, path
) == 4,
14162 "offset of PathParameterfCHROMIUM path should be 4");
14163 static_assert(offsetof(PathParameterfCHROMIUM
, pname
) == 8,
14164 "offset of PathParameterfCHROMIUM pname should be 8");
14165 static_assert(offsetof(PathParameterfCHROMIUM
, value
) == 12,
14166 "offset of PathParameterfCHROMIUM value should be 12");
14168 struct PathParameteriCHROMIUM
{
14169 typedef PathParameteriCHROMIUM ValueType
;
14170 static const CommandId kCmdId
= kPathParameteriCHROMIUM
;
14171 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14172 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14174 static uint32_t ComputeSize() {
14175 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14178 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14180 void Init(GLuint _path
, GLenum _pname
, GLint _value
) {
14187 void* Set(void* cmd
, GLuint _path
, GLenum _pname
, GLint _value
) {
14188 static_cast<ValueType
*>(cmd
)->Init(_path
, _pname
, _value
);
14189 return NextCmdAddress
<ValueType
>(cmd
);
14192 gpu::CommandHeader header
;
14198 static_assert(sizeof(PathParameteriCHROMIUM
) == 16,
14199 "size of PathParameteriCHROMIUM should be 16");
14200 static_assert(offsetof(PathParameteriCHROMIUM
, header
) == 0,
14201 "offset of PathParameteriCHROMIUM header should be 0");
14202 static_assert(offsetof(PathParameteriCHROMIUM
, path
) == 4,
14203 "offset of PathParameteriCHROMIUM path should be 4");
14204 static_assert(offsetof(PathParameteriCHROMIUM
, pname
) == 8,
14205 "offset of PathParameteriCHROMIUM pname should be 8");
14206 static_assert(offsetof(PathParameteriCHROMIUM
, value
) == 12,
14207 "offset of PathParameteriCHROMIUM value should be 12");
14209 struct PathStencilFuncCHROMIUM
{
14210 typedef PathStencilFuncCHROMIUM ValueType
;
14211 static const CommandId kCmdId
= kPathStencilFuncCHROMIUM
;
14212 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14213 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14215 static uint32_t ComputeSize() {
14216 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14219 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14221 void Init(GLenum _func
, GLint _ref
, GLuint _mask
) {
14228 void* Set(void* cmd
, GLenum _func
, GLint _ref
, GLuint _mask
) {
14229 static_cast<ValueType
*>(cmd
)->Init(_func
, _ref
, _mask
);
14230 return NextCmdAddress
<ValueType
>(cmd
);
14233 gpu::CommandHeader header
;
14239 static_assert(sizeof(PathStencilFuncCHROMIUM
) == 16,
14240 "size of PathStencilFuncCHROMIUM should be 16");
14241 static_assert(offsetof(PathStencilFuncCHROMIUM
, header
) == 0,
14242 "offset of PathStencilFuncCHROMIUM header should be 0");
14243 static_assert(offsetof(PathStencilFuncCHROMIUM
, func
) == 4,
14244 "offset of PathStencilFuncCHROMIUM func should be 4");
14245 static_assert(offsetof(PathStencilFuncCHROMIUM
, ref
) == 8,
14246 "offset of PathStencilFuncCHROMIUM ref should be 8");
14247 static_assert(offsetof(PathStencilFuncCHROMIUM
, mask
) == 12,
14248 "offset of PathStencilFuncCHROMIUM mask should be 12");
14250 struct StencilFillPathCHROMIUM
{
14251 typedef StencilFillPathCHROMIUM ValueType
;
14252 static const CommandId kCmdId
= kStencilFillPathCHROMIUM
;
14253 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14254 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14256 static uint32_t ComputeSize() {
14257 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14260 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14262 void Init(GLuint _path
, GLenum _fillMode
, GLuint _mask
) {
14265 fillMode
= _fillMode
;
14269 void* Set(void* cmd
, GLuint _path
, GLenum _fillMode
, GLuint _mask
) {
14270 static_cast<ValueType
*>(cmd
)->Init(_path
, _fillMode
, _mask
);
14271 return NextCmdAddress
<ValueType
>(cmd
);
14274 gpu::CommandHeader header
;
14280 static_assert(sizeof(StencilFillPathCHROMIUM
) == 16,
14281 "size of StencilFillPathCHROMIUM should be 16");
14282 static_assert(offsetof(StencilFillPathCHROMIUM
, header
) == 0,
14283 "offset of StencilFillPathCHROMIUM header should be 0");
14284 static_assert(offsetof(StencilFillPathCHROMIUM
, path
) == 4,
14285 "offset of StencilFillPathCHROMIUM path should be 4");
14286 static_assert(offsetof(StencilFillPathCHROMIUM
, fillMode
) == 8,
14287 "offset of StencilFillPathCHROMIUM fillMode should be 8");
14288 static_assert(offsetof(StencilFillPathCHROMIUM
, mask
) == 12,
14289 "offset of StencilFillPathCHROMIUM mask should be 12");
14291 struct StencilStrokePathCHROMIUM
{
14292 typedef StencilStrokePathCHROMIUM ValueType
;
14293 static const CommandId kCmdId
= kStencilStrokePathCHROMIUM
;
14294 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14295 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14297 static uint32_t ComputeSize() {
14298 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14301 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14303 void Init(GLuint _path
, GLint _reference
, GLuint _mask
) {
14306 reference
= _reference
;
14310 void* Set(void* cmd
, GLuint _path
, GLint _reference
, GLuint _mask
) {
14311 static_cast<ValueType
*>(cmd
)->Init(_path
, _reference
, _mask
);
14312 return NextCmdAddress
<ValueType
>(cmd
);
14315 gpu::CommandHeader header
;
14321 static_assert(sizeof(StencilStrokePathCHROMIUM
) == 16,
14322 "size of StencilStrokePathCHROMIUM should be 16");
14323 static_assert(offsetof(StencilStrokePathCHROMIUM
, header
) == 0,
14324 "offset of StencilStrokePathCHROMIUM header should be 0");
14325 static_assert(offsetof(StencilStrokePathCHROMIUM
, path
) == 4,
14326 "offset of StencilStrokePathCHROMIUM path should be 4");
14327 static_assert(offsetof(StencilStrokePathCHROMIUM
, reference
) == 8,
14328 "offset of StencilStrokePathCHROMIUM reference should be 8");
14329 static_assert(offsetof(StencilStrokePathCHROMIUM
, mask
) == 12,
14330 "offset of StencilStrokePathCHROMIUM mask should be 12");
14332 struct CoverFillPathCHROMIUM
{
14333 typedef CoverFillPathCHROMIUM ValueType
;
14334 static const CommandId kCmdId
= kCoverFillPathCHROMIUM
;
14335 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14336 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14338 static uint32_t ComputeSize() {
14339 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14342 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14344 void Init(GLuint _path
, GLenum _coverMode
) {
14347 coverMode
= _coverMode
;
14350 void* Set(void* cmd
, GLuint _path
, GLenum _coverMode
) {
14351 static_cast<ValueType
*>(cmd
)->Init(_path
, _coverMode
);
14352 return NextCmdAddress
<ValueType
>(cmd
);
14355 gpu::CommandHeader header
;
14357 uint32_t coverMode
;
14360 static_assert(sizeof(CoverFillPathCHROMIUM
) == 12,
14361 "size of CoverFillPathCHROMIUM should be 12");
14362 static_assert(offsetof(CoverFillPathCHROMIUM
, header
) == 0,
14363 "offset of CoverFillPathCHROMIUM header should be 0");
14364 static_assert(offsetof(CoverFillPathCHROMIUM
, path
) == 4,
14365 "offset of CoverFillPathCHROMIUM path should be 4");
14366 static_assert(offsetof(CoverFillPathCHROMIUM
, coverMode
) == 8,
14367 "offset of CoverFillPathCHROMIUM coverMode should be 8");
14369 struct CoverStrokePathCHROMIUM
{
14370 typedef CoverStrokePathCHROMIUM ValueType
;
14371 static const CommandId kCmdId
= kCoverStrokePathCHROMIUM
;
14372 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14373 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14375 static uint32_t ComputeSize() {
14376 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14379 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14381 void Init(GLuint _path
, GLenum _coverMode
) {
14384 coverMode
= _coverMode
;
14387 void* Set(void* cmd
, GLuint _path
, GLenum _coverMode
) {
14388 static_cast<ValueType
*>(cmd
)->Init(_path
, _coverMode
);
14389 return NextCmdAddress
<ValueType
>(cmd
);
14392 gpu::CommandHeader header
;
14394 uint32_t coverMode
;
14397 static_assert(sizeof(CoverStrokePathCHROMIUM
) == 12,
14398 "size of CoverStrokePathCHROMIUM should be 12");
14399 static_assert(offsetof(CoverStrokePathCHROMIUM
, header
) == 0,
14400 "offset of CoverStrokePathCHROMIUM header should be 0");
14401 static_assert(offsetof(CoverStrokePathCHROMIUM
, path
) == 4,
14402 "offset of CoverStrokePathCHROMIUM path should be 4");
14403 static_assert(offsetof(CoverStrokePathCHROMIUM
, coverMode
) == 8,
14404 "offset of CoverStrokePathCHROMIUM coverMode should be 8");
14406 struct StencilThenCoverFillPathCHROMIUM
{
14407 typedef StencilThenCoverFillPathCHROMIUM ValueType
;
14408 static const CommandId kCmdId
= kStencilThenCoverFillPathCHROMIUM
;
14409 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14410 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14412 static uint32_t ComputeSize() {
14413 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14416 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14418 void Init(GLuint _path
, GLenum _fillMode
, GLuint _mask
, GLenum _coverMode
) {
14421 fillMode
= _fillMode
;
14423 coverMode
= _coverMode
;
14426 void* Set(void* cmd
,
14430 GLenum _coverMode
) {
14431 static_cast<ValueType
*>(cmd
)->Init(_path
, _fillMode
, _mask
, _coverMode
);
14432 return NextCmdAddress
<ValueType
>(cmd
);
14435 gpu::CommandHeader header
;
14439 uint32_t coverMode
;
14442 static_assert(sizeof(StencilThenCoverFillPathCHROMIUM
) == 20,
14443 "size of StencilThenCoverFillPathCHROMIUM should be 20");
14444 static_assert(offsetof(StencilThenCoverFillPathCHROMIUM
, header
) == 0,
14445 "offset of StencilThenCoverFillPathCHROMIUM header should be 0");
14446 static_assert(offsetof(StencilThenCoverFillPathCHROMIUM
, path
) == 4,
14447 "offset of StencilThenCoverFillPathCHROMIUM path should be 4");
14449 offsetof(StencilThenCoverFillPathCHROMIUM
, fillMode
) == 8,
14450 "offset of StencilThenCoverFillPathCHROMIUM fillMode should be 8");
14451 static_assert(offsetof(StencilThenCoverFillPathCHROMIUM
, mask
) == 12,
14452 "offset of StencilThenCoverFillPathCHROMIUM mask should be 12");
14454 offsetof(StencilThenCoverFillPathCHROMIUM
, coverMode
) == 16,
14455 "offset of StencilThenCoverFillPathCHROMIUM coverMode should be 16");
14457 struct StencilThenCoverStrokePathCHROMIUM
{
14458 typedef StencilThenCoverStrokePathCHROMIUM ValueType
;
14459 static const CommandId kCmdId
= kStencilThenCoverStrokePathCHROMIUM
;
14460 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14461 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14463 static uint32_t ComputeSize() {
14464 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14467 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14469 void Init(GLuint _path
, GLint _reference
, GLuint _mask
, GLenum _coverMode
) {
14472 reference
= _reference
;
14474 coverMode
= _coverMode
;
14477 void* Set(void* cmd
,
14481 GLenum _coverMode
) {
14482 static_cast<ValueType
*>(cmd
)->Init(_path
, _reference
, _mask
, _coverMode
);
14483 return NextCmdAddress
<ValueType
>(cmd
);
14486 gpu::CommandHeader header
;
14490 uint32_t coverMode
;
14493 static_assert(sizeof(StencilThenCoverStrokePathCHROMIUM
) == 20,
14494 "size of StencilThenCoverStrokePathCHROMIUM should be 20");
14496 offsetof(StencilThenCoverStrokePathCHROMIUM
, header
) == 0,
14497 "offset of StencilThenCoverStrokePathCHROMIUM header should be 0");
14498 static_assert(offsetof(StencilThenCoverStrokePathCHROMIUM
, path
) == 4,
14499 "offset of StencilThenCoverStrokePathCHROMIUM path should be 4");
14501 offsetof(StencilThenCoverStrokePathCHROMIUM
, reference
) == 8,
14502 "offset of StencilThenCoverStrokePathCHROMIUM reference should be 8");
14503 static_assert(offsetof(StencilThenCoverStrokePathCHROMIUM
, mask
) == 12,
14504 "offset of StencilThenCoverStrokePathCHROMIUM mask should be 12");
14506 offsetof(StencilThenCoverStrokePathCHROMIUM
, coverMode
) == 16,
14507 "offset of StencilThenCoverStrokePathCHROMIUM coverMode should be 16");
14509 struct BlendBarrierKHR
{
14510 typedef BlendBarrierKHR ValueType
;
14511 static const CommandId kCmdId
= kBlendBarrierKHR
;
14512 static const cmd::ArgFlags kArgFlags
= cmd::kFixed
;
14513 static const uint8 cmd_flags
= CMD_FLAG_SET_TRACE_LEVEL(3);
14515 static uint32_t ComputeSize() {
14516 return static_cast<uint32_t>(sizeof(ValueType
)); // NOLINT
14519 void SetHeader() { header
.SetCmd
<ValueType
>(); }
14521 void Init() { SetHeader(); }
14523 void* Set(void* cmd
) {
14524 static_cast<ValueType
*>(cmd
)->Init();
14525 return NextCmdAddress
<ValueType
>(cmd
);
14528 gpu::CommandHeader header
;
14531 static_assert(sizeof(BlendBarrierKHR
) == 4,
14532 "size of BlendBarrierKHR should be 4");
14533 static_assert(offsetof(BlendBarrierKHR
, header
) == 0,
14534 "offset of BlendBarrierKHR header should be 0");
14536 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_