OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include <GLES2/gl2.h> |
| 6 |
5 #include "gpu/command_buffer/service/shader_translator.h" | 7 #include "gpu/command_buffer/service/shader_translator.h" |
6 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
7 | 9 |
| 10 // The ANGLE shader translator now uses native GLenums |
| 11 // TODO(jmadill): delete these defines when the ANGLE |
| 12 // roll reliably passes translator version 126 |
| 13 #if (ANGLE_SH_VERSION >= 126) |
| 14 #define SH_VERTEX_SHADER GL_VERTEX_SHADER |
| 15 #define SH_FRAGMENT_SHADER GL_FRAGMENT_SHADER |
| 16 #define SH_FLOAT_VEC4 GL_FLOAT_VEC4 |
| 17 #endif |
| 18 |
8 namespace gpu { | 19 namespace gpu { |
9 namespace gles2 { | 20 namespace gles2 { |
10 | 21 |
11 class ShaderTranslatorTest : public testing::Test { | 22 class ShaderTranslatorTest : public testing::Test { |
12 public: | 23 public: |
13 ShaderTranslatorTest() { | 24 ShaderTranslatorTest() { |
14 } | 25 } |
15 | 26 |
16 virtual ~ShaderTranslatorTest() { | 27 virtual ~ShaderTranslatorTest() { |
17 } | 28 } |
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
255 | 266 |
256 EXPECT_EQ(options_1, options_2); | 267 EXPECT_EQ(options_1, options_2); |
257 EXPECT_NE(options_1, options_3); | 268 EXPECT_NE(options_1, options_3); |
258 EXPECT_NE(options_1, options_4); | 269 EXPECT_NE(options_1, options_4); |
259 EXPECT_NE(options_3, options_4); | 270 EXPECT_NE(options_3, options_4); |
260 } | 271 } |
261 | 272 |
262 } // namespace gles2 | 273 } // namespace gles2 |
263 } // namespace gpu | 274 } // namespace gpu |
264 | 275 |
OLD | NEW |