Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Side by Side Diff: cc/output/gl_renderer_unittest.cc

Issue 1376883004: Overlays: Remove special casing of primary overlay plane (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/output/gl_renderer.cc ('k') | cc/output/output_surface.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <set> 7 #include <set>
8 8
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 2106 matching lines...) Expand 10 before | Expand all | Expand 10 after
2117 class SingleOverlayValidator : public OverlayCandidateValidator { 2117 class SingleOverlayValidator : public OverlayCandidateValidator {
2118 public: 2118 public:
2119 void GetStrategies(OverlayProcessor::StrategyList* strategies) override { 2119 void GetStrategies(OverlayProcessor::StrategyList* strategies) override {
2120 strategies->push_back(scoped_ptr<OverlayProcessor::Strategy>( 2120 strategies->push_back(scoped_ptr<OverlayProcessor::Strategy>(
2121 new OverlayStrategyCommon(this, new OverlayStrategySingleOnTop))); 2121 new OverlayStrategyCommon(this, new OverlayStrategySingleOnTop)));
2122 strategies->push_back(scoped_ptr<OverlayProcessor::Strategy>( 2122 strategies->push_back(scoped_ptr<OverlayProcessor::Strategy>(
2123 new OverlayStrategyCommon(this, new OverlayStrategyUnderlay))); 2123 new OverlayStrategyCommon(this, new OverlayStrategyUnderlay)));
2124 } 2124 }
2125 2125
2126 void CheckOverlaySupport(OverlayCandidateList* surfaces) override { 2126 void CheckOverlaySupport(OverlayCandidateList* surfaces) override {
2127 ASSERT_EQ(2U, surfaces->size()); 2127 ASSERT_EQ(1U, surfaces->size());
2128 OverlayCandidate& candidate = surfaces->back(); 2128 OverlayCandidate& candidate = surfaces->back();
2129 candidate.overlay_handled = true; 2129 candidate.overlay_handled = true;
2130 } 2130 }
2131 }; 2131 };
2132 2132
2133 explicit SingleOverlayOnTopProcessor(OutputSurface* surface) 2133 explicit SingleOverlayOnTopProcessor(OutputSurface* surface)
2134 : OverlayProcessor(surface) {} 2134 : OverlayProcessor(surface) {}
2135 2135
2136 void Initialize() override { 2136 void Initialize() override {
2137 strategies_.push_back(scoped_ptr<Strategy>(new OverlayStrategyCommon( 2137 strategies_.push_back(scoped_ptr<Strategy>(new OverlayStrategyCommon(
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
2226 EXPECT_CALL(overlay_scheduler, 2226 EXPECT_CALL(overlay_scheduler,
2227 Schedule(1, gfx::OVERLAY_TRANSFORM_NONE, _, viewport_rect, 2227 Schedule(1, gfx::OVERLAY_TRANSFORM_NONE, _, viewport_rect,
2228 BoundingRect(uv_top_left, uv_bottom_right))).Times(1); 2228 BoundingRect(uv_top_left, uv_bottom_right))).Times(1);
2229 2229
2230 renderer.DrawFrame(&render_passes_in_draw_order_, 1.f, viewport_rect, 2230 renderer.DrawFrame(&render_passes_in_draw_order_, 1.f, viewport_rect,
2231 viewport_rect, false); 2231 viewport_rect, false);
2232 } 2232 }
2233 2233
2234 } // namespace 2234 } // namespace
2235 } // namespace cc 2235 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/gl_renderer.cc ('k') | cc/output/output_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698