| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #include "PathOpsCubicIntersectionTestData.h" | 7 #include "PathOpsCubicIntersectionTestData.h" |
| 8 #include "PathOpsTestCommon.h" | 8 #include "PathOpsTestCommon.h" |
| 9 #include "SkIntersections.h" | 9 #include "SkIntersections.h" |
| 10 #include "SkPathOpsRect.h" | 10 #include "SkPathOpsRect.h" |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 | 155 |
| 156 {{{18.1312339, 31.6473732}, {95.5711034, 63.5350219}, {92.3283165, 62.0158945}, | 156 {{{18.1312339, 31.6473732}, {95.5711034, 63.5350219}, {92.3283165, 62.0158945}, |
| 157 {18.5656052, 32.1268808}}}, | 157 {18.5656052, 32.1268808}}}, |
| 158 {{{97.402018, 35.7169972}, {33.1127443, 25.8935163}, {1.13970027, 54.9424981}, | 158 {{{97.402018, 35.7169972}, {33.1127443, 25.8935163}, {1.13970027, 54.9424981}, |
| 159 {56.4860195, 60.529264}}}, | 159 {56.4860195, 60.529264}}}, |
| 160 }; | 160 }; |
| 161 | 161 |
| 162 const int testSetCount = (int) SK_ARRAY_COUNT(testSet); | 162 const int testSetCount = (int) SK_ARRAY_COUNT(testSet); |
| 163 | 163 |
| 164 static const SkDCubic newTestSet[] = { | 164 static const SkDCubic newTestSet[] = { |
| 165 {{{980.9000244140625, 1474.3280029296875}, {980.9000244140625, 1474.328002929687
5}, {978.89300537109375, 1471.95703125}, {981.791015625, 1469.487060546875}}}, |
| 166 {{{981.791015625, 1469.487060546875}, {981.791015625, 1469.4859619140625}, {983.
3580322265625, 1472.72900390625}, {980.9000244140625, 1474.3280029296875}}}, |
| 167 |
| 165 {{{275,532}, {277.209137,532}, {279,530.209106}, {279,528}}}, | 168 {{{275,532}, {277.209137,532}, {279,530.209106}, {279,528}}}, |
| 166 {{{278,529}, {278,530.65686}, {276.65686,532}, {275,532}}}, | 169 {{{278,529}, {278,530.65686}, {276.65686,532}, {275,532}}}, |
| 167 | 170 |
| 168 #if 0 // FIXME: asserts coincidence, not working yet | 171 #if 0 // FIXME: asserts coincidence, not working yet |
| 169 {{{195, 785}, {124.30755615234375, 785}, {67, 841.85986328125}, {67, 912}}}, | 172 {{{195, 785}, {124.30755615234375, 785}, {67, 841.85986328125}, {67, 912}}}, |
| 170 {{{67, 913}, {67, 842.30755615234375}, {123.85984039306641, 785}, {194, 785}}}, | 173 {{{67, 913}, {67, 842.30755615234375}, {123.85984039306641, 785}, {194, 785}}}, |
| 171 #endif | 174 #endif |
| 172 | 175 |
| 173 {{{149,710.001465}, {149.000809,712.209961}, {150.791367,714}, {153,714}}}, | 176 {{{149,710.001465}, {149.000809,712.209961}, {150.791367,714}, {153,714}}}, |
| 174 {{{154,715}, {151.238571,715}, {149,712.761414}, {149,710}}}, | 177 {{{154,715}, {151.238571,715}, {149,712.761414}, {149,710}}}, |
| (...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 632 } | 635 } |
| 633 | 636 |
| 634 DEF_TEST(PathOpsCubicIntersection, reporter) { | 637 DEF_TEST(PathOpsCubicIntersection, reporter) { |
| 635 oneOffTests(reporter); | 638 oneOffTests(reporter); |
| 636 cubicIntersectionSelfTest(reporter); | 639 cubicIntersectionSelfTest(reporter); |
| 637 cubicIntersectionCoinTest(reporter); | 640 cubicIntersectionCoinTest(reporter); |
| 638 standardTestCases(reporter); | 641 standardTestCases(reporter); |
| 639 if (false) CubicIntersection_IntersectionFinder(); | 642 if (false) CubicIntersection_IntersectionFinder(); |
| 640 if (false) CubicIntersection_RandTest(reporter); | 643 if (false) CubicIntersection_RandTest(reporter); |
| 641 } | 644 } |
| OLD | NEW |