| 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 1760 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1771 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribiv::kCmdId), | 1771 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribiv::kCmdId), |
| 1772 cmd.header.command); | 1772 cmd.header.command); |
| 1773 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); | 1773 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 1774 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); | 1774 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); |
| 1775 EXPECT_EQ(static_cast<GLenum>(12), cmd.pname); | 1775 EXPECT_EQ(static_cast<GLenum>(12), cmd.pname); |
| 1776 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_id); | 1776 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_id); |
| 1777 EXPECT_EQ(static_cast<uint32_t>(14), cmd.params_shm_offset); | 1777 EXPECT_EQ(static_cast<uint32_t>(14), cmd.params_shm_offset); |
| 1778 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); | 1778 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 1779 } | 1779 } |
| 1780 | 1780 |
| 1781 TEST_F(GLES2FormatTest, GetVertexAttribIiv) { |
| 1782 cmds::GetVertexAttribIiv& cmd = *GetBufferAs<cmds::GetVertexAttribIiv>(); |
| 1783 void* next_cmd = |
| 1784 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), |
| 1785 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); |
| 1786 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribIiv::kCmdId), |
| 1787 cmd.header.command); |
| 1788 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 1789 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); |
| 1790 EXPECT_EQ(static_cast<GLenum>(12), cmd.pname); |
| 1791 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_id); |
| 1792 EXPECT_EQ(static_cast<uint32_t>(14), cmd.params_shm_offset); |
| 1793 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 1794 } |
| 1795 |
| 1796 TEST_F(GLES2FormatTest, GetVertexAttribIuiv) { |
| 1797 cmds::GetVertexAttribIuiv& cmd = *GetBufferAs<cmds::GetVertexAttribIuiv>(); |
| 1798 void* next_cmd = |
| 1799 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), |
| 1800 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); |
| 1801 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribIuiv::kCmdId), |
| 1802 cmd.header.command); |
| 1803 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 1804 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); |
| 1805 EXPECT_EQ(static_cast<GLenum>(12), cmd.pname); |
| 1806 EXPECT_EQ(static_cast<uint32_t>(13), cmd.params_shm_id); |
| 1807 EXPECT_EQ(static_cast<uint32_t>(14), cmd.params_shm_offset); |
| 1808 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 1809 } |
| 1810 |
| 1781 TEST_F(GLES2FormatTest, GetVertexAttribPointerv) { | 1811 TEST_F(GLES2FormatTest, GetVertexAttribPointerv) { |
| 1782 cmds::GetVertexAttribPointerv& cmd = | 1812 cmds::GetVertexAttribPointerv& cmd = |
| 1783 *GetBufferAs<cmds::GetVertexAttribPointerv>(); | 1813 *GetBufferAs<cmds::GetVertexAttribPointerv>(); |
| 1784 void* next_cmd = | 1814 void* next_cmd = |
| 1785 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), | 1815 cmd.Set(&cmd, static_cast<GLuint>(11), static_cast<GLenum>(12), |
| 1786 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); | 1816 static_cast<uint32_t>(13), static_cast<uint32_t>(14)); |
| 1787 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribPointerv::kCmdId), | 1817 EXPECT_EQ(static_cast<uint32_t>(cmds::GetVertexAttribPointerv::kCmdId), |
| 1788 cmd.header.command); | 1818 cmd.header.command); |
| 1789 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); | 1819 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 1790 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); | 1820 EXPECT_EQ(static_cast<GLuint>(11), cmd.index); |
| (...skipping 3041 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4832 TEST_F(GLES2FormatTest, BlendBarrierKHR) { | 4862 TEST_F(GLES2FormatTest, BlendBarrierKHR) { |
| 4833 cmds::BlendBarrierKHR& cmd = *GetBufferAs<cmds::BlendBarrierKHR>(); | 4863 cmds::BlendBarrierKHR& cmd = *GetBufferAs<cmds::BlendBarrierKHR>(); |
| 4834 void* next_cmd = cmd.Set(&cmd); | 4864 void* next_cmd = cmd.Set(&cmd); |
| 4835 EXPECT_EQ(static_cast<uint32_t>(cmds::BlendBarrierKHR::kCmdId), | 4865 EXPECT_EQ(static_cast<uint32_t>(cmds::BlendBarrierKHR::kCmdId), |
| 4836 cmd.header.command); | 4866 cmd.header.command); |
| 4837 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); | 4867 EXPECT_EQ(sizeof(cmd), cmd.header.size * 4u); |
| 4838 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); | 4868 CheckBytesWrittenMatchesExpectedSize(next_cmd, sizeof(cmd)); |
| 4839 } | 4869 } |
| 4840 | 4870 |
| 4841 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_TEST_AUTOGEN_H_ | 4871 #endif // GPU_COMMAND_BUFFER_COMMON_GLES2_CMD_FORMAT_TEST_AUTOGEN_H_ |
| OLD | NEW |