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

Side by Side Diff: third_party/WebKit/Source/platform/transforms/TransformationMatrix.h

Issue 1602343002: compositor-worker: cc->blink mutation plumbing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@compositor-worker-ian-patch
Patch Set: Created 4 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2006 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2005, 2006 Apple Computer, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 setMatrix(a, b, c, d, e, f); 98 setMatrix(a, b, c, d, e, f);
99 } 99 }
100 TransformationMatrix(double m11, double m12, double m13, double m14, 100 TransformationMatrix(double m11, double m12, double m13, double m14,
101 double m21, double m22, double m23, double m24, 101 double m21, double m22, double m23, double m24,
102 double m31, double m32, double m33, double m34, 102 double m31, double m32, double m33, double m34,
103 double m41, double m42, double m43, double m44) 103 double m41, double m42, double m43, double m44)
104 { 104 {
105 checkAlignment(); 105 checkAlignment();
106 setMatrix(m11, m12, m13, m14, m21, m22, m23, m24, m31, m32, m33, m34, m4 1, m42, m43, m44); 106 setMatrix(m11, m12, m13, m14, m21, m22, m23, m24, m31, m32, m33, m34, m4 1, m42, m43, m44);
107 } 107 }
108 TransformationMatrix(const SkMatrix44& matrix)
109 {
110 setMatrix(
111 matrix.get(0, 0), matrix.get(1, 0), matrix.get(2, 0), matrix.get(3, 0),
112 matrix.get(0, 1), matrix.get(1, 1), matrix.get(2, 1), matrix.get(3, 1),
113 matrix.get(0, 2), matrix.get(1, 2), matrix.get(2, 2), matrix.get(3, 2),
114 matrix.get(0, 3), matrix.get(1, 3), matrix.get(2, 3), matrix.get(3, 3));
115 }
108 116
109 void setMatrix(double a, double b, double c, double d, double e, double f) 117 void setMatrix(double a, double b, double c, double d, double e, double f)
110 { 118 {
111 m_matrix[0][0] = a; 119 m_matrix[0][0] = a;
112 m_matrix[0][1] = b; 120 m_matrix[0][1] = b;
113 m_matrix[0][2] = 0; 121 m_matrix[0][2] = 0;
114 m_matrix[0][3] = 0; 122 m_matrix[0][3] = 0;
115 m_matrix[1][0] = c; 123 m_matrix[1][0] = c;
116 m_matrix[1][1] = d; 124 m_matrix[1][1] = d;
117 m_matrix[1][2] = 0; 125 m_matrix[1][2] = 0;
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 Matrix4 m_matrix; 427 Matrix4 m_matrix;
420 }; 428 };
421 429
422 // Redeclared here to avoid ODR issues. 430 // Redeclared here to avoid ODR issues.
423 // See platform/testing/TransformPrinters.h. 431 // See platform/testing/TransformPrinters.h.
424 void PrintTo(const TransformationMatrix&, std::ostream*); 432 void PrintTo(const TransformationMatrix&, std::ostream*);
425 433
426 } // namespace blink 434 } // namespace blink
427 435
428 #endif // TransformationMatrix_h 436 #endif // TransformationMatrix_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698