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 "PathOpsExtendedTest.h" | 7 #include "PathOpsExtendedTest.h" |
8 #include "PathOpsTestCommon.h" | 8 #include "PathOpsTestCommon.h" |
9 | 9 |
10 class PathTest_Private { | 10 class PathTest_Private { |
(...skipping 6515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6526 path.lineTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f | 6526 path.lineTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f |
6527 path.close(); | 6527 path.close(); |
6528 path.moveTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f | 6528 path.moveTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f |
6529 path.cubicTo(SkBits2Float(0xe3000000), SkBits2Float(0xe39e92c7), SkBits2Float(0x
f17febcb), SkBits2Float(0xff7febcb), SkBits2Float(0xeed0ee9a), SkBits2Float(0x9a
98ffca)); // -2.36118e+21f, -5.85032e+21f, -1.26726e+30f, -3.40177e+38f, -3.233
07e+28f, -6.3279e-23f | 6529 path.cubicTo(SkBits2Float(0xe3000000), SkBits2Float(0xe39e92c7), SkBits2Float(0x
f17febcb), SkBits2Float(0xff7febcb), SkBits2Float(0xeed0ee9a), SkBits2Float(0x9a
98ffca)); // -2.36118e+21f, -5.85032e+21f, -1.26726e+30f, -3.40177e+38f, -3.233
07e+28f, -6.3279e-23f |
6530 path.lineTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f | 6530 path.lineTo(SkBits2Float(0xba98ffee), SkBits2Float(0xfafafa1a)); // -0.0011673f
, -6.51573e+35f |
6531 path.close(); | 6531 path.close(); |
6532 SkPath path2(path); | 6532 SkPath path2(path); |
6533 testPathOpFail(reporter, path1, path2, kXOR_SkPathOp, filename); | 6533 testPathOpFail(reporter, path1, path2, kXOR_SkPathOp, filename); |
6534 } | 6534 } |
6535 | 6535 |
| 6536 static void fuzz763_10(skiatest::Reporter* reporter, const char* filename) { |
| 6537 SkPath path; |
| 6538 path.setFillType((SkPath::FillType) 1); |
| 6539 path.moveTo(SkBits2Float(0x00000000), SkBits2Float(0x68556829)); // 0, 4.03114e
+24f |
| 6540 path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000)); // 0, 0 |
| 6541 path.quadTo(SkBits2Float(0x6a4b7bc0), SkBits2Float(0x00000000), SkBits2Float(0x0
0000000), SkBits2Float(0x6a4b7bc4)); // 6.14991e+25f, 0, 0, 6.14991e+25f |
| 6542 path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x68556829)); // 0, 4.03114e
+24f |
| 6543 path.close(); |
| 6544 |
| 6545 SkPath path1(path); |
| 6546 path.reset(); |
| 6547 path.setFillType((SkPath::FillType) 0); |
| 6548 path.moveTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000)); // 0, 0 |
| 6549 path.lineTo(SkBits2Float(0x5b2d2968), SkBits2Float(0x2a8c8f55)); // 4.87407e+16
f, 2.49685e-13f |
| 6550 path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000)); // 0, 0 |
| 6551 path.close(); |
| 6552 path.moveTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6553 path.conicTo(SkBits2Float(0x682d2fed), SkBits2Float(0x755b6829), SkBits2Float(0x
5b292d2b), SkBits2Float(0xc92a8c55), SkBits2Float(0x081f2a21)); // 3.27141e+24f
, 2.78131e+32f, 4.76189e+16f, -698565, 4.78968e-34f |
| 6554 path.lineTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6555 path.close(); |
| 6556 path.moveTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6557 path.conicTo(SkBits2Float(0x6a4b7bc0), SkBits2Float(0x2a8ced7a), SkBits2Float(0x
21081f21), SkBits2Float(0x3a7bc003), SkBits2Float(0x47ed7a29)); // 6.14991e+25f
, 2.50338e-13f, 4.61198e-19f, 0.00096035f, 121588 |
| 6558 path.lineTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6559 path.close(); |
| 6560 path.moveTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6561 path.quadTo(SkBits2Float(0x6829682d), SkBits2Float(0x292d555b), SkBits2Float(0x2
a8c555b), SkBits2Float(0x081f2a29)); // 3.20001e+24f, 3.84878e-14f, 2.49282e-13
f, 4.78969e-34f |
| 6562 path.conicTo(SkBits2Float(0x6a497b19), SkBits2Float(0x218ced7a), SkBits2Float(0x
0321081f), SkBits2Float(0x6a3a7bc0), SkBits2Float(0x47ed3a7a)); // 6.08939e+25f
, 9.54963e-19f, 4.7323e-37f, 5.63611e+25f, 121461 |
| 6563 path.lineTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6564 path.close(); |
| 6565 path.moveTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6566 path.quadTo(SkBits2Float(0x282a282a), SkBits2Float(0x8a3a21df), SkBits2Float(0x2
728282a), SkBits2Float(0x8a3a2129)); // 9.4456e-15f, -8.96194e-33f, 2.33365e-15
f, -8.96181e-33f |
| 6567 path.quadTo(SkBits2Float(0x8a284f9a), SkBits2Float(0x3a3ac2b3), SkBits2Float(0x2
a292827), SkBits2Float(0x962be61d)); // -8.10388e-33f, 0.000712435f, 1.50241e-1
3f, -1.38859e-25f |
| 6568 path.lineTo(SkBits2Float(0x272a802a), SkBits2Float(0x2a8c2d29)); // 2.36617e-15
f, 2.49003e-13f |
| 6569 path.lineTo(SkBits2Float(0xc021211f), SkBits2Float(0x6a4b7b03)); // -2.51765f,
6.14982e+25f |
| 6570 path.close(); |
| 6571 path.moveTo(SkBits2Float(0x4f9a3a29), SkBits2Float(0x3ab38a28)); // 5.17501e+09
f, 0.00136978f |
| 6572 path.quadTo(SkBits2Float(0xc368305b), SkBits2Float(0x5b296855), SkBits2Float(0x2
d8c5568), SkBits2Float(0x1f2a2172)); // -232.189f, 4.7684e+16f, 1.59541e-11f, 3
.60266e-20f |
| 6573 path.lineTo(SkBits2Float(0x29c00321), SkBits2Float(0x5b4b7b13)); // 8.52706e-14
f, 5.72747e+16f |
| 6574 |
| 6575 SkPath path2(path); |
| 6576 testPathOpSkipAssert(reporter, path1, path2, (SkPathOp) 4, filename); |
| 6577 } |
| 6578 |
| 6579 |
6536 static struct TestDesc failTests[] = { | 6580 static struct TestDesc failTests[] = { |
| 6581 TEST(fuzz763_10), |
6537 TEST(kfuzz2), | 6582 TEST(kfuzz2), |
6538 TEST(fuzz763_7), | 6583 TEST(fuzz763_7), |
6539 TEST(fuzz763_6), | 6584 TEST(fuzz763_6), |
6540 TEST(fuzz763_2c), | 6585 TEST(fuzz763_2c), |
6541 TEST(fuzz763_2b), | 6586 TEST(fuzz763_2b), |
6542 TEST(fuzz763_2a), | 6587 TEST(fuzz763_2a), |
6543 TEST(fuzz763_5a), | 6588 TEST(fuzz763_5a), |
6544 TEST(fuzz763_3a), | 6589 TEST(fuzz763_3a), |
6545 TEST(fuzz763_1a), | 6590 TEST(fuzz763_1a), |
6546 TEST(fuzz763_1b), | 6591 TEST(fuzz763_1b), |
(...skipping 29 matching lines...) Expand all Loading... |
6576 static struct TestDesc repTests[] = { | 6621 static struct TestDesc repTests[] = { |
6577 TEST(loops44i), | 6622 TEST(loops44i), |
6578 TEST(loops45i), | 6623 TEST(loops45i), |
6579 TEST(loops46i), | 6624 TEST(loops46i), |
6580 }; | 6625 }; |
6581 | 6626 |
6582 DEF_TEST(PathOpsRepOp, reporter) { | 6627 DEF_TEST(PathOpsRepOp, reporter) { |
6583 for (int index = 0; index < 2; ++index) | 6628 for (int index = 0; index < 2; ++index) |
6584 RunTestSet(reporter, repTests, SK_ARRAY_COUNT(repTests), nullptr, nullptr, n
ullptr, false); | 6629 RunTestSet(reporter, repTests, SK_ARRAY_COUNT(repTests), nullptr, nullptr, n
ullptr, false); |
6585 } | 6630 } |
OLD | NEW |