| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "cc/output/gl_renderer.h" | 5 #include "cc/output/gl_renderer.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 817 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 828 // created in AppendOneOfEveryQuadType(). | 828 // created in AppendOneOfEveryQuadType(). |
| 829 Mock::VerifyAndClearExpectations(context); | 829 Mock::VerifyAndClearExpectations(context); |
| 830 { | 830 { |
| 831 InSequence sequence; | 831 InSequence sequence; |
| 832 | 832 |
| 833 // The sync points for all quads are waited on first. This sync point is | 833 // The sync points for all quads are waited on first. This sync point is |
| 834 // for a texture quad drawn later in the frame. | 834 // for a texture quad drawn later in the frame. |
| 835 EXPECT_CALL(*context, waitSyncToken(MatchesSyncToken(mailbox_sync_token))) | 835 EXPECT_CALL(*context, waitSyncToken(MatchesSyncToken(mailbox_sync_token))) |
| 836 .Times(1); | 836 .Times(1); |
| 837 | 837 |
| 838 // yuv_quad is drawn with the default linear filter. | 838 // yuv_quad is drawn with GL_NEAREST for 4 planes. |
| 839 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, |
| 840 GL_NEAREST)); |
| 841 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, |
| 842 GL_NEAREST)); |
| 843 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, |
| 844 GL_NEAREST)); |
| 845 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, |
| 846 GL_NEAREST)); |
| 847 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, |
| 848 GL_NEAREST)); |
| 849 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, |
| 850 GL_NEAREST)); |
| 851 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, |
| 852 GL_NEAREST)); |
| 853 EXPECT_CALL(*context, texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, |
| 854 GL_NEAREST)); |
| 839 EXPECT_CALL(*context, drawElements(_, _, _, _)); | 855 EXPECT_CALL(*context, drawElements(_, _, _, _)); |
| 840 | 856 |
| 841 // tile_quad is drawn with GL_NEAREST because it is not transformed or | 857 // tile_quad is drawn with GL_NEAREST because it is not transformed or |
| 842 // scaled. | 858 // scaled. |
| 843 EXPECT_CALL( | 859 EXPECT_CALL( |
| 844 *context, | 860 *context, |
| 845 texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST)); | 861 texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST)); |
| 846 EXPECT_CALL( | 862 EXPECT_CALL( |
| 847 *context, | 863 *context, |
| 848 texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST)); | 864 texParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST)); |
| (...skipping 1115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1964 renderer_->SetVisible(true); | 1980 renderer_->SetVisible(true); |
| 1965 Mock::VerifyAndClearExpectations(context_support_ptr_); | 1981 Mock::VerifyAndClearExpectations(context_support_ptr_); |
| 1966 | 1982 |
| 1967 EXPECT_CALL(*context_support_ptr_, SetAggressivelyFreeResources(true)); | 1983 EXPECT_CALL(*context_support_ptr_, SetAggressivelyFreeResources(true)); |
| 1968 renderer_->SetVisible(false); | 1984 renderer_->SetVisible(false); |
| 1969 Mock::VerifyAndClearExpectations(context_support_ptr_); | 1985 Mock::VerifyAndClearExpectations(context_support_ptr_); |
| 1970 } | 1986 } |
| 1971 | 1987 |
| 1972 } // namespace | 1988 } // namespace |
| 1973 } // namespace cc | 1989 } // namespace cc |
| OLD | NEW |