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

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

Issue 793693003: Tile Compression (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 9044 matching lines...) Expand 10 before | Expand all | Expand 10 after
9055 OffsetOf_CopyTextureCHROMIUM_source_id_not_8); 9055 OffsetOf_CopyTextureCHROMIUM_source_id_not_8);
9056 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, dest_id) == 12, 9056 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, dest_id) == 12,
9057 OffsetOf_CopyTextureCHROMIUM_dest_id_not_12); 9057 OffsetOf_CopyTextureCHROMIUM_dest_id_not_12);
9058 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, level) == 16, 9058 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, level) == 16,
9059 OffsetOf_CopyTextureCHROMIUM_level_not_16); 9059 OffsetOf_CopyTextureCHROMIUM_level_not_16);
9060 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, internalformat) == 20, 9060 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, internalformat) == 20,
9061 OffsetOf_CopyTextureCHROMIUM_internalformat_not_20); 9061 OffsetOf_CopyTextureCHROMIUM_internalformat_not_20);
9062 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, dest_type) == 24, 9062 COMPILE_ASSERT(offsetof(CopyTextureCHROMIUM, dest_type) == 24,
9063 OffsetOf_CopyTextureCHROMIUM_dest_type_not_24); 9063 OffsetOf_CopyTextureCHROMIUM_dest_type_not_24);
9064 9064
9065 struct CopyCompressedTextureCHROMIUM {
9066 typedef CopyCompressedTextureCHROMIUM ValueType;
9067 static const CommandId kCmdId = kCopyCompressedTextureCHROMIUM;
9068 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
9069 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
9070
9071 static uint32_t ComputeSize() {
9072 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
9073 }
9074
9075 void SetHeader() { header.SetCmd<ValueType>(); }
9076
9077 void Init(GLenum _target,
9078 GLenum _source_id,
9079 GLenum _dest_id,
9080 GLenum _internalformat,
9081 GLenum _dest_type) {
9082 SetHeader();
9083 target = _target;
9084 source_id = _source_id;
9085 dest_id = _dest_id;
9086 internalformat = _internalformat;
9087 dest_type = _dest_type;
9088 }
9089
9090 void* Set(void* cmd,
9091 GLenum _target,
9092 GLenum _source_id,
9093 GLenum _dest_id,
9094 GLenum _internalformat,
9095 GLenum _dest_type) {
9096 static_cast<ValueType*>(cmd)
9097 ->Init(_target, _source_id, _dest_id, _internalformat, _dest_type);
9098 return NextCmdAddress<ValueType>(cmd);
9099 }
9100
9101 gpu::CommandHeader header;
9102 uint32_t target;
9103 uint32_t source_id;
9104 uint32_t dest_id;
9105 uint32_t internalformat;
9106 uint32_t dest_type;
9107 };
9108
9109 COMPILE_ASSERT(sizeof(CopyCompressedTextureCHROMIUM) == 24,
9110 Sizeof_CopyCompressedTextureCHROMIUM_is_not_24);
9111 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, header) == 0,
9112 OffsetOf_CopyCompressedTextureCHROMIUM_header_not_0);
9113 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, target) == 4,
9114 OffsetOf_CopyCompressedTextureCHROMIUM_target_not_4);
9115 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, source_id) == 8,
9116 OffsetOf_CopyCompressedTextureCHROMIUM_source_id_not_8);
9117 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, dest_id) == 12,
9118 OffsetOf_CopyCompressedTextureCHROMIUM_dest_id_not_12);
9119 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, internalformat) == 16,
9120 OffsetOf_CopyCompressedTextureCHROMIUM_internalformat_not_16);
9121 COMPILE_ASSERT(offsetof(CopyCompressedTextureCHROMIUM, dest_type) == 20,
9122 OffsetOf_CopyCompressedTextureCHROMIUM_dest_type_not_20);
9123
9065 struct DrawArraysInstancedANGLE { 9124 struct DrawArraysInstancedANGLE {
9066 typedef DrawArraysInstancedANGLE ValueType; 9125 typedef DrawArraysInstancedANGLE ValueType;
9067 static const CommandId kCmdId = kDrawArraysInstancedANGLE; 9126 static const CommandId kCmdId = kDrawArraysInstancedANGLE;
9068 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 9127 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
9069 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); 9128 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
9070 9129
9071 static uint32_t ComputeSize() { 9130 static uint32_t ComputeSize() {
9072 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT 9131 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
9073 } 9132 }
9074 9133
(...skipping 928 matching lines...) Expand 10 before | Expand all | Expand 10 after
10003 OffsetOf_AsyncTexImage2DCHROMIUM_pixels_shm_id_not_32); 10062 OffsetOf_AsyncTexImage2DCHROMIUM_pixels_shm_id_not_32);
10004 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, pixels_shm_offset) == 36, 10063 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, pixels_shm_offset) == 36,
10005 OffsetOf_AsyncTexImage2DCHROMIUM_pixels_shm_offset_not_36); 10064 OffsetOf_AsyncTexImage2DCHROMIUM_pixels_shm_offset_not_36);
10006 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, async_upload_token) == 40, 10065 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, async_upload_token) == 40,
10007 OffsetOf_AsyncTexImage2DCHROMIUM_async_upload_token_not_40); 10066 OffsetOf_AsyncTexImage2DCHROMIUM_async_upload_token_not_40);
10008 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, sync_data_shm_id) == 44, 10067 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, sync_data_shm_id) == 44,
10009 OffsetOf_AsyncTexImage2DCHROMIUM_sync_data_shm_id_not_44); 10068 OffsetOf_AsyncTexImage2DCHROMIUM_sync_data_shm_id_not_44);
10010 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, sync_data_shm_offset) == 48, 10069 COMPILE_ASSERT(offsetof(AsyncTexImage2DCHROMIUM, sync_data_shm_offset) == 48,
10011 OffsetOf_AsyncTexImage2DCHROMIUM_sync_data_shm_offset_not_48); 10070 OffsetOf_AsyncTexImage2DCHROMIUM_sync_data_shm_offset_not_48);
10012 10071
10072 struct AsyncCompressedTexSubImage2DCHROMIUM {
10073 typedef AsyncCompressedTexSubImage2DCHROMIUM ValueType;
10074 static const CommandId kCmdId = kAsyncCompressedTexSubImage2DCHROMIUM;
10075 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
10076 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
10077
10078 static uint32_t ComputeSize() {
10079 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
10080 }
10081
10082 void SetHeader() { header.SetCmd<ValueType>(); }
10083
10084 void Init(GLenum _target,
10085 GLint _level,
10086 GLint _xoffset,
10087 GLint _yoffset,
10088 GLsizei _width,
10089 GLsizei _height,
10090 GLenum _format,
10091 GLsizei _imagesize,
10092 uint32_t _data_shm_id,
10093 uint32_t _data_shm_offset,
10094 uint32_t _async_upload_token,
10095 uint32_t _sync_data_shm_id,
10096 uint32_t _sync_data_shm_offset) {
10097 SetHeader();
10098 target = _target;
10099 level = _level;
10100 xoffset = _xoffset;
10101 yoffset = _yoffset;
10102 width = _width;
10103 height = _height;
10104 format = _format;
10105 imagesize = _imagesize;
10106 data_shm_id = _data_shm_id;
10107 data_shm_offset = _data_shm_offset;
10108 async_upload_token = _async_upload_token;
10109 sync_data_shm_id = _sync_data_shm_id;
10110 sync_data_shm_offset = _sync_data_shm_offset;
10111 }
10112
10113 void* Set(void* cmd,
10114 GLenum _target,
10115 GLint _level,
10116 GLint _xoffset,
10117 GLint _yoffset,
10118 GLsizei _width,
10119 GLsizei _height,
10120 GLenum _format,
10121 GLsizei _imagesize,
10122 uint32_t _data_shm_id,
10123 uint32_t _data_shm_offset,
10124 uint32_t _async_upload_token,
10125 uint32_t _sync_data_shm_id,
10126 uint32_t _sync_data_shm_offset) {
10127 static_cast<ValueType*>(cmd)
10128 ->Init(_target, _level, _xoffset, _yoffset, _width, _height, _format,
10129 _imagesize, _data_shm_id, _data_shm_offset, _async_upload_token,
10130 _sync_data_shm_id, _sync_data_shm_offset);
10131 return NextCmdAddress<ValueType>(cmd);
10132 }
10133
10134 gpu::CommandHeader header;
10135 uint32_t target;
10136 int32_t level;
10137 int32_t xoffset;
10138 int32_t yoffset;
10139 int32_t width;
10140 int32_t height;
10141 uint32_t format;
10142 int32_t imagesize;
10143 uint32_t data_shm_id;
10144 uint32_t data_shm_offset;
10145 uint32_t async_upload_token;
10146 uint32_t sync_data_shm_id;
10147 uint32_t sync_data_shm_offset;
10148 };
10149
10150 COMPILE_ASSERT(sizeof(AsyncCompressedTexSubImage2DCHROMIUM) == 56,
10151 Sizeof_AsyncCompressedTexSubImage2DCHROMIUM_is_not_56);
10152 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, header) == 0,
10153 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_header_not_0);
10154 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, target) == 4,
10155 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_target_not_4);
10156 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, level) == 8,
10157 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_level_not_8);
10158 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, xoffset) == 12,
10159 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_xoffset_not_12);
10160 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, yoffset) == 16,
10161 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_yoffset_not_16);
10162 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, width) == 20,
10163 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_width_not_20);
10164 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, height) == 24,
10165 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_height_not_24);
10166 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, format) == 28,
10167 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_format_not_28);
10168 COMPILE_ASSERT(offsetof(AsyncCompressedTexSubImage2DCHROMIUM, imagesize) == 32,
10169 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_imagesize_not_32);
10170 COMPILE_ASSERT(
10171 offsetof(AsyncCompressedTexSubImage2DCHROMIUM, data_shm_id) == 36,
10172 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_data_shm_id_not_36);
10173 COMPILE_ASSERT(
10174 offsetof(AsyncCompressedTexSubImage2DCHROMIUM, data_shm_offset) == 40,
10175 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_data_shm_offset_not_40);
10176 COMPILE_ASSERT(
10177 offsetof(AsyncCompressedTexSubImage2DCHROMIUM, async_upload_token) == 44,
10178 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_async_upload_token_not_44);
10179 COMPILE_ASSERT(
10180 offsetof(AsyncCompressedTexSubImage2DCHROMIUM, sync_data_shm_id) == 48,
10181 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_sync_data_shm_id_not_48);
10182 COMPILE_ASSERT(
10183 offsetof(AsyncCompressedTexSubImage2DCHROMIUM, sync_data_shm_offset) == 52,
10184 OffsetOf_AsyncCompressedTexSubImage2DCHROMIUM_sync_data_shm_offset_not_52);
10185
10186 struct AsyncCompressedTexImage2DCHROMIUM {
10187 typedef AsyncCompressedTexImage2DCHROMIUM ValueType;
10188 static const CommandId kCmdId = kAsyncCompressedTexImage2DCHROMIUM;
10189 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
10190 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
10191
10192 static uint32_t ComputeSize() {
10193 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
10194 }
10195
10196 void SetHeader() { header.SetCmd<ValueType>(); }
10197
10198 void Init(GLenum _target,
10199 GLint _level,
10200 GLint _internalformat,
10201 GLsizei _width,
10202 GLsizei _height,
10203 GLsizei _imagesize,
10204 uint32_t _pixels_shm_id,
10205 uint32_t _pixels_shm_offset,
10206 uint32_t _async_upload_token,
10207 uint32_t _sync_data_shm_id,
10208 uint32_t _sync_data_shm_offset) {
10209 SetHeader();
10210 target = _target;
10211 level = _level;
10212 internalformat = _internalformat;
10213 width = _width;
10214 height = _height;
10215 imagesize = _imagesize;
10216 pixels_shm_id = _pixels_shm_id;
10217 pixels_shm_offset = _pixels_shm_offset;
10218 async_upload_token = _async_upload_token;
10219 sync_data_shm_id = _sync_data_shm_id;
10220 sync_data_shm_offset = _sync_data_shm_offset;
10221 }
10222
10223 void* Set(void* cmd,
10224 GLenum _target,
10225 GLint _level,
10226 GLint _internalformat,
10227 GLsizei _width,
10228 GLsizei _height,
10229 GLsizei _imagesize,
10230 uint32_t _pixels_shm_id,
10231 uint32_t _pixels_shm_offset,
10232 uint32_t _async_upload_token,
10233 uint32_t _sync_data_shm_id,
10234 uint32_t _sync_data_shm_offset) {
10235 static_cast<ValueType*>(cmd)
10236 ->Init(_target, _level, _internalformat, _width, _height, _imagesize,
10237 _pixels_shm_id, _pixels_shm_offset, _async_upload_token,
10238 _sync_data_shm_id, _sync_data_shm_offset);
10239 return NextCmdAddress<ValueType>(cmd);
10240 }
10241
10242 gpu::CommandHeader header;
10243 uint32_t target;
10244 int32_t level;
10245 int32_t internalformat;
10246 int32_t width;
10247 int32_t height;
10248 int32_t imagesize;
10249 uint32_t pixels_shm_id;
10250 uint32_t pixels_shm_offset;
10251 uint32_t async_upload_token;
10252 uint32_t sync_data_shm_id;
10253 uint32_t sync_data_shm_offset;
10254 static const int32_t border = 0;
10255 };
10256
10257 COMPILE_ASSERT(sizeof(AsyncCompressedTexImage2DCHROMIUM) == 48,
10258 Sizeof_AsyncCompressedTexImage2DCHROMIUM_is_not_48);
10259 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, header) == 0,
10260 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_header_not_0);
10261 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, target) == 4,
10262 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_target_not_4);
10263 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, level) == 8,
10264 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_level_not_8);
10265 COMPILE_ASSERT(
10266 offsetof(AsyncCompressedTexImage2DCHROMIUM, internalformat) == 12,
10267 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_internalformat_not_12);
10268 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, width) == 16,
10269 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_width_not_16);
10270 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, height) == 20,
10271 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_height_not_20);
10272 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, imagesize) == 24,
10273 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_imagesize_not_24);
10274 COMPILE_ASSERT(offsetof(AsyncCompressedTexImage2DCHROMIUM, pixels_shm_id) == 28,
10275 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_pixels_shm_id_not_28);
10276 COMPILE_ASSERT(
10277 offsetof(AsyncCompressedTexImage2DCHROMIUM, pixels_shm_offset) == 32,
10278 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_pixels_shm_offset_not_32);
10279 COMPILE_ASSERT(
10280 offsetof(AsyncCompressedTexImage2DCHROMIUM, async_upload_token) == 36,
10281 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_async_upload_token_not_36);
10282 COMPILE_ASSERT(
10283 offsetof(AsyncCompressedTexImage2DCHROMIUM, sync_data_shm_id) == 40,
10284 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_sync_data_shm_id_not_40);
10285 COMPILE_ASSERT(
10286 offsetof(AsyncCompressedTexImage2DCHROMIUM, sync_data_shm_offset) == 44,
10287 OffsetOf_AsyncCompressedTexImage2DCHROMIUM_sync_data_shm_offset_not_44);
10288
10013 struct WaitAsyncTexImage2DCHROMIUM { 10289 struct WaitAsyncTexImage2DCHROMIUM {
10014 typedef WaitAsyncTexImage2DCHROMIUM ValueType; 10290 typedef WaitAsyncTexImage2DCHROMIUM ValueType;
10015 static const CommandId kCmdId = kWaitAsyncTexImage2DCHROMIUM; 10291 static const CommandId kCmdId = kWaitAsyncTexImage2DCHROMIUM;
10016 static const cmd::ArgFlags kArgFlags = cmd::kFixed; 10292 static const cmd::ArgFlags kArgFlags = cmd::kFixed;
10017 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3); 10293 static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
10018 10294
10019 static uint32_t ComputeSize() { 10295 static uint32_t ComputeSize() {
10020 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT 10296 return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
10021 } 10297 }
10022 10298
(...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after
10480 } 10756 }
10481 10757
10482 gpu::CommandHeader header; 10758 gpu::CommandHeader header;
10483 }; 10759 };
10484 10760
10485 COMPILE_ASSERT(sizeof(BlendBarrierKHR) == 4, Sizeof_BlendBarrierKHR_is_not_4); 10761 COMPILE_ASSERT(sizeof(BlendBarrierKHR) == 4, Sizeof_BlendBarrierKHR_is_not_4);
10486 COMPILE_ASSERT(offsetof(BlendBarrierKHR, header) == 0, 10762 COMPILE_ASSERT(offsetof(BlendBarrierKHR, header) == 0,
10487 OffsetOf_BlendBarrierKHR_header_not_0); 10763 OffsetOf_BlendBarrierKHR_header_not_0);
10488 10764
10489 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_ 10765 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/capabilities.cc ('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