OLD | NEW |
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 827 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
838 | 838 |
839 gpu::CommandHeader header; | 839 gpu::CommandHeader header; |
840 uint32_t mask; | 840 uint32_t mask; |
841 }; | 841 }; |
842 | 842 |
843 static_assert(sizeof(Clear) == 8, "size of Clear should be 8"); | 843 static_assert(sizeof(Clear) == 8, "size of Clear should be 8"); |
844 static_assert(offsetof(Clear, header) == 0, | 844 static_assert(offsetof(Clear, header) == 0, |
845 "offset of Clear header should be 0"); | 845 "offset of Clear header should be 0"); |
846 static_assert(offsetof(Clear, mask) == 4, "offset of Clear mask should be 4"); | 846 static_assert(offsetof(Clear, mask) == 4, "offset of Clear mask should be 4"); |
847 | 847 |
| 848 struct ClearBufferfi { |
| 849 typedef ClearBufferfi ValueType; |
| 850 static const CommandId kCmdId = kClearBufferfi; |
| 851 static const cmd::ArgFlags kArgFlags = cmd::kFixed; |
| 852 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
| 853 |
| 854 static uint32_t ComputeSize() { |
| 855 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT |
| 856 } |
| 857 |
| 858 void SetHeader() { header.SetCmd<ValueType>(); } |
| 859 |
| 860 void Init(GLenum _buffer, |
| 861 GLint _drawbuffers, |
| 862 GLfloat _depth, |
| 863 GLint _stencil) { |
| 864 SetHeader(); |
| 865 buffer = _buffer; |
| 866 drawbuffers = _drawbuffers; |
| 867 depth = _depth; |
| 868 stencil = _stencil; |
| 869 } |
| 870 |
| 871 void* Set(void* cmd, |
| 872 GLenum _buffer, |
| 873 GLint _drawbuffers, |
| 874 GLfloat _depth, |
| 875 GLint _stencil) { |
| 876 static_cast<ValueType*>(cmd)->Init(_buffer, _drawbuffers, _depth, _stencil); |
| 877 return NextCmdAddress<ValueType>(cmd); |
| 878 } |
| 879 |
| 880 gpu::CommandHeader header; |
| 881 uint32_t buffer; |
| 882 int32_t drawbuffers; |
| 883 float depth; |
| 884 int32_t stencil; |
| 885 }; |
| 886 |
| 887 static_assert(sizeof(ClearBufferfi) == 20, |
| 888 "size of ClearBufferfi should be 20"); |
| 889 static_assert(offsetof(ClearBufferfi, header) == 0, |
| 890 "offset of ClearBufferfi header should be 0"); |
| 891 static_assert(offsetof(ClearBufferfi, buffer) == 4, |
| 892 "offset of ClearBufferfi buffer should be 4"); |
| 893 static_assert(offsetof(ClearBufferfi, drawbuffers) == 8, |
| 894 "offset of ClearBufferfi drawbuffers should be 8"); |
| 895 static_assert(offsetof(ClearBufferfi, depth) == 12, |
| 896 "offset of ClearBufferfi depth should be 12"); |
| 897 static_assert(offsetof(ClearBufferfi, stencil) == 16, |
| 898 "offset of ClearBufferfi stencil should be 16"); |
| 899 |
| 900 struct ClearBufferfvImmediate { |
| 901 typedef ClearBufferfvImmediate ValueType; |
| 902 static const CommandId kCmdId = kClearBufferfvImmediate; |
| 903 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
| 904 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
| 905 |
| 906 static uint32_t ComputeDataSize() { |
| 907 return static_cast<uint32_t>(sizeof(GLfloat) * 4); |
| 908 } |
| 909 |
| 910 static uint32_t ComputeEffectiveDataSize(GLenum buffer) { |
| 911 return static_cast<uint32_t>(sizeof(GLfloat) * |
| 912 GLES2Util::CalcClearBufferfvDataCount(buffer)); |
| 913 } |
| 914 |
| 915 static uint32_t ComputeSize() { |
| 916 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
| 917 } |
| 918 |
| 919 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
| 920 |
| 921 void Init(GLenum _buffer, GLint _drawbuffers, const GLfloat* _value) { |
| 922 SetHeader(); |
| 923 buffer = _buffer; |
| 924 drawbuffers = _drawbuffers; |
| 925 memcpy(ImmediateDataAddress(this), _value, |
| 926 ComputeEffectiveDataSize(buffer)); |
| 927 DCHECK_GE(ComputeDataSize(), ComputeEffectiveDataSize(buffer)); |
| 928 char* pointer = reinterpret_cast<char*>(ImmediateDataAddress(this)) + |
| 929 ComputeEffectiveDataSize(buffer); |
| 930 memset(pointer, 0, ComputeDataSize() - ComputeEffectiveDataSize(buffer)); |
| 931 } |
| 932 |
| 933 void* Set(void* cmd, |
| 934 GLenum _buffer, |
| 935 GLint _drawbuffers, |
| 936 const GLfloat* _value) { |
| 937 static_cast<ValueType*>(cmd)->Init(_buffer, _drawbuffers, _value); |
| 938 const uint32_t size = ComputeSize(); |
| 939 return NextImmediateCmdAddressTotalSize<ValueType>(cmd, size); |
| 940 } |
| 941 |
| 942 gpu::CommandHeader header; |
| 943 uint32_t buffer; |
| 944 int32_t drawbuffers; |
| 945 }; |
| 946 |
| 947 static_assert(sizeof(ClearBufferfvImmediate) == 12, |
| 948 "size of ClearBufferfvImmediate should be 12"); |
| 949 static_assert(offsetof(ClearBufferfvImmediate, header) == 0, |
| 950 "offset of ClearBufferfvImmediate header should be 0"); |
| 951 static_assert(offsetof(ClearBufferfvImmediate, buffer) == 4, |
| 952 "offset of ClearBufferfvImmediate buffer should be 4"); |
| 953 static_assert(offsetof(ClearBufferfvImmediate, drawbuffers) == 8, |
| 954 "offset of ClearBufferfvImmediate drawbuffers should be 8"); |
| 955 |
| 956 struct ClearBufferivImmediate { |
| 957 typedef ClearBufferivImmediate ValueType; |
| 958 static const CommandId kCmdId = kClearBufferivImmediate; |
| 959 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
| 960 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
| 961 |
| 962 static uint32_t ComputeDataSize() { |
| 963 return static_cast<uint32_t>(sizeof(GLint) * 4); |
| 964 } |
| 965 |
| 966 static uint32_t ComputeEffectiveDataSize(GLenum buffer) { |
| 967 return static_cast<uint32_t>(sizeof(GLint) * |
| 968 GLES2Util::CalcClearBufferivDataCount(buffer)); |
| 969 } |
| 970 |
| 971 static uint32_t ComputeSize() { |
| 972 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
| 973 } |
| 974 |
| 975 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
| 976 |
| 977 void Init(GLenum _buffer, GLint _drawbuffers, const GLint* _value) { |
| 978 SetHeader(); |
| 979 buffer = _buffer; |
| 980 drawbuffers = _drawbuffers; |
| 981 memcpy(ImmediateDataAddress(this), _value, |
| 982 ComputeEffectiveDataSize(buffer)); |
| 983 DCHECK_GE(ComputeDataSize(), ComputeEffectiveDataSize(buffer)); |
| 984 char* pointer = reinterpret_cast<char*>(ImmediateDataAddress(this)) + |
| 985 ComputeEffectiveDataSize(buffer); |
| 986 memset(pointer, 0, ComputeDataSize() - ComputeEffectiveDataSize(buffer)); |
| 987 } |
| 988 |
| 989 void* Set(void* cmd, |
| 990 GLenum _buffer, |
| 991 GLint _drawbuffers, |
| 992 const GLint* _value) { |
| 993 static_cast<ValueType*>(cmd)->Init(_buffer, _drawbuffers, _value); |
| 994 const uint32_t size = ComputeSize(); |
| 995 return NextImmediateCmdAddressTotalSize<ValueType>(cmd, size); |
| 996 } |
| 997 |
| 998 gpu::CommandHeader header; |
| 999 uint32_t buffer; |
| 1000 int32_t drawbuffers; |
| 1001 }; |
| 1002 |
| 1003 static_assert(sizeof(ClearBufferivImmediate) == 12, |
| 1004 "size of ClearBufferivImmediate should be 12"); |
| 1005 static_assert(offsetof(ClearBufferivImmediate, header) == 0, |
| 1006 "offset of ClearBufferivImmediate header should be 0"); |
| 1007 static_assert(offsetof(ClearBufferivImmediate, buffer) == 4, |
| 1008 "offset of ClearBufferivImmediate buffer should be 4"); |
| 1009 static_assert(offsetof(ClearBufferivImmediate, drawbuffers) == 8, |
| 1010 "offset of ClearBufferivImmediate drawbuffers should be 8"); |
| 1011 |
| 1012 struct ClearBufferuivImmediate { |
| 1013 typedef ClearBufferuivImmediate ValueType; |
| 1014 static const CommandId kCmdId = kClearBufferuivImmediate; |
| 1015 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
| 1016 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
| 1017 |
| 1018 static uint32_t ComputeDataSize() { |
| 1019 return static_cast<uint32_t>(sizeof(GLuint) * 4); |
| 1020 } |
| 1021 |
| 1022 static uint32_t ComputeSize() { |
| 1023 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
| 1024 } |
| 1025 |
| 1026 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
| 1027 |
| 1028 void Init(GLenum _buffer, GLint _drawbuffers, const GLuint* _value) { |
| 1029 SetHeader(); |
| 1030 buffer = _buffer; |
| 1031 drawbuffers = _drawbuffers; |
| 1032 memcpy(ImmediateDataAddress(this), _value, ComputeDataSize()); |
| 1033 } |
| 1034 |
| 1035 void* Set(void* cmd, |
| 1036 GLenum _buffer, |
| 1037 GLint _drawbuffers, |
| 1038 const GLuint* _value) { |
| 1039 static_cast<ValueType*>(cmd)->Init(_buffer, _drawbuffers, _value); |
| 1040 const uint32_t size = ComputeSize(); |
| 1041 return NextImmediateCmdAddressTotalSize<ValueType>(cmd, size); |
| 1042 } |
| 1043 |
| 1044 gpu::CommandHeader header; |
| 1045 uint32_t buffer; |
| 1046 int32_t drawbuffers; |
| 1047 }; |
| 1048 |
| 1049 static_assert(sizeof(ClearBufferuivImmediate) == 12, |
| 1050 "size of ClearBufferuivImmediate should be 12"); |
| 1051 static_assert(offsetof(ClearBufferuivImmediate, header) == 0, |
| 1052 "offset of ClearBufferuivImmediate header should be 0"); |
| 1053 static_assert(offsetof(ClearBufferuivImmediate, buffer) == 4, |
| 1054 "offset of ClearBufferuivImmediate buffer should be 4"); |
| 1055 static_assert(offsetof(ClearBufferuivImmediate, drawbuffers) == 8, |
| 1056 "offset of ClearBufferuivImmediate drawbuffers should be 8"); |
| 1057 |
848 struct ClearColor { | 1058 struct ClearColor { |
849 typedef ClearColor ValueType; | 1059 typedef ClearColor ValueType; |
850 static const CommandId kCmdId = kClearColor; | 1060 static const CommandId kCmdId = kClearColor; |
851 static const cmd::ArgFlags kArgFlags = cmd::kFixed; | 1061 static const cmd::ArgFlags kArgFlags = cmd::kFixed; |
852 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 1062 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
853 | 1063 |
854 static uint32_t ComputeSize() { | 1064 static uint32_t ComputeSize() { |
855 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT | 1065 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT |
856 } | 1066 } |
857 | 1067 |
(...skipping 4644 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5502 static_assert(offsetof(SamplerParameterf, param) == 12, | 5712 static_assert(offsetof(SamplerParameterf, param) == 12, |
5503 "offset of SamplerParameterf param should be 12"); | 5713 "offset of SamplerParameterf param should be 12"); |
5504 | 5714 |
5505 struct SamplerParameterfvImmediate { | 5715 struct SamplerParameterfvImmediate { |
5506 typedef SamplerParameterfvImmediate ValueType; | 5716 typedef SamplerParameterfvImmediate ValueType; |
5507 static const CommandId kCmdId = kSamplerParameterfvImmediate; | 5717 static const CommandId kCmdId = kSamplerParameterfvImmediate; |
5508 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 5718 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
5509 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 5719 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
5510 | 5720 |
5511 static uint32_t ComputeDataSize() { | 5721 static uint32_t ComputeDataSize() { |
5512 return static_cast<uint32_t>(sizeof(GLfloat) * 1); // NOLINT | 5722 return static_cast<uint32_t>(sizeof(GLfloat) * 1); |
5513 } | 5723 } |
5514 | 5724 |
5515 static uint32_t ComputeSize() { | 5725 static uint32_t ComputeSize() { |
5516 return static_cast<uint32_t>(sizeof(ValueType) + | 5726 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
5517 ComputeDataSize()); // NOLINT | |
5518 } | 5727 } |
5519 | 5728 |
5520 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 5729 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
5521 | 5730 |
5522 void Init(GLuint _sampler, GLenum _pname, const GLfloat* _params) { | 5731 void Init(GLuint _sampler, GLenum _pname, const GLfloat* _params) { |
5523 SetHeader(); | 5732 SetHeader(); |
5524 sampler = _sampler; | 5733 sampler = _sampler; |
5525 pname = _pname; | 5734 pname = _pname; |
5526 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); | 5735 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); |
5527 } | 5736 } |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5587 static_assert(offsetof(SamplerParameteri, param) == 12, | 5796 static_assert(offsetof(SamplerParameteri, param) == 12, |
5588 "offset of SamplerParameteri param should be 12"); | 5797 "offset of SamplerParameteri param should be 12"); |
5589 | 5798 |
5590 struct SamplerParameterivImmediate { | 5799 struct SamplerParameterivImmediate { |
5591 typedef SamplerParameterivImmediate ValueType; | 5800 typedef SamplerParameterivImmediate ValueType; |
5592 static const CommandId kCmdId = kSamplerParameterivImmediate; | 5801 static const CommandId kCmdId = kSamplerParameterivImmediate; |
5593 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 5802 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
5594 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 5803 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
5595 | 5804 |
5596 static uint32_t ComputeDataSize() { | 5805 static uint32_t ComputeDataSize() { |
5597 return static_cast<uint32_t>(sizeof(GLint) * 1); // NOLINT | 5806 return static_cast<uint32_t>(sizeof(GLint) * 1); |
5598 } | 5807 } |
5599 | 5808 |
5600 static uint32_t ComputeSize() { | 5809 static uint32_t ComputeSize() { |
5601 return static_cast<uint32_t>(sizeof(ValueType) + | 5810 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
5602 ComputeDataSize()); // NOLINT | |
5603 } | 5811 } |
5604 | 5812 |
5605 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 5813 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
5606 | 5814 |
5607 void Init(GLuint _sampler, GLenum _pname, const GLint* _params) { | 5815 void Init(GLuint _sampler, GLenum _pname, const GLint* _params) { |
5608 SetHeader(); | 5816 SetHeader(); |
5609 sampler = _sampler; | 5817 sampler = _sampler; |
5610 pname = _pname; | 5818 pname = _pname; |
5611 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); | 5819 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); |
5612 } | 5820 } |
(...skipping 626 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6239 static_assert(offsetof(TexParameterf, param) == 12, | 6447 static_assert(offsetof(TexParameterf, param) == 12, |
6240 "offset of TexParameterf param should be 12"); | 6448 "offset of TexParameterf param should be 12"); |
6241 | 6449 |
6242 struct TexParameterfvImmediate { | 6450 struct TexParameterfvImmediate { |
6243 typedef TexParameterfvImmediate ValueType; | 6451 typedef TexParameterfvImmediate ValueType; |
6244 static const CommandId kCmdId = kTexParameterfvImmediate; | 6452 static const CommandId kCmdId = kTexParameterfvImmediate; |
6245 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 6453 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
6246 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 6454 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
6247 | 6455 |
6248 static uint32_t ComputeDataSize() { | 6456 static uint32_t ComputeDataSize() { |
6249 return static_cast<uint32_t>(sizeof(GLfloat) * 1); // NOLINT | 6457 return static_cast<uint32_t>(sizeof(GLfloat) * 1); |
6250 } | 6458 } |
6251 | 6459 |
6252 static uint32_t ComputeSize() { | 6460 static uint32_t ComputeSize() { |
6253 return static_cast<uint32_t>(sizeof(ValueType) + | 6461 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
6254 ComputeDataSize()); // NOLINT | |
6255 } | 6462 } |
6256 | 6463 |
6257 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 6464 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
6258 | 6465 |
6259 void Init(GLenum _target, GLenum _pname, const GLfloat* _params) { | 6466 void Init(GLenum _target, GLenum _pname, const GLfloat* _params) { |
6260 SetHeader(); | 6467 SetHeader(); |
6261 target = _target; | 6468 target = _target; |
6262 pname = _pname; | 6469 pname = _pname; |
6263 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); | 6470 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); |
6264 } | 6471 } |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6324 static_assert(offsetof(TexParameteri, param) == 12, | 6531 static_assert(offsetof(TexParameteri, param) == 12, |
6325 "offset of TexParameteri param should be 12"); | 6532 "offset of TexParameteri param should be 12"); |
6326 | 6533 |
6327 struct TexParameterivImmediate { | 6534 struct TexParameterivImmediate { |
6328 typedef TexParameterivImmediate ValueType; | 6535 typedef TexParameterivImmediate ValueType; |
6329 static const CommandId kCmdId = kTexParameterivImmediate; | 6536 static const CommandId kCmdId = kTexParameterivImmediate; |
6330 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 6537 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
6331 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 6538 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
6332 | 6539 |
6333 static uint32_t ComputeDataSize() { | 6540 static uint32_t ComputeDataSize() { |
6334 return static_cast<uint32_t>(sizeof(GLint) * 1); // NOLINT | 6541 return static_cast<uint32_t>(sizeof(GLint) * 1); |
6335 } | 6542 } |
6336 | 6543 |
6337 static uint32_t ComputeSize() { | 6544 static uint32_t ComputeSize() { |
6338 return static_cast<uint32_t>(sizeof(ValueType) + | 6545 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
6339 ComputeDataSize()); // NOLINT | |
6340 } | 6546 } |
6341 | 6547 |
6342 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 6548 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
6343 | 6549 |
6344 void Init(GLenum _target, GLenum _pname, const GLint* _params) { | 6550 void Init(GLenum _target, GLenum _pname, const GLint* _params) { |
6345 SetHeader(); | 6551 SetHeader(); |
6346 target = _target; | 6552 target = _target; |
6347 pname = _pname; | 6553 pname = _pname; |
6348 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); | 6554 memcpy(ImmediateDataAddress(this), _params, ComputeDataSize()); |
6349 } | 6555 } |
(...skipping 1874 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8224 static_assert(offsetof(VertexAttrib1f, x) == 8, | 8430 static_assert(offsetof(VertexAttrib1f, x) == 8, |
8225 "offset of VertexAttrib1f x should be 8"); | 8431 "offset of VertexAttrib1f x should be 8"); |
8226 | 8432 |
8227 struct VertexAttrib1fvImmediate { | 8433 struct VertexAttrib1fvImmediate { |
8228 typedef VertexAttrib1fvImmediate ValueType; | 8434 typedef VertexAttrib1fvImmediate ValueType; |
8229 static const CommandId kCmdId = kVertexAttrib1fvImmediate; | 8435 static const CommandId kCmdId = kVertexAttrib1fvImmediate; |
8230 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8436 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8231 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8437 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8232 | 8438 |
8233 static uint32_t ComputeDataSize() { | 8439 static uint32_t ComputeDataSize() { |
8234 return static_cast<uint32_t>(sizeof(GLfloat) * 1); // NOLINT | 8440 return static_cast<uint32_t>(sizeof(GLfloat) * 1); |
8235 } | 8441 } |
8236 | 8442 |
8237 static uint32_t ComputeSize() { | 8443 static uint32_t ComputeSize() { |
8238 return static_cast<uint32_t>(sizeof(ValueType) + | 8444 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8239 ComputeDataSize()); // NOLINT | |
8240 } | 8445 } |
8241 | 8446 |
8242 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8447 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8243 | 8448 |
8244 void Init(GLuint _indx, const GLfloat* _values) { | 8449 void Init(GLuint _indx, const GLfloat* _values) { |
8245 SetHeader(); | 8450 SetHeader(); |
8246 indx = _indx; | 8451 indx = _indx; |
8247 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8452 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8248 } | 8453 } |
8249 | 8454 |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8305 static_assert(offsetof(VertexAttrib2f, y) == 12, | 8510 static_assert(offsetof(VertexAttrib2f, y) == 12, |
8306 "offset of VertexAttrib2f y should be 12"); | 8511 "offset of VertexAttrib2f y should be 12"); |
8307 | 8512 |
8308 struct VertexAttrib2fvImmediate { | 8513 struct VertexAttrib2fvImmediate { |
8309 typedef VertexAttrib2fvImmediate ValueType; | 8514 typedef VertexAttrib2fvImmediate ValueType; |
8310 static const CommandId kCmdId = kVertexAttrib2fvImmediate; | 8515 static const CommandId kCmdId = kVertexAttrib2fvImmediate; |
8311 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8516 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8312 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8517 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8313 | 8518 |
8314 static uint32_t ComputeDataSize() { | 8519 static uint32_t ComputeDataSize() { |
8315 return static_cast<uint32_t>(sizeof(GLfloat) * 2); // NOLINT | 8520 return static_cast<uint32_t>(sizeof(GLfloat) * 2); |
8316 } | 8521 } |
8317 | 8522 |
8318 static uint32_t ComputeSize() { | 8523 static uint32_t ComputeSize() { |
8319 return static_cast<uint32_t>(sizeof(ValueType) + | 8524 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8320 ComputeDataSize()); // NOLINT | |
8321 } | 8525 } |
8322 | 8526 |
8323 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8527 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8324 | 8528 |
8325 void Init(GLuint _indx, const GLfloat* _values) { | 8529 void Init(GLuint _indx, const GLfloat* _values) { |
8326 SetHeader(); | 8530 SetHeader(); |
8327 indx = _indx; | 8531 indx = _indx; |
8328 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8532 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8329 } | 8533 } |
8330 | 8534 |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8390 static_assert(offsetof(VertexAttrib3f, z) == 16, | 8594 static_assert(offsetof(VertexAttrib3f, z) == 16, |
8391 "offset of VertexAttrib3f z should be 16"); | 8595 "offset of VertexAttrib3f z should be 16"); |
8392 | 8596 |
8393 struct VertexAttrib3fvImmediate { | 8597 struct VertexAttrib3fvImmediate { |
8394 typedef VertexAttrib3fvImmediate ValueType; | 8598 typedef VertexAttrib3fvImmediate ValueType; |
8395 static const CommandId kCmdId = kVertexAttrib3fvImmediate; | 8599 static const CommandId kCmdId = kVertexAttrib3fvImmediate; |
8396 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8600 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8397 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8601 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8398 | 8602 |
8399 static uint32_t ComputeDataSize() { | 8603 static uint32_t ComputeDataSize() { |
8400 return static_cast<uint32_t>(sizeof(GLfloat) * 3); // NOLINT | 8604 return static_cast<uint32_t>(sizeof(GLfloat) * 3); |
8401 } | 8605 } |
8402 | 8606 |
8403 static uint32_t ComputeSize() { | 8607 static uint32_t ComputeSize() { |
8404 return static_cast<uint32_t>(sizeof(ValueType) + | 8608 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8405 ComputeDataSize()); // NOLINT | |
8406 } | 8609 } |
8407 | 8610 |
8408 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8611 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8409 | 8612 |
8410 void Init(GLuint _indx, const GLfloat* _values) { | 8613 void Init(GLuint _indx, const GLfloat* _values) { |
8411 SetHeader(); | 8614 SetHeader(); |
8412 indx = _indx; | 8615 indx = _indx; |
8413 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8616 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8414 } | 8617 } |
8415 | 8618 |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8484 static_assert(offsetof(VertexAttrib4f, w) == 20, | 8687 static_assert(offsetof(VertexAttrib4f, w) == 20, |
8485 "offset of VertexAttrib4f w should be 20"); | 8688 "offset of VertexAttrib4f w should be 20"); |
8486 | 8689 |
8487 struct VertexAttrib4fvImmediate { | 8690 struct VertexAttrib4fvImmediate { |
8488 typedef VertexAttrib4fvImmediate ValueType; | 8691 typedef VertexAttrib4fvImmediate ValueType; |
8489 static const CommandId kCmdId = kVertexAttrib4fvImmediate; | 8692 static const CommandId kCmdId = kVertexAttrib4fvImmediate; |
8490 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8693 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8491 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8694 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8492 | 8695 |
8493 static uint32_t ComputeDataSize() { | 8696 static uint32_t ComputeDataSize() { |
8494 return static_cast<uint32_t>(sizeof(GLfloat) * 4); // NOLINT | 8697 return static_cast<uint32_t>(sizeof(GLfloat) * 4); |
8495 } | 8698 } |
8496 | 8699 |
8497 static uint32_t ComputeSize() { | 8700 static uint32_t ComputeSize() { |
8498 return static_cast<uint32_t>(sizeof(ValueType) + | 8701 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8499 ComputeDataSize()); // NOLINT | |
8500 } | 8702 } |
8501 | 8703 |
8502 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8704 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8503 | 8705 |
8504 void Init(GLuint _indx, const GLfloat* _values) { | 8706 void Init(GLuint _indx, const GLfloat* _values) { |
8505 SetHeader(); | 8707 SetHeader(); |
8506 indx = _indx; | 8708 indx = _indx; |
8507 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8709 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8508 } | 8710 } |
8509 | 8711 |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8573 static_assert(offsetof(VertexAttribI4i, w) == 20, | 8775 static_assert(offsetof(VertexAttribI4i, w) == 20, |
8574 "offset of VertexAttribI4i w should be 20"); | 8776 "offset of VertexAttribI4i w should be 20"); |
8575 | 8777 |
8576 struct VertexAttribI4ivImmediate { | 8778 struct VertexAttribI4ivImmediate { |
8577 typedef VertexAttribI4ivImmediate ValueType; | 8779 typedef VertexAttribI4ivImmediate ValueType; |
8578 static const CommandId kCmdId = kVertexAttribI4ivImmediate; | 8780 static const CommandId kCmdId = kVertexAttribI4ivImmediate; |
8579 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8781 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8580 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8782 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8581 | 8783 |
8582 static uint32_t ComputeDataSize() { | 8784 static uint32_t ComputeDataSize() { |
8583 return static_cast<uint32_t>(sizeof(GLint) * 4); // NOLINT | 8785 return static_cast<uint32_t>(sizeof(GLint) * 4); |
8584 } | 8786 } |
8585 | 8787 |
8586 static uint32_t ComputeSize() { | 8788 static uint32_t ComputeSize() { |
8587 return static_cast<uint32_t>(sizeof(ValueType) + | 8789 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8588 ComputeDataSize()); // NOLINT | |
8589 } | 8790 } |
8590 | 8791 |
8591 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8792 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8592 | 8793 |
8593 void Init(GLuint _indx, const GLint* _values) { | 8794 void Init(GLuint _indx, const GLint* _values) { |
8594 SetHeader(); | 8795 SetHeader(); |
8595 indx = _indx; | 8796 indx = _indx; |
8596 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8797 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8597 } | 8798 } |
8598 | 8799 |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8667 static_assert(offsetof(VertexAttribI4ui, w) == 20, | 8868 static_assert(offsetof(VertexAttribI4ui, w) == 20, |
8668 "offset of VertexAttribI4ui w should be 20"); | 8869 "offset of VertexAttribI4ui w should be 20"); |
8669 | 8870 |
8670 struct VertexAttribI4uivImmediate { | 8871 struct VertexAttribI4uivImmediate { |
8671 typedef VertexAttribI4uivImmediate ValueType; | 8872 typedef VertexAttribI4uivImmediate ValueType; |
8672 static const CommandId kCmdId = kVertexAttribI4uivImmediate; | 8873 static const CommandId kCmdId = kVertexAttribI4uivImmediate; |
8673 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 8874 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
8674 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 8875 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
8675 | 8876 |
8676 static uint32_t ComputeDataSize() { | 8877 static uint32_t ComputeDataSize() { |
8677 return static_cast<uint32_t>(sizeof(GLuint) * 4); // NOLINT | 8878 return static_cast<uint32_t>(sizeof(GLuint) * 4); |
8678 } | 8879 } |
8679 | 8880 |
8680 static uint32_t ComputeSize() { | 8881 static uint32_t ComputeSize() { |
8681 return static_cast<uint32_t>(sizeof(ValueType) + | 8882 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
8682 ComputeDataSize()); // NOLINT | |
8683 } | 8883 } |
8684 | 8884 |
8685 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 8885 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
8686 | 8886 |
8687 void Init(GLuint _indx, const GLuint* _values) { | 8887 void Init(GLuint _indx, const GLuint* _values) { |
8688 SetHeader(); | 8888 SetHeader(); |
8689 indx = _indx; | 8889 indx = _indx; |
8690 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); | 8890 memcpy(ImmediateDataAddress(this), _values, ComputeDataSize()); |
8691 } | 8891 } |
8692 | 8892 |
(...skipping 1670 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10363 static_assert(offsetof(VertexAttribDivisorANGLE, divisor) == 8, | 10563 static_assert(offsetof(VertexAttribDivisorANGLE, divisor) == 8, |
10364 "offset of VertexAttribDivisorANGLE divisor should be 8"); | 10564 "offset of VertexAttribDivisorANGLE divisor should be 8"); |
10365 | 10565 |
10366 struct ProduceTextureCHROMIUMImmediate { | 10566 struct ProduceTextureCHROMIUMImmediate { |
10367 typedef ProduceTextureCHROMIUMImmediate ValueType; | 10567 typedef ProduceTextureCHROMIUMImmediate ValueType; |
10368 static const CommandId kCmdId = kProduceTextureCHROMIUMImmediate; | 10568 static const CommandId kCmdId = kProduceTextureCHROMIUMImmediate; |
10369 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 10569 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
10370 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); | 10570 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); |
10371 | 10571 |
10372 static uint32_t ComputeDataSize() { | 10572 static uint32_t ComputeDataSize() { |
10373 return static_cast<uint32_t>(sizeof(GLbyte) * 64); // NOLINT | 10573 return static_cast<uint32_t>(sizeof(GLbyte) * 64); |
10374 } | 10574 } |
10375 | 10575 |
10376 static uint32_t ComputeSize() { | 10576 static uint32_t ComputeSize() { |
10377 return static_cast<uint32_t>(sizeof(ValueType) + | 10577 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
10378 ComputeDataSize()); // NOLINT | |
10379 } | 10578 } |
10380 | 10579 |
10381 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 10580 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
10382 | 10581 |
10383 void Init(GLenum _target, const GLbyte* _mailbox) { | 10582 void Init(GLenum _target, const GLbyte* _mailbox) { |
10384 SetHeader(); | 10583 SetHeader(); |
10385 target = _target; | 10584 target = _target; |
10386 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); | 10585 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); |
10387 } | 10586 } |
10388 | 10587 |
(...skipping 14 matching lines...) Expand all Loading... |
10403 static_assert(offsetof(ProduceTextureCHROMIUMImmediate, target) == 4, | 10602 static_assert(offsetof(ProduceTextureCHROMIUMImmediate, target) == 4, |
10404 "offset of ProduceTextureCHROMIUMImmediate target should be 4"); | 10603 "offset of ProduceTextureCHROMIUMImmediate target should be 4"); |
10405 | 10604 |
10406 struct ProduceTextureDirectCHROMIUMImmediate { | 10605 struct ProduceTextureDirectCHROMIUMImmediate { |
10407 typedef ProduceTextureDirectCHROMIUMImmediate ValueType; | 10606 typedef ProduceTextureDirectCHROMIUMImmediate ValueType; |
10408 static const CommandId kCmdId = kProduceTextureDirectCHROMIUMImmediate; | 10607 static const CommandId kCmdId = kProduceTextureDirectCHROMIUMImmediate; |
10409 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 10608 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
10410 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); | 10609 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); |
10411 | 10610 |
10412 static uint32_t ComputeDataSize() { | 10611 static uint32_t ComputeDataSize() { |
10413 return static_cast<uint32_t>(sizeof(GLbyte) * 64); // NOLINT | 10612 return static_cast<uint32_t>(sizeof(GLbyte) * 64); |
10414 } | 10613 } |
10415 | 10614 |
10416 static uint32_t ComputeSize() { | 10615 static uint32_t ComputeSize() { |
10417 return static_cast<uint32_t>(sizeof(ValueType) + | 10616 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
10418 ComputeDataSize()); // NOLINT | |
10419 } | 10617 } |
10420 | 10618 |
10421 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 10619 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
10422 | 10620 |
10423 void Init(GLuint _texture, GLenum _target, const GLbyte* _mailbox) { | 10621 void Init(GLuint _texture, GLenum _target, const GLbyte* _mailbox) { |
10424 SetHeader(); | 10622 SetHeader(); |
10425 texture = _texture; | 10623 texture = _texture; |
10426 target = _target; | 10624 target = _target; |
10427 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); | 10625 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); |
10428 } | 10626 } |
(...skipping 24 matching lines...) Expand all Loading... |
10453 offsetof(ProduceTextureDirectCHROMIUMImmediate, target) == 8, | 10651 offsetof(ProduceTextureDirectCHROMIUMImmediate, target) == 8, |
10454 "offset of ProduceTextureDirectCHROMIUMImmediate target should be 8"); | 10652 "offset of ProduceTextureDirectCHROMIUMImmediate target should be 8"); |
10455 | 10653 |
10456 struct ConsumeTextureCHROMIUMImmediate { | 10654 struct ConsumeTextureCHROMIUMImmediate { |
10457 typedef ConsumeTextureCHROMIUMImmediate ValueType; | 10655 typedef ConsumeTextureCHROMIUMImmediate ValueType; |
10458 static const CommandId kCmdId = kConsumeTextureCHROMIUMImmediate; | 10656 static const CommandId kCmdId = kConsumeTextureCHROMIUMImmediate; |
10459 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 10657 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
10460 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); | 10658 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(1); |
10461 | 10659 |
10462 static uint32_t ComputeDataSize() { | 10660 static uint32_t ComputeDataSize() { |
10463 return static_cast<uint32_t>(sizeof(GLbyte) * 64); // NOLINT | 10661 return static_cast<uint32_t>(sizeof(GLbyte) * 64); |
10464 } | 10662 } |
10465 | 10663 |
10466 static uint32_t ComputeSize() { | 10664 static uint32_t ComputeSize() { |
10467 return static_cast<uint32_t>(sizeof(ValueType) + | 10665 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
10468 ComputeDataSize()); // NOLINT | |
10469 } | 10666 } |
10470 | 10667 |
10471 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 10668 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
10472 | 10669 |
10473 void Init(GLenum _target, const GLbyte* _mailbox) { | 10670 void Init(GLenum _target, const GLbyte* _mailbox) { |
10474 SetHeader(); | 10671 SetHeader(); |
10475 target = _target; | 10672 target = _target; |
10476 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); | 10673 memcpy(ImmediateDataAddress(this), _mailbox, ComputeDataSize()); |
10477 } | 10674 } |
10478 | 10675 |
(...skipping 1084 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11563 static_assert(offsetof(SwapInterval, interval) == 4, | 11760 static_assert(offsetof(SwapInterval, interval) == 4, |
11564 "offset of SwapInterval interval should be 4"); | 11761 "offset of SwapInterval interval should be 4"); |
11565 | 11762 |
11566 struct MatrixLoadfCHROMIUMImmediate { | 11763 struct MatrixLoadfCHROMIUMImmediate { |
11567 typedef MatrixLoadfCHROMIUMImmediate ValueType; | 11764 typedef MatrixLoadfCHROMIUMImmediate ValueType; |
11568 static const CommandId kCmdId = kMatrixLoadfCHROMIUMImmediate; | 11765 static const CommandId kCmdId = kMatrixLoadfCHROMIUMImmediate; |
11569 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; | 11766 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN; |
11570 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); | 11767 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); |
11571 | 11768 |
11572 static uint32_t ComputeDataSize() { | 11769 static uint32_t ComputeDataSize() { |
11573 return static_cast<uint32_t>(sizeof(GLfloat) * 16); // NOLINT | 11770 return static_cast<uint32_t>(sizeof(GLfloat) * 16); |
11574 } | 11771 } |
11575 | 11772 |
11576 static uint32_t ComputeSize() { | 11773 static uint32_t ComputeSize() { |
11577 return static_cast<uint32_t>(sizeof(ValueType) + | 11774 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize()); |
11578 ComputeDataSize()); // NOLINT | |
11579 } | 11775 } |
11580 | 11776 |
11581 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } | 11777 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); } |
11582 | 11778 |
11583 void Init(GLenum _matrixMode, const GLfloat* _m) { | 11779 void Init(GLenum _matrixMode, const GLfloat* _m) { |
11584 SetHeader(); | 11780 SetHeader(); |
11585 matrixMode = _matrixMode; | 11781 matrixMode = _matrixMode; |
11586 memcpy(ImmediateDataAddress(this), _m, ComputeDataSize()); | 11782 memcpy(ImmediateDataAddress(this), _m, ComputeDataSize()); |
11587 } | 11783 } |
11588 | 11784 |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11657 | 11853 |
11658 gpu::CommandHeader header; | 11854 gpu::CommandHeader header; |
11659 }; | 11855 }; |
11660 | 11856 |
11661 static_assert(sizeof(BlendBarrierKHR) == 4, | 11857 static_assert(sizeof(BlendBarrierKHR) == 4, |
11662 "size of BlendBarrierKHR should be 4"); | 11858 "size of BlendBarrierKHR should be 4"); |
11663 static_assert(offsetof(BlendBarrierKHR, header) == 0, | 11859 static_assert(offsetof(BlendBarrierKHR, header) == 0, |
11664 "offset of BlendBarrierKHR header should be 0"); | 11860 "offset of BlendBarrierKHR header should be 0"); |
11665 | 11861 |
11666 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_ | 11862 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_ |
OLD | NEW |