| 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 "gpu/command_buffer/service/test_helper.h" | 5 #include "gpu/command_buffer/service/test_helper.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
| (...skipping 772 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 783 .RetiresOnSaturation(); | 783 .RetiresOnSaturation(); |
| 784 EXPECT_CALL(*gl, CompileShader(shader->service_id())) | 784 EXPECT_CALL(*gl, CompileShader(shader->service_id())) |
| 785 .Times(1) | 785 .Times(1) |
| 786 .RetiresOnSaturation(); | 786 .RetiresOnSaturation(); |
| 787 EXPECT_CALL(*gl, GetShaderiv(shader->service_id(), | 787 EXPECT_CALL(*gl, GetShaderiv(shader->service_id(), |
| 788 GL_COMPILE_STATUS, | 788 GL_COMPILE_STATUS, |
| 789 NotNull())) // status | 789 NotNull())) // status |
| 790 .WillOnce(SetArgumentPointee<2>(GL_TRUE)) | 790 .WillOnce(SetArgumentPointee<2>(GL_TRUE)) |
| 791 .RetiresOnSaturation(); | 791 .RetiresOnSaturation(); |
| 792 } | 792 } |
| 793 shader->RequestCompile(); |
| 793 shader->DoCompile(&translator, Shader::kGL); | 794 shader->DoCompile(&translator, Shader::kGL); |
| 794 } | 795 } |
| 795 | 796 |
| 796 // static | 797 // static |
| 797 void TestHelper::SetShaderStates( | 798 void TestHelper::SetShaderStates( |
| 798 ::gfx::MockGLInterface* gl, Shader* shader, bool valid) { | 799 ::gfx::MockGLInterface* gl, Shader* shader, bool valid) { |
| 799 SetShaderStates(gl, shader, valid, NULL, NULL, NULL, NULL, NULL, NULL); | 800 SetShaderStates(gl, shader, valid, NULL, NULL, NULL, NULL, NULL, NULL); |
| 800 } | 801 } |
| 801 | 802 |
| 802 // static | 803 // static |
| (...skipping 26 matching lines...) Expand all Loading... |
| 829 gfx::SetGLImplementation(implementation); | 830 gfx::SetGLImplementation(implementation); |
| 830 } | 831 } |
| 831 | 832 |
| 832 ScopedGLImplementationSetter::~ScopedGLImplementationSetter() { | 833 ScopedGLImplementationSetter::~ScopedGLImplementationSetter() { |
| 833 gfx::SetGLImplementation(old_implementation_); | 834 gfx::SetGLImplementation(old_implementation_); |
| 834 } | 835 } |
| 835 | 836 |
| 836 } // namespace gles2 | 837 } // namespace gles2 |
| 837 } // namespace gpu | 838 } // namespace gpu |
| 838 | 839 |
| OLD | NEW |