| 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 1423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1434 EXPECT_EQ(static_cast<GLenum>(11), cmd.pname); | 1434 EXPECT_EQ(static_cast<GLenum>(11), cmd.pname); |
| 1435 EXPECT_EQ(static_cast<uint32_t>(12), cmd.params_shm_id); | 1435 EXPECT_EQ(static_cast<uint32_t>(12), cmd.params_shm_id); |
| 1436 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_offset); | 1436 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_offset); |
| 1437 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); | 1437 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 1438 } | 1438 } |
| 1439 | 1439 |
| 1440 TEST_F(GLES2FormatTest, GetInternalformativ) { | 1440 TEST_F(GLES2FormatTest, GetInternalformativ) { |
| 1441 cmds::GetInternalformativ& cmd = *GetBufferAs<cmds::GetInternalformativ>(); | 1441 cmds::GetInternalformativ& cmd = *GetBufferAs<cmds::GetInternalformativ>(); |
| 1442 void* next_cmd = | 1442 void* next_cmd = |
| 1443 cmd.Set(&cmd, static_cast<GLenum>(11), static_cast<GLenum>(12), | 1443 cmd.Set(&cmd, static_cast<GLenum>(11), static_cast<GLenum>(12), |
| 1444 static_cast<GLenum>(13), static_cast<GLsizei>(14), | 1444 static_cast<GLenum>(13), static_cast<uint32_t>(14), |
| 1445 static_cast<uint32_t>(15), static_cast<uint32_t>(16)); | 1445 static_cast<uint32_t>(15)); |
| 1446 EXPECT_EQ(static_cast<uint32_t>(cmds::GetInternalformativ::kCmdId), | 1446 EXPECT_EQ(static_cast<uint32_t>(cmds::GetInternalformativ::kCmdId), |
| 1447 cmd.header.command); | 1447 cmd.header.command); |
| 1448 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); | 1448 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 1449 EXPECT_EQ(static_cast<GLenum>(11), cmd.target); | 1449 EXPECT_EQ(static_cast<GLenum>(11), cmd.target); |
| 1450 EXPECT_EQ(static_cast<GLenum>(12), cmd.format); | 1450 EXPECT_EQ(static_cast<GLenum>(12), cmd.format); |
| 1451 EXPECT_EQ(static_cast<GLenum>(13), cmd.pname); | 1451 EXPECT_EQ(static_cast<GLenum>(13), cmd.pname); |
| 1452 EXPECT_EQ(static_cast<GLsizei>(14), cmd.bufSize); | 1452 EXPECT_EQ(static_cast<uint32_t>(14), cmd.params_shm_id); |
| 1453 EXPECT_EQ(static_cast<uint32_t>(15), cmd.params_shm_id); | 1453 EXPECT_EQ(static_cast<uint32_t>(15), cmd.params_shm_offset); |
| 1454 EXPECT_EQ(static_cast<uint32_t>(16), cmd.params_shm_offset); | |
| 1455 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); | 1454 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 1456 } | 1455 } |
| 1457 | 1456 |
| 1458 TEST_F(GLES2FormatTest, GetProgramiv) { | 1457 TEST_F(GLES2FormatTest, GetProgramiv) { |
| 1459 cmds::GetProgramiv& cmd = *GetBufferAs<cmds::GetProgramiv>(); | 1458 cmds::GetProgramiv& cmd = *GetBufferAs<cmds::GetProgramiv>(); |
| 1460 void* next_cmd = | 1459 void* next_cmd = |
| 1461 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), | 1460 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), |
| 1462 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); | 1461 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); |
| 1463 EXPECT_EQ(static_cast<uint32_t>(cmds::GetProgramiv::kCmdId), | 1462 EXPECT_EQ(static_cast<uint32_t>(cmds::GetProgramiv::kCmdId), |
| 1464 cmd.header.command); | 1463 cmd.header.command); |
| (...skipping 3403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4868 TEST_F(GLES2FormatTest, BlendBarrierKHR) { | 4867 TEST_F(GLES2FormatTest, BlendBarrierKHR) { |
| 4869 cmds::BlendBarrierKHR& cmd = *GetBufferAs<cmds::BlendBarrierKHR>(); | 4868 cmds::BlendBarrierKHR& cmd = *GetBufferAs<cmds::BlendBarrierKHR>(); |
| 4870 void* next_cmd = cmd.Set(&cmd); | 4869 void* next_cmd = cmd.Set(&cmd); |
| 4871 EXPECT_EQ(static_cast<uint32_t>(cmds::BlendBarrierKHR::kCmdId), | 4870 EXPECT_EQ(static_cast<uint32_t>(cmds::BlendBarrierKHR::kCmdId), |
| 4872 cmd.header.command); | 4871 cmd.header.command); |
| 4873 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); | 4872 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 4874 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); | 4873 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 4875 } | 4874 } |
| 4876 | 4875 |
| 4877 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_TEST_AUTOGEN_H_ | 4876 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_TEST_AUTOGEN_H_ |
| OLD | NEW |