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

Unified Diff: gpu/command_buffer/common/gles2_cmd_format_autogen.h

Issue 1119723003: Add glCopyCompressedTextureCHROMIUM (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix comments in tests Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: gpu/command_buffer/common/gles2_cmd_format_autogen.h
diff --git a/gpu/command_buffer/common/gles2_cmd_format_autogen.h b/gpu/command_buffer/common/gles2_cmd_format_autogen.h
index f6f4a18452466390fb8e3c94c102244c3bbf09fa..95f9f36eb1ba60b8e5d34dc8504c102697b530a6 100644
--- a/gpu/command_buffer/common/gles2_cmd_format_autogen.h
+++ b/gpu/command_buffer/common/gles2_cmd_format_autogen.h
@@ -11907,6 +11907,74 @@ static_assert(offsetof(CopySubTextureCHROMIUM, xoffset) == 16,
static_assert(offsetof(CopySubTextureCHROMIUM, yoffset) == 20,
"offset of CopySubTextureCHROMIUM yoffset should be 20");
+struct CopyCompressedTextureCHROMIUM {
+ typedef CopyCompressedTextureCHROMIUM ValueType;
+ static const CommandId kCmdId = kCopyCompressedTextureCHROMIUM;
+ static const cmd::ArgFlags kArgFlags = cmd::kFixed;
+ static const uint8 cmd_flags = CMD_FLAG_SET_TRACE_LEVEL(3);
+
+ static uint32_t ComputeSize() {
+ return static_cast<uint32_t>(sizeof(ValueType)); // NOLINT
+ }
+
+ void SetHeader() { header.SetCmd<ValueType>(); }
+
+ void Init(GLenum _target,
+ GLenum _source_id,
+ GLenum _dest_id,
+ GLenum _internalformat,
+ GLenum _dest_type,
+ GLsizei _source_size) {
+ SetHeader();
+ target = _target;
+ source_id = _source_id;
+ dest_id = _dest_id;
+ internalformat = _internalformat;
+ dest_type = _dest_type;
+ source_size = _source_size;
+ }
+
+ void* Set(void* cmd,
+ GLenum _target,
+ GLenum _source_id,
+ GLenum _dest_id,
+ GLenum _internalformat,
+ GLenum _dest_type,
+ GLsizei _source_size) {
+ static_cast<ValueType*>(cmd)->Init(_target, _source_id, _dest_id,
+ _internalformat, _dest_type,
+ _source_size);
+ return NextCmdAddress<ValueType>(cmd);
+ }
+
+ gpu::CommandHeader header;
+ uint32_t target;
+ uint32_t source_id;
+ uint32_t dest_id;
+ uint32_t internalformat;
+ uint32_t dest_type;
+ int32_t source_size;
+};
+
+static_assert(sizeof(CopyCompressedTextureCHROMIUM) == 28,
+ "size of CopyCompressedTextureCHROMIUM should be 28");
+static_assert(offsetof(CopyCompressedTextureCHROMIUM, header) == 0,
+ "offset of CopyCompressedTextureCHROMIUM header should be 0");
+static_assert(offsetof(CopyCompressedTextureCHROMIUM, target) == 4,
+ "offset of CopyCompressedTextureCHROMIUM target should be 4");
+static_assert(offsetof(CopyCompressedTextureCHROMIUM, source_id) == 8,
+ "offset of CopyCompressedTextureCHROMIUM source_id should be 8");
+static_assert(offsetof(CopyCompressedTextureCHROMIUM, dest_id) == 12,
+ "offset of CopyCompressedTextureCHROMIUM dest_id should be 12");
+static_assert(
+ offsetof(CopyCompressedTextureCHROMIUM, internalformat) == 16,
+ "offset of CopyCompressedTextureCHROMIUM internalformat should be 16");
+static_assert(offsetof(CopyCompressedTextureCHROMIUM, dest_type) == 20,
+ "offset of CopyCompressedTextureCHROMIUM dest_type should be 20");
+static_assert(
+ offsetof(CopyCompressedTextureCHROMIUM, source_size) == 24,
+ "offset of CopyCompressedTextureCHROMIUM source_size should be 24");
+
struct DrawArraysInstancedANGLE {
typedef DrawArraysInstancedANGLE ValueType;
static const CommandId kCmdId = kDrawArraysInstancedANGLE;

Powered by Google App Engine
This is Rietveld 408576698