Chromium Code Reviews| 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 775 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 786 Cmds expected; | 786 Cmds expected; |
| 787 ExpectedMemoryInfo result1 = GetExpectedResultMemory(4); | 787 ExpectedMemoryInfo result1 = GetExpectedResultMemory(4); |
| 788 expected.cmd.Init(123, result1.id, result1.offset); | 788 expected.cmd.Init(123, result1.id, result1.offset); |
| 789 EXPECT_CALL(*command_buffer(), OnFlush()) | 789 EXPECT_CALL(*command_buffer(), OnFlush()) |
| 790 .WillOnce(SetMemory(result1.ptr, SizedResultHelper<Result::Type>(1))) | 790 .WillOnce(SetMemory(result1.ptr, SizedResultHelper<Result::Type>(1))) |
| 791 .RetiresOnSaturation(); | 791 .RetiresOnSaturation(); |
| 792 gl_->GetFloatv(123, &result); | 792 gl_->GetFloatv(123, &result); |
| 793 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); | 793 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); |
| 794 EXPECT_EQ(static_cast<Result::Type>(1), result); | 794 EXPECT_EQ(static_cast<Result::Type>(1), result); |
| 795 } | 795 } |
| 796 // TODO: Implement unit test for GetFragDataLocation | |
|
Ken Russell (switch to Gerrit)
2015/01/26 23:39:12
Add OWNER for TODO -- and ideally file a bug.
Zhenyao Mo
2015/01/26 23:47:30
OK, will add TODO(zmo).
| |
| 796 | 797 |
| 797 TEST_F(GLES2ImplementationTest, GetFramebufferAttachmentParameteriv) { | 798 TEST_F(GLES2ImplementationTest, GetFramebufferAttachmentParameteriv) { |
| 798 struct Cmds { | 799 struct Cmds { |
| 799 cmds::GetFramebufferAttachmentParameteriv cmd; | 800 cmds::GetFramebufferAttachmentParameteriv cmd; |
| 800 }; | 801 }; |
| 801 typedef cmds::GetFramebufferAttachmentParameteriv::Result Result; | 802 typedef cmds::GetFramebufferAttachmentParameteriv::Result Result; |
| 802 Result::Type result = 0; | 803 Result::Type result = 0; |
| 803 Cmds expected; | 804 Cmds expected; |
| 804 ExpectedMemoryInfo result1 = GetExpectedResultMemory(4); | 805 ExpectedMemoryInfo result1 = GetExpectedResultMemory(4); |
| 805 expected.cmd.Init(123, GL_COLOR_ATTACHMENT0, | 806 expected.cmd.Init(123, GL_COLOR_ATTACHMENT0, |
| (...skipping 2092 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2898 struct Cmds { | 2899 struct Cmds { |
| 2899 cmds::MatrixLoadIdentityCHROMIUM cmd; | 2900 cmds::MatrixLoadIdentityCHROMIUM cmd; |
| 2900 }; | 2901 }; |
| 2901 Cmds expected; | 2902 Cmds expected; |
| 2902 expected.cmd.Init(GL_PATH_PROJECTION_CHROMIUM); | 2903 expected.cmd.Init(GL_PATH_PROJECTION_CHROMIUM); |
| 2903 | 2904 |
| 2904 gl_->MatrixLoadIdentityCHROMIUM(GL_PATH_PROJECTION_CHROMIUM); | 2905 gl_->MatrixLoadIdentityCHROMIUM(GL_PATH_PROJECTION_CHROMIUM); |
| 2905 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); | 2906 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); |
| 2906 } | 2907 } |
| 2907 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_UNITTEST_AUTOGEN_H_ | 2908 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_UNITTEST_AUTOGEN_H_ |
| OLD | NEW |