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

Side by Side Diff: cc/transform_operation.h

Issue 12035029: Finish migrating cc/ from WebKit::WebTransformationMatrix to gfx::Transform (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix nits Created 7 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/test/geometry_test_utils.cc ('k') | cc/transform_operation.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_TRANSFORM_OPERATION_H_ 5 #ifndef CC_TRANSFORM_OPERATION_H_
6 #define CC_TRANSFORM_OPERATION_H 6 #define CC_TRANSFORM_OPERATION_H
7 7
8 #include "third_party/WebKit/Source/Platform/chromium/public/WebTransformationMa trix.h" 8 #include "ui/gfx/transform.h"
9 9
10 namespace cc { 10 namespace cc {
11 11
12 struct TransformOperation { 12 struct TransformOperation {
13 enum Type { 13 enum Type {
14 TransformOperationTranslate, 14 TransformOperationTranslate,
15 TransformOperationRotate, 15 TransformOperationRotate,
16 TransformOperationScale, 16 TransformOperationScale,
17 TransformOperationSkew, 17 TransformOperationSkew,
18 TransformOperationPerspective, 18 TransformOperationPerspective,
19 TransformOperationMatrix, 19 TransformOperationMatrix,
20 TransformOperationIdentity 20 TransformOperationIdentity
21 }; 21 };
22 22
23 TransformOperation() 23 TransformOperation()
24 : type(TransformOperationIdentity) { 24 : type(TransformOperationIdentity) {
25 } 25 }
26 26
27 Type type; 27 Type type;
28 WebKit::WebTransformationMatrix matrix; 28 gfx::Transform matrix;
29 29
30 union { 30 union {
31 double perspective_depth; 31 double perspective_depth;
32 32
33 struct { 33 struct {
34 double x, y; 34 double x, y;
35 } skew; 35 } skew;
36 36
37 struct { 37 struct {
38 double x, y, z; 38 double x, y, z;
39 } scale; 39 } scale;
40 40
41 struct { 41 struct {
42 double x, y, z; 42 double x, y, z;
43 } translate; 43 } translate;
44 44
45 struct { 45 struct {
46 struct { 46 struct {
47 double x, y, z; 47 double x, y, z;
48 } axis; 48 } axis;
49 49
50 double angle; 50 double angle;
51 } rotate; 51 } rotate;
52 }; 52 };
53 53
54 bool IsIdentity() const; 54 bool IsIdentity() const;
55 static bool BlendTransformOperations(const TransformOperation* from, 55 static bool BlendTransformOperations(const TransformOperation* from,
56 const TransformOperation* to, 56 const TransformOperation* to,
57 double progress, 57 double progress,
58 WebKit::WebTransformationMatrix& result); 58 gfx::Transform& result);
59 }; 59 };
60 60
61 } // namespace cc 61 } // namespace cc
62 62
63 #endif // CC_TRANSFORM_OPERATION_H_ 63 #endif // CC_TRANSFORM_OPERATION_H_
OLDNEW
« no previous file with comments | « cc/test/geometry_test_utils.cc ('k') | cc/transform_operation.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698