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

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

Issue 1559203003: Add GLStreamTextureImage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: s/GL_EXPORT/GPU_EXPORT for windows Created 4 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 15686 matching lines...) Expand 10 before | Expand all | Expand 10 after
15697 "offset of GetFragDataIndexEXT header should be 0"); 15697 "offset of GetFragDataIndexEXT header should be 0");
15698 static_assert(offsetof(GetFragDataIndexEXT, program) == 4, 15698 static_assert(offsetof(GetFragDataIndexEXT, program) == 4,
15699 "offset of GetFragDataIndexEXT program should be 4"); 15699 "offset of GetFragDataIndexEXT program should be 4");
15700 static_assert(offsetof(GetFragDataIndexEXT, name_bucket_id) == 8, 15700 static_assert(offsetof(GetFragDataIndexEXT, name_bucket_id) == 8,
15701 "offset of GetFragDataIndexEXT name_bucket_id should be 8"); 15701 "offset of GetFragDataIndexEXT name_bucket_id should be 8");
15702 static_assert(offsetof(GetFragDataIndexEXT, index_shm_id) == 12, 15702 static_assert(offsetof(GetFragDataIndexEXT, index_shm_id) == 12,
15703 "offset of GetFragDataIndexEXT index_shm_id should be 12"); 15703 "offset of GetFragDataIndexEXT index_shm_id should be 12");
15704 static_assert(offsetof(GetFragDataIndexEXT, index_shm_offset) == 16, 15704 static_assert(offsetof(GetFragDataIndexEXT, index_shm_offset) == 16,
15705 "offset of GetFragDataIndexEXT index_shm_offset should be 16"); 15705 "offset of GetFragDataIndexEXT index_shm_offset should be 16");
15706 15706
15707 struct UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate {
15708 typedef UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate ValueType;
15709 static const CommandId kCmdId =
15710 kUniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate;
15711 static const cmd::ArgFlags kArgFlags = cmd::kAtLeastN;
15712 static const uint8_t cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
15713
15714 static uint32_t ComputeDataSize() {
15715 return static_cast<uint32_t>(sizeof(GLfloat) * 16);
15716 }
15717
15718 static uint32_t ComputeSize() {
15719 return static_cast<uint32_t>(sizeof(ValueType) + ComputeDataSize());
15720 }
15721
15722 void SetHeader() { header.SetCmdByTotalSize<ValueType>(ComputeSize()); }
15723
15724 void Init(GLint _location,
15725 GLboolean _transpose,
15726 const GLfloat* _default_value) {
15727 SetHeader();
15728 location = _location;
15729 transpose = _transpose;
15730 memcpy(ImmediateDataAddress(this), _default_value, ComputeDataSize());
15731 }
15732
15733 void* Set(void* cmd,
15734 GLint _location,
15735 GLboolean _transpose,
15736 const GLfloat* _default_value) {
15737 static_cast<ValueType*>(cmd)->Init(_location, _transpose, _default_value);
15738 const uint32_t size = ComputeSize();
15739 return NextImmediateCmdAddressTotalSize<ValueType>(cmd, size);
15740 }
15741
15742 gpu::CommandHeader header;
15743 int32_t location;
15744 uint32_t transpose;
15745 };
15746
15747 static_assert(sizeof(UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate) ==
15748 12,
15749 "size of UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate "
15750 "should be 12");
15751 static_assert(offsetof(UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate,
15752 header) == 0,
15753 "offset of UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate "
15754 "header should be 0");
15755 static_assert(offsetof(UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate,
15756 location) == 4,
15757 "offset of UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate "
15758 "location should be 4");
15759 static_assert(offsetof(UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate,
15760 transpose) == 8,
15761 "offset of UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate "
15762 "transpose should be 8");
15763
15707 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_ 15764 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_AUTOGEN_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/cmd_buffer_functions.txt ('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