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

Unified Diff: tests/MatrixTest.cpp

Issue 864713002: remove dead SkPersp macros (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/ports/SkFontHost_win.cpp ('k') | tests/PathTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/MatrixTest.cpp
diff --git a/tests/MatrixTest.cpp b/tests/MatrixTest.cpp
index 8a27a9eddfff380e0ccb7a8cee37d977ae700266..7875d9ea45cd5e726cde798521eff1c6f1d25739 100644
--- a/tests/MatrixTest.cpp
+++ b/tests/MatrixTest.cpp
@@ -202,7 +202,7 @@ static void test_matrix_min_max_scale(skiatest::Reporter* reporter) {
SkMatrix perspX;
perspX.reset();
- perspX.setPerspX(SkScalarToPersp(SK_Scalar1 / 1000));
+ perspX.setPerspX(SK_Scalar1 / 1000);
REPORTER_ASSERT(reporter, -SK_Scalar1 == perspX.getMinScale());
REPORTER_ASSERT(reporter, -SK_Scalar1 == perspX.getMaxScale());
// Verify that getMinMaxScales() doesn't update the scales array on failure.
@@ -213,7 +213,7 @@ static void test_matrix_min_max_scale(skiatest::Reporter* reporter) {
SkMatrix perspY;
perspY.reset();
- perspY.setPerspY(SkScalarToPersp(-SK_Scalar1 / 500));
+ perspY.setPerspY(-SK_Scalar1 / 500);
REPORTER_ASSERT(reporter, -SK_Scalar1 == perspY.getMinScale());
REPORTER_ASSERT(reporter, -SK_Scalar1 == perspY.getMaxScale());
scales[0] = -5;
@@ -358,13 +358,13 @@ static void test_matrix_preserve_shape(skiatest::Reporter* reporter) {
// perspective x
mat.reset();
- mat.setPerspX(SkScalarToPersp(SK_Scalar1 / 2));
+ mat.setPerspX(SK_Scalar1 / 2);
REPORTER_ASSERT(reporter, !mat.isSimilarity());
REPORTER_ASSERT(reporter, !mat.preservesRightAngles());
// perspective y
mat.reset();
- mat.setPerspY(SkScalarToPersp(SK_Scalar1 / 2));
+ mat.setPerspY(SK_Scalar1 / 2);
REPORTER_ASSERT(reporter, !mat.isSimilarity());
REPORTER_ASSERT(reporter, !mat.preservesRightAngles());
@@ -867,7 +867,7 @@ DEF_TEST(Matrix, reporter) {
REPORTER_ASSERT(reporter, affineEqual(TransY));
#undef affineEqual
- mat.set(SkMatrix::kMPersp1, SkScalarToPersp(SK_Scalar1 / 2));
+ mat.set(SkMatrix::kMPersp1, SK_Scalar1 / 2);
REPORTER_ASSERT(reporter, !mat.asAffine(affine));
SkMatrix mat2;
« no previous file with comments | « src/ports/SkFontHost_win.cpp ('k') | tests/PathTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698