| 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 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
| 6 | 6 |
| 7 #include <limits.h> | 7 #include <limits.h> |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 3666 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3677 EXPECT_CALL(*gl_, CheckFramebufferStatusEXT(GL_READ_FRAMEBUFFER)) | 3677 EXPECT_CALL(*gl_, CheckFramebufferStatusEXT(GL_READ_FRAMEBUFFER)) |
| 3678 .WillOnce(Return(GL_FRAMEBUFFER_COMPLETE)) | 3678 .WillOnce(Return(GL_FRAMEBUFFER_COMPLETE)) |
| 3679 .RetiresOnSaturation(); | 3679 .RetiresOnSaturation(); |
| 3680 SetupExpectationsForFramebufferClearing(GL_DRAW_FRAMEBUFFER, // target | 3680 SetupExpectationsForFramebufferClearing(GL_DRAW_FRAMEBUFFER, // target |
| 3681 GL_COLOR_BUFFER_BIT, // clear bits | 3681 GL_COLOR_BUFFER_BIT, // clear bits |
| 3682 0, 0, 0, 0, // color | 3682 0, 0, 0, 0, // color |
| 3683 0, // stencil | 3683 0, // stencil |
| 3684 1.0f, // depth | 3684 1.0f, // depth |
| 3685 false, // scissor test | 3685 false, // scissor test |
| 3686 0, 0, 128, 64); | 3686 0, 0, 128, 64); |
| 3687 SetupExpectationsForEnableDisable(GL_SCISSOR_TEST, false); | |
| 3688 EXPECT_CALL(*gl_, BlitFramebufferEXT(0, 0, 1, 1, 0, 0, 1, 1, | 3687 EXPECT_CALL(*gl_, BlitFramebufferEXT(0, 0, 1, 1, 0, 0, 1, 1, |
| 3689 GL_COLOR_BUFFER_BIT, GL_LINEAR)) | 3688 GL_COLOR_BUFFER_BIT, GL_LINEAR)) |
| 3690 .Times(1) | 3689 .Times(1) |
| 3691 .RetiresOnSaturation(); | 3690 .RetiresOnSaturation(); |
| 3692 SetupExpectationsForEnableDisable(GL_SCISSOR_TEST, false); | |
| 3693 BlitFramebufferCHROMIUM cmd; | 3691 BlitFramebufferCHROMIUM cmd; |
| 3694 cmd.Init(0, 0, 1, 1, 0, 0, 1, 1, GL_COLOR_BUFFER_BIT, GL_LINEAR); | 3692 cmd.Init(0, 0, 1, 1, 0, 0, 1, 1, GL_COLOR_BUFFER_BIT, GL_LINEAR); |
| 3695 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); | 3693 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); |
| 3696 EXPECT_EQ(GL_NO_ERROR, GetGLError()); | 3694 EXPECT_EQ(GL_NO_ERROR, GetGLError()); |
| 3697 } | 3695 } |
| 3698 } | 3696 } |
| 3699 | 3697 |
| 3700 TEST_P(GLES3DecoderTest, BlitFramebufferMissingDepthOrStencil) { | 3698 TEST_P(GLES3DecoderTest, BlitFramebufferMissingDepthOrStencil) { |
| 3701 // Run BlitFramebufferCHROMIUM with depth or stencil bits, from/to a read/draw | 3699 // Run BlitFramebufferCHROMIUM with depth or stencil bits, from/to a read/draw |
| 3702 // framebuffer that doesn't have depth/stencil. The bits should be silently | 3700 // framebuffer that doesn't have depth/stencil. The bits should be silently |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3801 EXPECT_EQ(GL_NO_ERROR, GetGLError()); | 3799 EXPECT_EQ(GL_NO_ERROR, GetGLError()); |
| 3802 } | 3800 } |
| 3803 } | 3801 } |
| 3804 | 3802 |
| 3805 // TODO(gman): PixelStorei | 3803 // TODO(gman): PixelStorei |
| 3806 | 3804 |
| 3807 // TODO(gman): SwapBuffers | 3805 // TODO(gman): SwapBuffers |
| 3808 | 3806 |
| 3809 } // namespace gles2 | 3807 } // namespace gles2 |
| 3810 } // namespace gpu | 3808 } // namespace gpu |
| OLD | NEW |