OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "SkFloatingPoint.h" | 8 #include "SkFloatingPoint.h" |
9 #include "SkMath.h" | 9 #include "SkMath.h" |
10 #include "SkPoint.h" | 10 #include "SkPoint.h" |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 }; | 47 }; |
48 static const SkPoint gI2[] = { | 48 static const SkPoint gI2[] = { |
49 { 0, 0 }, { 1, 1 }, { 99.234f, -42342 }, { SK_ScalarInfinity, 3 }, { 2,
3 }, | 49 { 0, 0 }, { 1, 1 }, { 99.234f, -42342 }, { SK_ScalarInfinity, 3 }, { 2,
3 }, |
50 }; | 50 }; |
51 static const SkPoint gI3[] = { | 51 static const SkPoint gI3[] = { |
52 { 0, 0 }, { 1, 1 }, { 99.234f, -42342 }, { 3, SK_ScalarInfinity }, { 2,
3 }, | 52 { 0, 0 }, { 1, 1 }, { 99.234f, -42342 }, { 3, SK_ScalarInfinity }, { 2,
3 }, |
53 }; | 53 }; |
54 | 54 |
55 static const struct { | 55 static const struct { |
56 const SkPoint* fPts; | 56 const SkPoint* fPts; |
57 size_t fCount; | 57 int fCount; |
58 bool fIsFinite; | 58 bool fIsFinite; |
59 } gSets[] = { | 59 } gSets[] = { |
60 { gF0, SK_ARRAY_COUNT(gF0), true }, | 60 { gF0, SK_ARRAY_COUNT(gF0), true }, |
61 { gF1, SK_ARRAY_COUNT(gF1), true }, | 61 { gF1, SK_ARRAY_COUNT(gF1), true }, |
62 | 62 |
63 { gI0, SK_ARRAY_COUNT(gI0), false }, | 63 { gI0, SK_ARRAY_COUNT(gI0), false }, |
64 { gI1, SK_ARRAY_COUNT(gI1), false }, | 64 { gI1, SK_ARRAY_COUNT(gI1), false }, |
65 { gI2, SK_ARRAY_COUNT(gI2), false }, | 65 { gI2, SK_ARRAY_COUNT(gI2), false }, |
66 { gI3, SK_ARRAY_COUNT(gI3), false }, | 66 { gI3, SK_ARRAY_COUNT(gI3), false }, |
67 }; | 67 }; |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
195 } | 195 } |
196 | 196 |
197 #if defined _WIN32 | 197 #if defined _WIN32 |
198 #pragma warning ( pop ) | 198 #pragma warning ( pop ) |
199 #endif | 199 #endif |
200 | 200 |
201 DEF_TEST(Scalar, reporter) { | 201 DEF_TEST(Scalar, reporter) { |
202 test_isfinite(reporter); | 202 test_isfinite(reporter); |
203 test_roundtoint(reporter); | 203 test_roundtoint(reporter); |
204 } | 204 } |
OLD | NEW |