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 2015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2026 for (int ii = 0; ii < 2; ++ii) { | 2026 for (int ii = 0; ii < 2; ++ii) { |
2027 for (int jj = 0; jj < 4; ++jj) { | 2027 for (int jj = 0; jj < 4; ++jj) { |
2028 data[ii][jj] = static_cast<GLuint>(ii * 4 + jj); | 2028 data[ii][jj] = static_cast<GLuint>(ii * 4 + jj); |
2029 } | 2029 } |
2030 } | 2030 } |
2031 expected.cmd.Init(1, 2, &data[0][0]); | 2031 expected.cmd.Init(1, 2, &data[0][0]); |
2032 gl_->Uniform4uiv(1, 2, &data[0][0]); | 2032 gl_->Uniform4uiv(1, 2, &data[0][0]); |
2033 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); | 2033 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); |
2034 } | 2034 } |
2035 | 2035 |
| 2036 TEST_F(GLES2ImplementationTest, UniformBlockBinding) { |
| 2037 struct Cmds { |
| 2038 cmds::UniformBlockBinding cmd; |
| 2039 }; |
| 2040 Cmds expected; |
| 2041 expected.cmd.Init(1, 2, 3); |
| 2042 |
| 2043 gl_->UniformBlockBinding(1, 2, 3); |
| 2044 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); |
| 2045 } |
| 2046 |
2036 TEST_F(GLES2ImplementationTest, UniformMatrix2fv) { | 2047 TEST_F(GLES2ImplementationTest, UniformMatrix2fv) { |
2037 GLfloat data[2][4] = {{0}}; | 2048 GLfloat data[2][4] = {{0}}; |
2038 struct Cmds { | 2049 struct Cmds { |
2039 cmds::UniformMatrix2fvImmediate cmd; | 2050 cmds::UniformMatrix2fvImmediate cmd; |
2040 GLfloat data[2][4]; | 2051 GLfloat data[2][4]; |
2041 }; | 2052 }; |
2042 | 2053 |
2043 Cmds expected; | 2054 Cmds expected; |
2044 for (int ii = 0; ii < 2; ++ii) { | 2055 for (int ii = 0; ii < 2; ++ii) { |
2045 for (int jj = 0; jj < 4; ++jj) { | 2056 for (int jj = 0; jj < 4; ++jj) { |
(...skipping 915 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2961 struct Cmds { | 2972 struct Cmds { |
2962 cmds::MatrixLoadIdentityCHROMIUM cmd; | 2973 cmds::MatrixLoadIdentityCHROMIUM cmd; |
2963 }; | 2974 }; |
2964 Cmds expected; | 2975 Cmds expected; |
2965 expected.cmd.Init(GL_PATH_PROJECTION_CHROMIUM); | 2976 expected.cmd.Init(GL_PATH_PROJECTION_CHROMIUM); |
2966 | 2977 |
2967 gl_->MatrixLoadIdentityCHROMIUM(GL_PATH_PROJECTION_CHROMIUM); | 2978 gl_->MatrixLoadIdentityCHROMIUM(GL_PATH_PROJECTION_CHROMIUM); |
2968 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); | 2979 EXPECT_EQ(0, memcmp(&expected, commands_, sizeof(expected))); |
2969 } | 2980 } |
2970 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_UNITTEST_AUTOGEN_H_ | 2981 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_UNITTEST_AUTOGEN_H_ |
OLD | NEW |