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

Unified Diff: cc/layers/quad_sink.cc

Issue 309493002: Remove QuadCuller class and make QuadSink concrete (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@test2ownMock
Patch Set: gn build fix Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layers/quad_sink.h ('k') | cc/test/mock_quad_culler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/quad_sink.cc
diff --git a/cc/trees/quad_culler.cc b/cc/layers/quad_sink.cc
similarity index 61%
rename from cc/trees/quad_culler.cc
rename to cc/layers/quad_sink.cc
index db59fa5da5805bffe837996337b30f017f60dd88..23758afc66938b606750238bb771f8bb5aed76d2 100644
--- a/cc/trees/quad_culler.cc
+++ b/cc/layers/quad_sink.cc
@@ -1,8 +1,8 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
+// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "cc/trees/quad_culler.h"
+#include "cc/layers/quad_sink.h"
#include "cc/debug/debug_colors.h"
#include "cc/layers/append_quads_data.h"
@@ -16,34 +16,33 @@
namespace cc {
-QuadCuller::QuadCuller(RenderPass* render_pass,
- const LayerImpl* layer,
- const OcclusionTracker<LayerImpl>& occlusion_tracker)
+QuadSink::QuadSink(RenderPass* render_pass,
+ const OcclusionTracker<LayerImpl>* occlusion_tracker)
: render_pass_(render_pass),
- layer_(layer),
- occlusion_tracker_(occlusion_tracker),
- current_shared_quad_state_(NULL) {
+ current_shared_quad_state_(NULL),
+ occlusion_tracker_(occlusion_tracker) {
}
-SharedQuadState* QuadCuller::CreateSharedQuadState() {
+SharedQuadState* QuadSink::CreateSharedQuadState() {
current_shared_quad_state_ = render_pass_->CreateAndAppendSharedQuadState();
return current_shared_quad_state_;
}
-gfx::Rect QuadCuller::UnoccludedContentRect(
+gfx::Rect QuadSink::UnoccludedContentRect(
const gfx::Rect& content_rect,
const gfx::Transform& draw_transform) {
- return occlusion_tracker_.UnoccludedContentRect(content_rect, draw_transform);
+ return occlusion_tracker_->UnoccludedContentRect(content_rect,
+ draw_transform);
}
-gfx::Rect QuadCuller::UnoccludedContributingSurfaceContentRect(
+gfx::Rect QuadSink::UnoccludedContributingSurfaceContentRect(
const gfx::Rect& content_rect,
const gfx::Transform& draw_transform) {
- return occlusion_tracker_.UnoccludedContributingSurfaceContentRect(
+ return occlusion_tracker_->UnoccludedContributingSurfaceContentRect(
content_rect, draw_transform);
}
-void QuadCuller::Append(scoped_ptr<DrawQuad> draw_quad) {
+void QuadSink::Append(scoped_ptr<DrawQuad> draw_quad) {
DCHECK(draw_quad->shared_quad_state == current_shared_quad_state_);
DCHECK(!render_pass_->shared_quad_state_list.empty());
DCHECK(render_pass_->shared_quad_state_list.back() ==
« no previous file with comments | « cc/layers/quad_sink.h ('k') | cc/test/mock_quad_culler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698