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

Side by Side Diff: cc/math_util.h

Issue 12096112: [cc] Trace detailed tile info when --trace-all-rendered-frames (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Dont expose to extension yet Created 7 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « cc/layer_tree_host_impl.cc ('k') | cc/math_util.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 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 #ifndef CC_MATH_UTIL_H_ 5 #ifndef CC_MATH_UTIL_H_
6 #define CC_MATH_UTIL_H_ 6 #define CC_MATH_UTIL_H_
7 7
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/memory/scoped_ptr.h"
9 #include "cc/cc_export.h" 10 #include "cc/cc_export.h"
10 #include "ui/gfx/point_f.h" 11 #include "ui/gfx/point_f.h"
11 #include "ui/gfx/point3_f.h" 12 #include "ui/gfx/point3_f.h"
13 #include "ui/gfx/size.h"
12 #include "ui/gfx/transform.h" 14 #include "ui/gfx/transform.h"
13 15
16 namespace base {
17 class Value;
18 }
19
14 namespace gfx { 20 namespace gfx {
15 class QuadF; 21 class QuadF;
16 class Rect; 22 class Rect;
17 class RectF; 23 class RectF;
18 class Transform; 24 class Transform;
19 class Vector2dF; 25 class Vector2dF;
20 } 26 }
21 27
22 namespace cc { 28 namespace cc {
23 29
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 static gfx::PointF projectPoint(const gfx::Transform&, const gfx::PointF&, b ool& clipped); 111 static gfx::PointF projectPoint(const gfx::Transform&, const gfx::PointF&, b ool& clipped);
106 112
107 static gfx::Vector2dF computeTransform2dScaleComponents(const gfx::Transform &, float fallbackValue); 113 static gfx::Vector2dF computeTransform2dScaleComponents(const gfx::Transform &, float fallbackValue);
108 114
109 // Returns the smallest angle between the given two vectors in degrees. Neit her vector is 115 // Returns the smallest angle between the given two vectors in degrees. Neit her vector is
110 // assumed to be normalized. 116 // assumed to be normalized.
111 static float smallestAngleBetweenVectors(gfx::Vector2dF, gfx::Vector2dF); 117 static float smallestAngleBetweenVectors(gfx::Vector2dF, gfx::Vector2dF);
112 118
113 // Projects the |source| vector onto |destination|. Neither vector is assume d to be normalized. 119 // Projects the |source| vector onto |destination|. Neither vector is assume d to be normalized.
114 static gfx::Vector2dF projectVector(gfx::Vector2dF source, gfx::Vector2dF de stination); 120 static gfx::Vector2dF projectVector(gfx::Vector2dF source, gfx::Vector2dF de stination);
121
122 // Conversion to value.
123 static scoped_ptr<base::Value> asValue(gfx::Size s);
124 static scoped_ptr<base::Value> asValue(gfx::PointF q);
125 static scoped_ptr<base::Value> asValue(gfx::QuadF q);
115 }; 126 };
116 127
117 } // namespace cc 128 } // namespace cc
118 129
119 #endif // CC_MATH_UTIL_H_ 130 #endif // CC_MATH_UTIL_H_
OLDNEW
« no previous file with comments | « cc/layer_tree_host_impl.cc ('k') | cc/math_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698