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

Side by Side Diff: webkit/compositor_bindings/web_transformation_matrix_unittest.cc

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, 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
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 #define _USE_MATH_DEFINES 5 #define _USE_MATH_DEFINES
6 #include <math.h> 6 #include <math.h>
7 7
8 #include "cc/test/geometry_test_utils.h"
9 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
10 #include "third_party/WebKit/Source/Platform/chromium/public/WebTransformationMa trix.h" 9 #include "third_party/WebKit/Source/Platform/chromium/public/WebTransformationMa trix.h"
11 10
12 #define EXPECT_ROW1_EQ(a, b, c, d, matrix) \ 11 #define EXPECT_ROW1_EQ(a, b, c, d, matrix) \
13 EXPECT_FLOAT_EQ((a), (matrix).m11()); \ 12 EXPECT_FLOAT_EQ((a), (matrix).m11()); \
14 EXPECT_FLOAT_EQ((b), (matrix).m21()); \ 13 EXPECT_FLOAT_EQ((b), (matrix).m21()); \
15 EXPECT_FLOAT_EQ((c), (matrix).m31()); \ 14 EXPECT_FLOAT_EQ((c), (matrix).m31()); \
16 EXPECT_FLOAT_EQ((d), (matrix).m41()); 15 EXPECT_FLOAT_EQ((d), (matrix).m41());
17 16
18 #define EXPECT_ROW2_EQ(a, b, c, d, matrix) \ 17 #define EXPECT_ROW2_EQ(a, b, c, d, matrix) \
19 EXPECT_FLOAT_EQ((a), (matrix).m12()); \ 18 EXPECT_FLOAT_EQ((a), (matrix).m12()); \
20 EXPECT_FLOAT_EQ((b), (matrix).m22()); \ 19 EXPECT_FLOAT_EQ((b), (matrix).m22()); \
21 EXPECT_FLOAT_EQ((c), (matrix).m32()); \ 20 EXPECT_FLOAT_EQ((c), (matrix).m32()); \
22 EXPECT_FLOAT_EQ((d), (matrix).m42()); 21 EXPECT_FLOAT_EQ((d), (matrix).m42());
23 22
24 #define EXPECT_ROW3_EQ(a, b, c, d, matrix) \ 23 #define EXPECT_ROW3_EQ(a, b, c, d, matrix) \
25 EXPECT_FLOAT_EQ((a), (matrix).m13()); \ 24 EXPECT_FLOAT_EQ((a), (matrix).m13()); \
26 EXPECT_FLOAT_EQ((b), (matrix).m23()); \ 25 EXPECT_FLOAT_EQ((b), (matrix).m23()); \
27 EXPECT_FLOAT_EQ((c), (matrix).m33()); \ 26 EXPECT_FLOAT_EQ((c), (matrix).m33()); \
28 EXPECT_FLOAT_EQ((d), (matrix).m43()); 27 EXPECT_FLOAT_EQ((d), (matrix).m43());
29 28
30 #define EXPECT_ROW4_EQ(a, b, c, d, matrix) \ 29 #define EXPECT_ROW4_EQ(a, b, c, d, matrix) \
31 EXPECT_FLOAT_EQ((a), (matrix).m14()); \ 30 EXPECT_FLOAT_EQ((a), (matrix).m14()); \
32 EXPECT_FLOAT_EQ((b), (matrix).m24()); \ 31 EXPECT_FLOAT_EQ((b), (matrix).m24()); \
33 EXPECT_FLOAT_EQ((c), (matrix).m34()); \ 32 EXPECT_FLOAT_EQ((c), (matrix).m34()); \
34 EXPECT_FLOAT_EQ((d), (matrix).m44()); 33 EXPECT_FLOAT_EQ((d), (matrix).m44());
35 34
35 #define EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(expected, actual) \
36 EXPECT_FLOAT_EQ((expected).m11(), (actual).m11()); \
37 EXPECT_FLOAT_EQ((expected).m12(), (actual).m12()); \
38 EXPECT_FLOAT_EQ((expected).m13(), (actual).m13()); \
39 EXPECT_FLOAT_EQ((expected).m14(), (actual).m14()); \
40 EXPECT_FLOAT_EQ((expected).m21(), (actual).m21()); \
41 EXPECT_FLOAT_EQ((expected).m22(), (actual).m22()); \
42 EXPECT_FLOAT_EQ((expected).m23(), (actual).m23()); \
43 EXPECT_FLOAT_EQ((expected).m24(), (actual).m24()); \
44 EXPECT_FLOAT_EQ((expected).m31(), (actual).m31()); \
45 EXPECT_FLOAT_EQ((expected).m32(), (actual).m32()); \
46 EXPECT_FLOAT_EQ((expected).m33(), (actual).m33()); \
47 EXPECT_FLOAT_EQ((expected).m34(), (actual).m34()); \
48 EXPECT_FLOAT_EQ((expected).m41(), (actual).m41()); \
49 EXPECT_FLOAT_EQ((expected).m42(), (actual).m42()); \
50 EXPECT_FLOAT_EQ((expected).m43(), (actual).m43()); \
51 EXPECT_FLOAT_EQ((expected).m44(), (actual).m44());
52
36 // Checking float values for equality close to zero is not robust using EXPECT_F LOAT_EQ 53 // Checking float values for equality close to zero is not robust using EXPECT_F LOAT_EQ
37 // (see gtest documentation). So, to verify rotation matrices, we must use a loo ser 54 // (see gtest documentation). So, to verify rotation matrices, we must use a loo ser
38 // absolute error threshold in some places. 55 // absolute error threshold in some places.
39 #define EXPECT_ROW1_NEAR(a, b, c, d, matrix, errorThreshold) \ 56 #define EXPECT_ROW1_NEAR(a, b, c, d, matrix, errorThreshold) \
40 EXPECT_NEAR((a), (matrix).m11(), (errorThreshold)); \ 57 EXPECT_NEAR((a), (matrix).m11(), (errorThreshold)); \
41 EXPECT_NEAR((b), (matrix).m21(), (errorThreshold)); \ 58 EXPECT_NEAR((b), (matrix).m21(), (errorThreshold)); \
42 EXPECT_NEAR((c), (matrix).m31(), (errorThreshold)); \ 59 EXPECT_NEAR((c), (matrix).m31(), (errorThreshold)); \
43 EXPECT_NEAR((d), (matrix).m41(), (errorThreshold)); 60 EXPECT_NEAR((d), (matrix).m41(), (errorThreshold));
44 61
45 #define EXPECT_ROW2_NEAR(a, b, c, d, matrix, errorThreshold) \ 62 #define EXPECT_ROW2_NEAR(a, b, c, d, matrix, errorThreshold) \
(...skipping 941 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 TEST(WebTransformationMatrixTest, verifyBlendForTranslation) 1004 TEST(WebTransformationMatrixTest, verifyBlendForTranslation)
988 { 1005 {
989 WebTransformationMatrix from; 1006 WebTransformationMatrix from;
990 from.translate3d(100, 200, 100); 1007 from.translate3d(100, 200, 100);
991 1008
992 WebTransformationMatrix to; 1009 WebTransformationMatrix to;
993 1010
994 to.makeIdentity(); 1011 to.makeIdentity();
995 to.translate3d(200, 100, 300); 1012 to.translate3d(200, 100, 300);
996 to.blend(from, 0); 1013 to.blend(from, 0);
997 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1014 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
998 1015
999 to.makeIdentity(); 1016 to.makeIdentity();
1000 to.translate3d(200, 100, 300); 1017 to.translate3d(200, 100, 300);
1001 to.blend(from, 0.25); 1018 to.blend(from, 0.25);
1002 EXPECT_ROW1_EQ(1, 0, 0, 125, to); 1019 EXPECT_ROW1_EQ(1, 0, 0, 125, to);
1003 EXPECT_ROW2_EQ(0, 1, 0, 175, to); 1020 EXPECT_ROW2_EQ(0, 1, 0, 175, to);
1004 EXPECT_ROW3_EQ(0, 0, 1, 150, to); 1021 EXPECT_ROW3_EQ(0, 0, 1, 150, to);
1005 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1022 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1006 1023
1007 to.makeIdentity(); 1024 to.makeIdentity();
(...skipping 16 matching lines...) Expand all
1024 TEST(WebTransformationMatrixTest, verifyBlendForScale) 1041 TEST(WebTransformationMatrixTest, verifyBlendForScale)
1025 { 1042 {
1026 WebTransformationMatrix from; 1043 WebTransformationMatrix from;
1027 from.scale3d(100, 200, 100); 1044 from.scale3d(100, 200, 100);
1028 1045
1029 WebTransformationMatrix to; 1046 WebTransformationMatrix to;
1030 1047
1031 to.makeIdentity(); 1048 to.makeIdentity();
1032 to.scale3d(200, 100, 300); 1049 to.scale3d(200, 100, 300);
1033 to.blend(from, 0); 1050 to.blend(from, 0);
1034 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1051 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1035 1052
1036 to.makeIdentity(); 1053 to.makeIdentity();
1037 to.scale3d(200, 100, 300); 1054 to.scale3d(200, 100, 300);
1038 to.blend(from, 0.25); 1055 to.blend(from, 0.25);
1039 EXPECT_ROW1_EQ(125, 0, 0, 0, to); 1056 EXPECT_ROW1_EQ(125, 0, 0, 0, to);
1040 EXPECT_ROW2_EQ(0, 175, 0, 0, to); 1057 EXPECT_ROW2_EQ(0, 175, 0, 0, to);
1041 EXPECT_ROW3_EQ(0, 0, 150, 0, to); 1058 EXPECT_ROW3_EQ(0, 0, 150, 0, to);
1042 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1059 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1043 1060
1044 to.makeIdentity(); 1061 to.makeIdentity();
(...skipping 16 matching lines...) Expand all
1061 TEST(WebTransformationMatrixTest, verifyBlendForSkewX) 1078 TEST(WebTransformationMatrixTest, verifyBlendForSkewX)
1062 { 1079 {
1063 WebTransformationMatrix from; 1080 WebTransformationMatrix from;
1064 from.skewX(0); 1081 from.skewX(0);
1065 1082
1066 WebTransformationMatrix to; 1083 WebTransformationMatrix to;
1067 1084
1068 to.makeIdentity(); 1085 to.makeIdentity();
1069 to.skewX(45); 1086 to.skewX(45);
1070 to.blend(from, 0); 1087 to.blend(from, 0);
1071 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1088 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1072 1089
1073 to.makeIdentity(); 1090 to.makeIdentity();
1074 to.skewX(45); 1091 to.skewX(45);
1075 to.blend(from, 0.5); 1092 to.blend(from, 0.5);
1076 EXPECT_ROW1_EQ(1, 0.5, 0, 0, to); 1093 EXPECT_ROW1_EQ(1, 0.5, 0, 0, to);
1077 EXPECT_ROW2_EQ(0, 1, 0, 0, to); 1094 EXPECT_ROW2_EQ(0, 1, 0, 0, to);
1078 EXPECT_ROW3_EQ(0, 0, 1, 0, to); 1095 EXPECT_ROW3_EQ(0, 0, 1, 0, to);
1079 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1096 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1080 1097
1081 to.makeIdentity(); 1098 to.makeIdentity();
(...skipping 28 matching lines...) Expand all
1110 // implementation just happens to decompose those test matrices intuitively. 1127 // implementation just happens to decompose those test matrices intuitively.
1111 1128
1112 WebTransformationMatrix from; 1129 WebTransformationMatrix from;
1113 from.skewY(0); 1130 from.skewY(0);
1114 1131
1115 WebTransformationMatrix to; 1132 WebTransformationMatrix to;
1116 1133
1117 to.makeIdentity(); 1134 to.makeIdentity();
1118 to.skewY(45); 1135 to.skewY(45);
1119 to.blend(from, 0); 1136 to.blend(from, 0);
1120 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1137 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1121 1138
1122 to.makeIdentity(); 1139 to.makeIdentity();
1123 to.skewY(45); 1140 to.skewY(45);
1124 to.blend(from, 0.25); 1141 to.blend(from, 0.25);
1125 EXPECT_ROW1_NEAR(1.0823489449280947471976333, 0.0464370719145053845178239, 0 , 0, to, LOOSE_ERROR_THRESHOLD); 1142 EXPECT_ROW1_NEAR(1.0823489449280947471976333, 0.0464370719145053845178239, 0 , 0, to, LOOSE_ERROR_THRESHOLD);
1126 EXPECT_ROW2_NEAR(0.2152925909665224513123150, 0.9541702441750861130032035, 0 , 0, to, LOOSE_ERROR_THRESHOLD); 1143 EXPECT_ROW2_NEAR(0.2152925909665224513123150, 0.9541702441750861130032035, 0 , 0, to, LOOSE_ERROR_THRESHOLD);
1127 EXPECT_ROW3_EQ(0, 0, 1, 0, to); 1144 EXPECT_ROW3_EQ(0, 0, 1, 0, to);
1128 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1145 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1129 1146
1130 to.makeIdentity(); 1147 to.makeIdentity();
(...skipping 21 matching lines...) Expand all
1152 // against manually specified matrices from Euler angles. 1169 // against manually specified matrices from Euler angles.
1153 1170
1154 WebTransformationMatrix from; 1171 WebTransformationMatrix from;
1155 from.rotate3d(1, 0, 0, 0); 1172 from.rotate3d(1, 0, 0, 0);
1156 1173
1157 WebTransformationMatrix to; 1174 WebTransformationMatrix to;
1158 1175
1159 to.makeIdentity(); 1176 to.makeIdentity();
1160 to.rotate3d(1, 0, 0, 90); 1177 to.rotate3d(1, 0, 0, 90);
1161 to.blend(from, 0); 1178 to.blend(from, 0);
1162 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1179 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1163 1180
1164 double expectedRotationAngle = 22.5 * M_PI / 180.0; 1181 double expectedRotationAngle = 22.5 * M_PI / 180.0;
1165 to.makeIdentity(); 1182 to.makeIdentity();
1166 to.rotate3d(1, 0, 0, 90); 1183 to.rotate3d(1, 0, 0, 90);
1167 to.blend(from, 0.25); 1184 to.blend(from, 0.25);
1168 EXPECT_ROW1_NEAR(1, 0, 0, 0, to, ERROR_THRESHOLD); 1185 EXPECT_ROW1_NEAR(1, 0, 0, 0, to, ERROR_THRESHOLD);
1169 EXPECT_ROW2_NEAR(0, cos(expectedRotationAngle), -sin(expectedRotationAngle), 0, to, ERROR_THRESHOLD); 1186 EXPECT_ROW2_NEAR(0, cos(expectedRotationAngle), -sin(expectedRotationAngle), 0, to, ERROR_THRESHOLD);
1170 EXPECT_ROW3_NEAR(0, sin(expectedRotationAngle), cos(expectedRotationAngle), 0, to, ERROR_THRESHOLD); 1187 EXPECT_ROW3_NEAR(0, sin(expectedRotationAngle), cos(expectedRotationAngle), 0, to, ERROR_THRESHOLD);
1171 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1188 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1172 1189
(...skipping 18 matching lines...) Expand all
1191 TEST(WebTransformationMatrixTest, verifyBlendForRotationAboutY) 1208 TEST(WebTransformationMatrixTest, verifyBlendForRotationAboutY)
1192 { 1209 {
1193 WebTransformationMatrix from; 1210 WebTransformationMatrix from;
1194 from.rotate3d(0, 1, 0, 0); 1211 from.rotate3d(0, 1, 0, 0);
1195 1212
1196 WebTransformationMatrix to; 1213 WebTransformationMatrix to;
1197 1214
1198 to.makeIdentity(); 1215 to.makeIdentity();
1199 to.rotate3d(0, 1, 0, 90); 1216 to.rotate3d(0, 1, 0, 90);
1200 to.blend(from, 0); 1217 to.blend(from, 0);
1201 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1218 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1202 1219
1203 double expectedRotationAngle = 22.5 * M_PI / 180.0; 1220 double expectedRotationAngle = 22.5 * M_PI / 180.0;
1204 to.makeIdentity(); 1221 to.makeIdentity();
1205 to.rotate3d(0, 1, 0, 90); 1222 to.rotate3d(0, 1, 0, 90);
1206 to.blend(from, 0.25); 1223 to.blend(from, 0.25);
1207 EXPECT_ROW1_NEAR(cos(expectedRotationAngle), 0, sin(expectedRotationAngle), 0, to, ERROR_THRESHOLD); 1224 EXPECT_ROW1_NEAR(cos(expectedRotationAngle), 0, sin(expectedRotationAngle), 0, to, ERROR_THRESHOLD);
1208 EXPECT_ROW2_NEAR(0, 1, 0, 0, to, ERROR_THRESHOLD); 1225 EXPECT_ROW2_NEAR(0, 1, 0, 0, to, ERROR_THRESHOLD);
1209 EXPECT_ROW3_NEAR(-sin(expectedRotationAngle), 0, cos(expectedRotationAngle), 0, to, ERROR_THRESHOLD); 1226 EXPECT_ROW3_NEAR(-sin(expectedRotationAngle), 0, cos(expectedRotationAngle), 0, to, ERROR_THRESHOLD);
1210 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1227 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1211 1228
(...skipping 18 matching lines...) Expand all
1230 TEST(WebTransformationMatrixTest, verifyBlendForRotationAboutZ) 1247 TEST(WebTransformationMatrixTest, verifyBlendForRotationAboutZ)
1231 { 1248 {
1232 WebTransformationMatrix from; 1249 WebTransformationMatrix from;
1233 from.rotate3d(0, 0, 1, 0); 1250 from.rotate3d(0, 0, 1, 0);
1234 1251
1235 WebTransformationMatrix to; 1252 WebTransformationMatrix to;
1236 1253
1237 to.makeIdentity(); 1254 to.makeIdentity();
1238 to.rotate3d(0, 0, 1, 90); 1255 to.rotate3d(0, 0, 1, 90);
1239 to.blend(from, 0); 1256 to.blend(from, 0);
1240 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1257 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1241 1258
1242 double expectedRotationAngle = 22.5 * M_PI / 180.0; 1259 double expectedRotationAngle = 22.5 * M_PI / 180.0;
1243 to.makeIdentity(); 1260 to.makeIdentity();
1244 to.rotate3d(0, 0, 1, 90); 1261 to.rotate3d(0, 0, 1, 90);
1245 to.blend(from, 0.25); 1262 to.blend(from, 0.25);
1246 EXPECT_ROW1_NEAR(cos(expectedRotationAngle), -sin(expectedRotationAngle), 0, 0, to, ERROR_THRESHOLD); 1263 EXPECT_ROW1_NEAR(cos(expectedRotationAngle), -sin(expectedRotationAngle), 0, 0, to, ERROR_THRESHOLD);
1247 EXPECT_ROW2_NEAR(sin(expectedRotationAngle), cos(expectedRotationAngle), 0, 0, to, ERROR_THRESHOLD); 1264 EXPECT_ROW2_NEAR(sin(expectedRotationAngle), cos(expectedRotationAngle), 0, 0, to, ERROR_THRESHOLD);
1248 EXPECT_ROW3_NEAR(0, 0, 1, 0, to, ERROR_THRESHOLD); 1265 EXPECT_ROW3_NEAR(0, 0, 1, 0, to, ERROR_THRESHOLD);
1249 EXPECT_ROW4_EQ(0, 0, 0, 1, to); 1266 EXPECT_ROW4_EQ(0, 0, 0, 1, to);
1250 1267
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
1283 1300
1284 WebTransformationMatrix expectedEndOfAnimation; 1301 WebTransformationMatrix expectedEndOfAnimation;
1285 expectedEndOfAnimation.applyPerspective(1); 1302 expectedEndOfAnimation.applyPerspective(1);
1286 expectedEndOfAnimation.translate3d(10, 20, 30); 1303 expectedEndOfAnimation.translate3d(10, 20, 30);
1287 expectedEndOfAnimation.rotate3d(0, 0, 1, 25); 1304 expectedEndOfAnimation.rotate3d(0, 0, 1, 25);
1288 expectedEndOfAnimation.skewY(45); 1305 expectedEndOfAnimation.skewY(45);
1289 expectedEndOfAnimation.scale3d(6, 7, 8); 1306 expectedEndOfAnimation.scale3d(6, 7, 8);
1290 1307
1291 to = expectedEndOfAnimation; 1308 to = expectedEndOfAnimation;
1292 to.blend(from, 0); 1309 to.blend(from, 0);
1293 EXPECT_TRANSFORMATION_MATRIX_EQ(from, to); 1310 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(from, to);
1294 1311
1295 to = expectedEndOfAnimation; 1312 to = expectedEndOfAnimation;
1296 to.blend(from, 1); 1313 to.blend(from, 1);
1297 1314
1298 // Recomposing the matrix results in a normalized matrix, so to verify we ne ed to 1315 // Recomposing the matrix results in a normalized matrix, so to verify we ne ed to
1299 // normalize the expectedEndOfAnimation before comparing elements. Normalizi ng means 1316 // normalize the expectedEndOfAnimation before comparing elements. Normalizi ng means
1300 // dividing everything by expectedEndOfAnimation.m44(). 1317 // dividing everything by expectedEndOfAnimation.m44().
1301 WebTransformationMatrix normalizedExpectedEndOfAnimation = expectedEndOfAnim ation; 1318 WebTransformationMatrix normalizedExpectedEndOfAnimation = expectedEndOfAnim ation;
1302 WebTransformationMatrix normalizationMatrix; 1319 WebTransformationMatrix normalizationMatrix;
1303 normalizationMatrix.setM11(1 / expectedEndOfAnimation.m44()); 1320 normalizationMatrix.setM11(1 / expectedEndOfAnimation.m44());
1304 normalizationMatrix.setM22(1 / expectedEndOfAnimation.m44()); 1321 normalizationMatrix.setM22(1 / expectedEndOfAnimation.m44());
1305 normalizationMatrix.setM33(1 / expectedEndOfAnimation.m44()); 1322 normalizationMatrix.setM33(1 / expectedEndOfAnimation.m44());
1306 normalizationMatrix.setM44(1 / expectedEndOfAnimation.m44()); 1323 normalizationMatrix.setM44(1 / expectedEndOfAnimation.m44());
1307 normalizedExpectedEndOfAnimation.multiply(normalizationMatrix); 1324 normalizedExpectedEndOfAnimation.multiply(normalizationMatrix);
1308 1325
1309 EXPECT_TRANSFORMATION_MATRIX_EQ(normalizedExpectedEndOfAnimation, to); 1326 EXPECT_WEB_TRANSFORMATION_MATRIX_EQ(normalizedExpectedEndOfAnimation, to);
1310 } 1327 }
1311 1328
1312 } // namespace 1329 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698