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

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

Issue 1533773002: Delete CC. (Closed) Base URL: git@github.com:domokit/mojo.git@cl-2e
Patch Set: rebase Created 5 years 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/bsp_walk_action.h ('k') | cc/output/compositor_frame.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "cc/output/bsp_walk_action.h"
6
7 #include <vector>
8
9 #include "base/memory/scoped_ptr.h"
10 #include "cc/output/direct_renderer.h"
11 #include "cc/quads/draw_polygon.h"
12 #include "cc/quads/draw_quad.h"
13
14 namespace cc {
15
16 BspWalkActionDrawPolygon::BspWalkActionDrawPolygon(
17 DirectRenderer* renderer,
18 DirectRenderer::DrawingFrame* frame,
19 const gfx::Rect& render_pass_scissor,
20 bool using_scissor_as_optimization)
21 : renderer_(renderer),
22 frame_(frame),
23 render_pass_scissor_(render_pass_scissor),
24 using_scissor_as_optimization_(using_scissor_as_optimization) {
25 }
26
27 void BspWalkActionDrawPolygon::operator()(DrawPolygon* item) {
28 gfx::Transform inverse_transform;
29 bool invertible =
30 item->original_ref()->quadTransform().GetInverse(&inverse_transform);
31 DCHECK(invertible);
32 item->TransformToLayerSpace(inverse_transform);
33 renderer_->DoDrawPolygon(*item, frame_, render_pass_scissor_,
34 using_scissor_as_optimization_);
35 }
36
37 BspWalkActionToVector::BspWalkActionToVector(std::vector<DrawPolygon*>* in_list)
38 : list_(in_list) {
39 }
40
41 void BspWalkActionToVector::operator()(DrawPolygon* item) {
42 list_->push_back(item);
43 }
44
45 } // namespace cc
OLDNEW
« no previous file with comments | « cc/output/bsp_walk_action.h ('k') | cc/output/compositor_frame.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698