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

Side by Side Diff: cc/trees/layer_sorter.h

Issue 139233002: [#4] Pass gfx structs by const ref (gfx::PointF) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Corrected as per review comments! Created 6 years, 11 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/resources/layer_quad.cc ('k') | cc/trees/layer_sorter.cc » ('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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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 #ifndef CC_TREES_LAYER_SORTER_H_ 5 #ifndef CC_TREES_LAYER_SORTER_H_
6 #define CC_TREES_LAYER_SORTER_H_ 6 #define CC_TREES_LAYER_SORTER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 24 matching lines...) Expand all
35 35
36 namespace cc { 36 namespace cc {
37 struct GraphEdge; 37 struct GraphEdge;
38 38
39 // Holds various useful properties derived from a layer's 3D outline. 39 // Holds various useful properties derived from a layer's 3D outline.
40 struct CC_EXPORT LayerShape { 40 struct CC_EXPORT LayerShape {
41 LayerShape(); 41 LayerShape();
42 LayerShape(float width, float height, const gfx::Transform& draw_transform); 42 LayerShape(float width, float height, const gfx::Transform& draw_transform);
43 ~LayerShape(); 43 ~LayerShape();
44 44
45 float LayerZFromProjectedPoint(gfx::PointF p) const; 45 float LayerZFromProjectedPoint(const gfx::PointF& p) const;
46 46
47 gfx::Vector3dF layer_normal; 47 gfx::Vector3dF layer_normal;
48 gfx::Point3F transform_origin; 48 gfx::Point3F transform_origin;
49 gfx::QuadF projected_quad; 49 gfx::QuadF projected_quad;
50 gfx::RectF projected_bounds; 50 gfx::RectF projected_bounds;
51 }; 51 };
52 52
53 struct GraphNode { 53 struct GraphNode {
54 explicit GraphNode(LayerImpl* layer_impl); 54 explicit GraphNode(LayerImpl* layer_impl);
55 ~GraphNode(); 55 ~GraphNode();
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 void CreateGraphNodes(LayerImplList::iterator first, 105 void CreateGraphNodes(LayerImplList::iterator first,
106 LayerImplList::iterator last); 106 LayerImplList::iterator last);
107 void CreateGraphEdges(); 107 void CreateGraphEdges();
108 void RemoveEdgeFromList(GraphEdge* graph, std::vector<GraphEdge*>* list); 108 void RemoveEdgeFromList(GraphEdge* graph, std::vector<GraphEdge*>* list);
109 109
110 DISALLOW_COPY_AND_ASSIGN(LayerSorter); 110 DISALLOW_COPY_AND_ASSIGN(LayerSorter);
111 }; 111 };
112 112
113 } // namespace cc 113 } // namespace cc
114 #endif // CC_TREES_LAYER_SORTER_H_ 114 #endif // CC_TREES_LAYER_SORTER_H_
OLDNEW
« no previous file with comments | « cc/resources/layer_quad.cc ('k') | cc/trees/layer_sorter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698