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

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

Issue 903273002: Update from https://crrev.com/315085 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file is auto-generated from 5 // This file is auto-generated from
6 // gpu/command_buffer/build_gles2_cmd_buffer.py 6 // gpu/command_buffer/build_gles2_cmd_buffer.py
7 // It's formatted by clang-format using chromium coding style: 7 // It's formatted by clang-format using chromium coding style:
8 // clang-format -i -style=chromium filename 8 // clang-format -i -style=chromium filename
9 // DO NOT EDIT! 9 // DO NOT EDIT!
10 10
(...skipping 3356 matching lines...) Expand 10 before | Expand all | Expand 10 after
3367 static_assert(offsetof(GetActiveUniform::Result, success) == 0, 3367 static_assert(offsetof(GetActiveUniform::Result, success) == 0,
3368 "offset of GetActiveUniform Result success should be " 3368 "offset of GetActiveUniform Result success should be "
3369 "0"); 3369 "0");
3370 static_assert(offsetof(GetActiveUniform::Result, size) == 4, 3370 static_assert(offsetof(GetActiveUniform::Result, size) == 4,
3371 "offset of GetActiveUniform Result size should be " 3371 "offset of GetActiveUniform Result size should be "
3372 "4"); 3372 "4");
3373 static_assert(offsetof(GetActiveUniform::Result, type) == 8, 3373 static_assert(offsetof(GetActiveUniform::Result, type) == 8,
3374 "offset of GetActiveUniform Result type should be " 3374 "offset of GetActiveUniform Result type should be "
3375 "8"); 3375 "8");
3376 3376
3377 struct GetActiveUniformBlockName {
3378 typedef GetActiveUniformBlockName ValueType;
3379 static const CommandId kCmdId = kGetActiveUniformBlockName;
3380 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
3381 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
3382
3383 typedef int32_t Result;
3384
3385 static uint32_t ComputeSize() {
3386 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
3387 }
3388
3389 void SetHeader() { header.SetCmd<ValueType>(); }
3390
3391 void Init(GLuint _program,
3392 GLuint _index,
3393 uint32_t _name_bucket_id,
3394 uint32_t _result_shm_id,
3395 uint32_t _result_shm_offset) {
3396 SetHeader();
3397 program = _program;
3398 index = _index;
3399 name_bucket_id = _name_bucket_id;
3400 result_shm_id = _result_shm_id;
3401 result_shm_offset = _result_shm_offset;
3402 }
3403
3404 void* Set(void* cmd,
3405 GLuint _program,
3406 GLuint _index,
3407 uint32_t _name_bucket_id,
3408 uint32_t _result_shm_id,
3409 uint32_t _result_shm_offset) {
3410 static_cast<ValueType*>(cmd)->Init(_program, _index, _name_bucket_id,
3411 _result_shm_id, _result_shm_offset);
3412 return NextCmdAddress<ValueType>(cmd);
3413 }
3414
3415 gpu::CommandHeader header;
3416 uint32_t program;
3417 uint32_t index;
3418 uint32_t name_bucket_id;
3419 uint32_t result_shm_id;
3420 uint32_t result_shm_offset;
3421 };
3422
3423 static_assert(sizeof(GetActiveUniformBlockName) == 24,
3424 "size of GetActiveUniformBlockName should be 24");
3425 static_assert(offsetof(GetActiveUniformBlockName, header) == 0,
3426 "offset of GetActiveUniformBlockName header should be 0");
3427 static_assert(offsetof(GetActiveUniformBlockName, program) == 4,
3428 "offset of GetActiveUniformBlockName program should be 4");
3429 static_assert(offsetof(GetActiveUniformBlockName, index) == 8,
3430 "offset of GetActiveUniformBlockName index should be 8");
3431 static_assert(
3432 offsetof(GetActiveUniformBlockName, name_bucket_id) == 12,
3433 "offset of GetActiveUniformBlockName name_bucket_id should be 12");
3434 static_assert(offsetof(GetActiveUniformBlockName, result_shm_id) == 16,
3435 "offset of GetActiveUniformBlockName result_shm_id should be 16");
3436 static_assert(
3437 offsetof(GetActiveUniformBlockName, result_shm_offset) == 20,
3438 "offset of GetActiveUniformBlockName result_shm_offset should be 20");
3439
3377 struct GetAttachedShaders { 3440 struct GetAttachedShaders {
3378 typedef GetAttachedShaders ValueType; 3441 typedef GetAttachedShaders ValueType;
3379 static const CommandId kCmdId = kGetAttachedShaders; 3442 static const CommandId kCmdId = kGetAttachedShaders;
3380 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 3443 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
3381 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); 3444 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
3382 3445
3383 typedef SizedResult<GLuint> Result; 3446 typedef SizedResult<GLuint> Result;
3384 3447
3385 static uint32_t ComputeSize() { 3448 static uint32_t ComputeSize() {
3386 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT 3449 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
(...skipping 1122 matching lines...) Expand 10 before | Expand all | Expand 10 after
4509 "offset of GetTexParameteriv header should be 0"); 4572 "offset of GetTexParameteriv header should be 0");
4510 static_assert(offsetof(GetTexParameteriv, target) == 4, 4573 static_assert(offsetof(GetTexParameteriv, target) == 4,
4511 "offset of GetTexParameteriv target should be 4"); 4574 "offset of GetTexParameteriv target should be 4");
4512 static_assert(offsetof(GetTexParameteriv, pname) == 8, 4575 static_assert(offsetof(GetTexParameteriv, pname) == 8,
4513 "offset of GetTexParameteriv pname should be 8"); 4576 "offset of GetTexParameteriv pname should be 8");
4514 static_assert(offsetof(GetTexParameteriv, params_shm_id) == 12, 4577 static_assert(offsetof(GetTexParameteriv, params_shm_id) == 12,
4515 "offset of GetTexParameteriv params_shm_id should be 12"); 4578 "offset of GetTexParameteriv params_shm_id should be 12");
4516 static_assert(offsetof(GetTexParameteriv, params_shm_offset) == 16, 4579 static_assert(offsetof(GetTexParameteriv, params_shm_offset) == 16,
4517 "offset of GetTexParameteriv params_shm_offset should be 16"); 4580 "offset of GetTexParameteriv params_shm_offset should be 16");
4518 4581
4582 struct GetUniformBlockIndex {
4583 typedef GetUniformBlockIndex ValueType;
4584 static const CommandId kCmdId = kGetUniformBlockIndex;
4585 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
4586 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
4587
4588 typedef GLuint Result;
4589
4590 static uint32_t ComputeSize() {
4591 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
4592 }
4593
4594 void SetHeader() { header.SetCmd<ValueType>(); }
4595
4596 void Init(GLuint _program,
4597 uint32_t _name_bucket_id,
4598 uint32_t _index_shm_id,
4599 uint32_t _index_shm_offset) {
4600 SetHeader();
4601 program = _program;
4602 name_bucket_id = _name_bucket_id;
4603 index_shm_id = _index_shm_id;
4604 index_shm_offset = _index_shm_offset;
4605 }
4606
4607 void* Set(void* cmd,
4608 GLuint _program,
4609 uint32_t _name_bucket_id,
4610 uint32_t _index_shm_id,
4611 uint32_t _index_shm_offset) {
4612 static_cast<ValueType*>(cmd)
4613 ->Init(_program, _name_bucket_id, _index_shm_id, _index_shm_offset);
4614 return NextCmdAddress<ValueType>(cmd);
4615 }
4616
4617 gpu::CommandHeader header;
4618 uint32_t program;
4619 uint32_t name_bucket_id;
4620 uint32_t index_shm_id;
4621 uint32_t index_shm_offset;
4622 };
4623
4624 static_assert(sizeof(GetUniformBlockIndex) == 20,
4625 "size of GetUniformBlockIndex should be 20");
4626 static_assert(offsetof(GetUniformBlockIndex, header) == 0,
4627 "offset of GetUniformBlockIndex header should be 0");
4628 static_assert(offsetof(GetUniformBlockIndex, program) == 4,
4629 "offset of GetUniformBlockIndex program should be 4");
4630 static_assert(offsetof(GetUniformBlockIndex, name_bucket_id) == 8,
4631 "offset of GetUniformBlockIndex name_bucket_id should be 8");
4632 static_assert(offsetof(GetUniformBlockIndex, index_shm_id) == 12,
4633 "offset of GetUniformBlockIndex index_shm_id should be 12");
4634 static_assert(offsetof(GetUniformBlockIndex, index_shm_offset) == 16,
4635 "offset of GetUniformBlockIndex index_shm_offset should be 16");
4636
4519 struct GetUniformfv { 4637 struct GetUniformfv {
4520 typedef GetUniformfv ValueType; 4638 typedef GetUniformfv ValueType;
4521 static const CommandId kCmdId = kGetUniformfv; 4639 static const CommandId kCmdId = kGetUniformfv;
4522 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 4640 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
4523 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); 4641 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
4524 4642
4525 typedef SizedResult<GLfloat> Result; 4643 typedef SizedResult<GLfloat> Result;
4526 4644
4527 static uint32_t ComputeSize() { 4645 static uint32_t ComputeSize() {
4528 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT 4646 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
(...skipping 5976 matching lines...) Expand 10 before | Expand all | Expand 10 after
10505 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, link_status) == 0, 10623 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, link_status) == 0,
10506 "offset of GetProgramInfoCHROMIUM Result link_status should be " 10624 "offset of GetProgramInfoCHROMIUM Result link_status should be "
10507 "0"); 10625 "0");
10508 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, num_attribs) == 4, 10626 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, num_attribs) == 4,
10509 "offset of GetProgramInfoCHROMIUM Result num_attribs should be " 10627 "offset of GetProgramInfoCHROMIUM Result num_attribs should be "
10510 "4"); 10628 "4");
10511 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, num_uniforms) == 8, 10629 static_assert(offsetof(GetProgramInfoCHROMIUM::Result, num_uniforms) == 8,
10512 "offset of GetProgramInfoCHROMIUM Result num_uniforms should be " 10630 "offset of GetProgramInfoCHROMIUM Result num_uniforms should be "
10513 "8"); 10631 "8");
10514 10632
10633 struct GetUniformBlocksCHROMIUM {
10634 typedef GetUniformBlocksCHROMIUM ValueType;
10635 static const CommandId kCmdId = kGetUniformBlocksCHROMIUM;
10636 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
10637 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
10638
10639 typedef uint32_t Result;
10640
10641 static uint32_t ComputeSize() {
10642 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
10643 }
10644
10645 void SetHeader() { header.SetCmd<ValueType>(); }
10646
10647 void Init(GLuint _program, uint32_t _bucket_id) {
10648 SetHeader();
10649 program = _program;
10650 bucket_id = _bucket_id;
10651 }
10652
10653 void* Set(void* cmd, GLuint _program, uint32_t _bucket_id) {
10654 static_cast<ValueType*>(cmd)->Init(_program, _bucket_id);
10655 return NextCmdAddress<ValueType>(cmd);
10656 }
10657
10658 gpu::CommandHeader header;
10659 uint32_t program;
10660 uint32_t bucket_id;
10661 };
10662
10663 static_assert(sizeof(GetUniformBlocksCHROMIUM) == 12,
10664 "size of GetUniformBlocksCHROMIUM should be 12");
10665 static_assert(offsetof(GetUniformBlocksCHROMIUM, header) == 0,
10666 "offset of GetUniformBlocksCHROMIUM header should be 0");
10667 static_assert(offsetof(GetUniformBlocksCHROMIUM, program) == 4,
10668 "offset of GetUniformBlocksCHROMIUM program should be 4");
10669 static_assert(offsetof(GetUniformBlocksCHROMIUM, bucket_id) == 8,
10670 "offset of GetUniformBlocksCHROMIUM bucket_id should be 8");
10671
10515 struct GetTranslatedShaderSourceANGLE { 10672 struct GetTranslatedShaderSourceANGLE {
10516 typedef GetTranslatedShaderSourceANGLE ValueType; 10673 typedef GetTranslatedShaderSourceANGLE ValueType;
10517 static const CommandId kCmdId = kGetTranslatedShaderSourceANGLE; 10674 static const CommandId kCmdId = kGetTranslatedShaderSourceANGLE;
10518 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 10675 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
10519 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); 10676 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
10520 10677
10521 static uint32_t ComputeSize() { 10678 static uint32_t ComputeSize() {
10522 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT 10679 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
10523 } 10680 }
10524 10681
(...skipping 1628 matching lines...) Expand 10 before | Expand all | Expand 10 after
12153 12310
12154 gpu::CommandHeader header; 12311 gpu::CommandHeader header;
12155 }; 12312 };
12156 12313
12157 static_assert(sizeof(BlendBarrierKHR) == 4, 12314 static_assert(sizeof(BlendBarrierKHR) == 4,
12158 "size of BlendBarrierKHR should be 4"); 12315 "size of BlendBarrierKHR should be 4");
12159 static_assert(offsetof(BlendBarrierKHR, header) == 0, 12316 static_assert(offsetof(BlendBarrierKHR, header) == 0,
12160 "offset of BlendBarrierKHR header should be 0"); 12317 "offset of BlendBarrierKHR header should be 0");
12161 12318
12162 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_ 12319 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/command_buffer_mock.h ('k') | gpu/command_buffer/common/gles2_cmd_format_test_autogen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698