caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2012 Google Inc. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license that can be |
| 5 | * found in the LICENSE file. |
| 6 | */ |
| 7 | #include "PathOpsExtendedTest.h" |
| 8 | |
| 9 | #define TEST(name) { name, #name } |
| 10 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 11 | static void testLine1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 12 | SkPath path; |
| 13 | path.moveTo(2,0); |
| 14 | path.lineTo(1,1); |
| 15 | path.lineTo(0,0); |
| 16 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 17 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 18 | } |
| 19 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 20 | static void testLine1x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 21 | SkPath path; |
| 22 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 23 | path.moveTo(2,0); |
| 24 | path.lineTo(1,1); |
| 25 | path.lineTo(0,0); |
| 26 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 27 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 28 | } |
| 29 | |
| 30 | static void addInnerCWTriangle(SkPath& path) { |
| 31 | path.moveTo(3,0); |
| 32 | path.lineTo(4,1); |
| 33 | path.lineTo(2,1); |
| 34 | path.close(); |
| 35 | } |
| 36 | |
| 37 | static void addInnerCCWTriangle(SkPath& path) { |
| 38 | path.moveTo(3,0); |
| 39 | path.lineTo(2,1); |
| 40 | path.lineTo(4,1); |
| 41 | path.close(); |
| 42 | } |
| 43 | |
| 44 | static void addOuterCWTriangle(SkPath& path) { |
| 45 | path.moveTo(3,0); |
| 46 | path.lineTo(6,2); |
| 47 | path.lineTo(0,2); |
| 48 | path.close(); |
| 49 | } |
| 50 | |
| 51 | static void addOuterCCWTriangle(SkPath& path) { |
| 52 | path.moveTo(3,0); |
| 53 | path.lineTo(0,2); |
| 54 | path.lineTo(6,2); |
| 55 | path.close(); |
| 56 | } |
| 57 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 58 | static void testLine2(skiatest::Reporter* reporter, const char* filename) { |
| 59 | SkPath path; |
| 60 | addInnerCWTriangle(path); |
| 61 | addOuterCWTriangle(path); |
| 62 | testSimplify(reporter, path, filename); |
| 63 | } |
| 64 | |
| 65 | static void testLine2x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 66 | SkPath path; |
| 67 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 68 | addInnerCWTriangle(path); |
| 69 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 70 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 71 | } |
| 72 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 73 | static void testLine3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 74 | SkPath path; |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 75 | addInnerCCWTriangle(path); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 76 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 77 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 78 | } |
| 79 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 80 | static void testLine3x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 81 | SkPath path; |
| 82 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 83 | addInnerCCWTriangle(path); |
| 84 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 85 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 86 | } |
| 87 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 88 | static void testLine3a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 89 | SkPath path; |
| 90 | addInnerCWTriangle(path); |
| 91 | addOuterCCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 92 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 93 | } |
| 94 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 95 | static void testLine3ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 96 | SkPath path; |
| 97 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 98 | addInnerCWTriangle(path); |
| 99 | addOuterCCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 100 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 101 | } |
| 102 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 103 | static void testLine3b(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 104 | SkPath path; |
| 105 | addInnerCCWTriangle(path); |
| 106 | addOuterCCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 107 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 108 | } |
| 109 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 110 | static void testLine3bx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 111 | SkPath path; |
| 112 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 113 | addInnerCCWTriangle(path); |
| 114 | addOuterCCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 115 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 116 | } |
| 117 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 118 | static void testLine4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 119 | SkPath path; |
| 120 | addOuterCCWTriangle(path); |
| 121 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 122 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 123 | } |
| 124 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 125 | static void testLine4x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 126 | SkPath path; |
| 127 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 128 | addOuterCCWTriangle(path); |
| 129 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 130 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 131 | } |
| 132 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 133 | static void testLine5(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 134 | SkPath path; |
| 135 | addOuterCWTriangle(path); |
| 136 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 137 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 138 | } |
| 139 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 140 | static void testLine5x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 141 | SkPath path; |
| 142 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 143 | addOuterCWTriangle(path); |
| 144 | addOuterCWTriangle(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 145 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 146 | } |
| 147 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 148 | static void testLine6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 149 | SkPath path; |
| 150 | path.moveTo(0,0); |
| 151 | path.lineTo(4,0); |
| 152 | path.lineTo(2,2); |
| 153 | path.close(); |
| 154 | path.moveTo(2,0); |
| 155 | path.lineTo(6,0); |
| 156 | path.lineTo(4,2); |
| 157 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 158 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 159 | } |
| 160 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 161 | static void testLine6x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 162 | SkPath path; |
| 163 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 164 | path.moveTo(0,0); |
| 165 | path.lineTo(4,0); |
| 166 | path.lineTo(2,2); |
| 167 | path.close(); |
| 168 | path.moveTo(2,0); |
| 169 | path.lineTo(6,0); |
| 170 | path.lineTo(4,2); |
| 171 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 172 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 173 | } |
| 174 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 175 | static void testLine7(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 176 | SkPath path; |
| 177 | path.moveTo(0,0); |
| 178 | path.lineTo(4,0); |
| 179 | path.lineTo(2,2); |
| 180 | path.close(); |
| 181 | path.moveTo(6,0); |
| 182 | path.lineTo(2,0); |
| 183 | path.lineTo(4,2); |
| 184 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 185 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 186 | } |
| 187 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 188 | static void testLine7x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 189 | SkPath path; |
| 190 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 191 | path.moveTo(0,0); |
| 192 | path.lineTo(4,0); |
| 193 | path.lineTo(2,2); |
| 194 | path.close(); |
| 195 | path.moveTo(6,0); |
| 196 | path.lineTo(2,0); |
| 197 | path.lineTo(4,2); |
| 198 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 199 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 200 | } |
| 201 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 202 | static void testLine7a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 203 | SkPath path; |
| 204 | path.moveTo(0,0); |
| 205 | path.lineTo(4,0); |
| 206 | path.lineTo(2,2); |
| 207 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 208 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 209 | } |
| 210 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 211 | static void testLine7ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 212 | SkPath path; |
| 213 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 214 | path.moveTo(0,0); |
| 215 | path.lineTo(4,0); |
| 216 | path.lineTo(2,2); |
| 217 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 218 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 219 | } |
| 220 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 221 | static void testLine7b(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 222 | SkPath path; |
| 223 | path.moveTo(0,0); |
| 224 | path.lineTo(4,0); |
| 225 | path.close(); |
| 226 | path.moveTo(6,0); |
| 227 | path.lineTo(2,0); |
| 228 | path.lineTo(4,2); |
| 229 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 230 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 231 | } |
| 232 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 233 | static void testLine7bx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 234 | SkPath path; |
| 235 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 236 | path.moveTo(0,0); |
| 237 | path.lineTo(4,0); |
| 238 | path.close(); |
| 239 | path.moveTo(6,0); |
| 240 | path.lineTo(2,0); |
| 241 | path.lineTo(4,2); |
| 242 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 243 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 244 | } |
| 245 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 246 | static void testLine8(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 247 | SkPath path; |
| 248 | path.moveTo(0,4); |
| 249 | path.lineTo(4,4); |
| 250 | path.lineTo(2,2); |
| 251 | path.close(); |
| 252 | path.moveTo(2,4); |
| 253 | path.lineTo(6,4); |
| 254 | path.lineTo(4,2); |
| 255 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 256 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 257 | } |
| 258 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 259 | static void testLine8x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 260 | SkPath path; |
| 261 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 262 | path.moveTo(0,4); |
| 263 | path.lineTo(4,4); |
| 264 | path.lineTo(2,2); |
| 265 | path.close(); |
| 266 | path.moveTo(2,4); |
| 267 | path.lineTo(6,4); |
| 268 | path.lineTo(4,2); |
| 269 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 270 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 271 | } |
| 272 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 273 | static void testLine9(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 274 | SkPath path; |
| 275 | path.moveTo(0,4); |
| 276 | path.lineTo(4,4); |
| 277 | path.lineTo(2,2); |
| 278 | path.close(); |
| 279 | path.moveTo(6,4); |
| 280 | path.lineTo(2,4); |
| 281 | path.lineTo(4,2); |
| 282 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 283 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 284 | } |
| 285 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 286 | static void testLine9x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 287 | SkPath path; |
| 288 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 289 | path.moveTo(0,4); |
| 290 | path.lineTo(4,4); |
| 291 | path.lineTo(2,2); |
| 292 | path.close(); |
| 293 | path.moveTo(6,4); |
| 294 | path.lineTo(2,4); |
| 295 | path.lineTo(4,2); |
| 296 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 297 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 298 | } |
| 299 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 300 | static void testLine10(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 301 | SkPath path; |
| 302 | path.moveTo(0,4); |
| 303 | path.lineTo(4,4); |
| 304 | path.lineTo(2,2); |
| 305 | path.close(); |
| 306 | path.moveTo(2,1); |
| 307 | path.lineTo(3,4); |
| 308 | path.lineTo(6,1); |
| 309 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 310 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 311 | } |
| 312 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 313 | static void testLine10x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 314 | SkPath path; |
| 315 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 316 | path.moveTo(0,4); |
| 317 | path.lineTo(4,4); |
| 318 | path.lineTo(2,2); |
| 319 | path.close(); |
| 320 | path.moveTo(2,1); |
| 321 | path.lineTo(3,4); |
| 322 | path.lineTo(6,1); |
| 323 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 324 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 325 | } |
| 326 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 327 | static void testLine10a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 328 | SkPath path; |
| 329 | path.moveTo(0,4); |
| 330 | path.lineTo(8,4); |
| 331 | path.lineTo(4,0); |
| 332 | path.close(); |
| 333 | path.moveTo(2,2); |
| 334 | path.lineTo(3,3); |
| 335 | path.lineTo(4,2); |
| 336 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 337 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 338 | } |
| 339 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 340 | static void testLine10ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 341 | SkPath path; |
| 342 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 343 | path.moveTo(0,4); |
| 344 | path.lineTo(8,4); |
| 345 | path.lineTo(4,0); |
| 346 | path.close(); |
| 347 | path.moveTo(2,2); |
| 348 | path.lineTo(3,3); |
| 349 | path.lineTo(4,2); |
| 350 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 351 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 352 | } |
| 353 | |
| 354 | static void addCWContainer(SkPath& path) { |
| 355 | path.moveTo(6,4); |
| 356 | path.lineTo(0,4); |
| 357 | path.lineTo(3,1); |
| 358 | path.close(); |
| 359 | } |
| 360 | |
| 361 | static void addCCWContainer(SkPath& path) { |
| 362 | path.moveTo(0,4); |
| 363 | path.lineTo(6,4); |
| 364 | path.lineTo(3,1); |
| 365 | path.close(); |
| 366 | } |
| 367 | |
| 368 | static void addCWContents(SkPath& path) { |
| 369 | path.moveTo(2,3); |
| 370 | path.lineTo(3,2); |
| 371 | path.lineTo(4,3); |
| 372 | path.close(); |
| 373 | } |
| 374 | |
| 375 | static void addCCWContents(SkPath& path) { |
| 376 | path.moveTo(3,2); |
| 377 | path.lineTo(2,3); |
| 378 | path.lineTo(4,3); |
| 379 | path.close(); |
| 380 | } |
| 381 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 382 | static void testLine11(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 383 | SkPath path; |
| 384 | addCWContainer(path); |
| 385 | addCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 386 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 387 | } |
| 388 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 389 | static void testLine11x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 390 | SkPath path; |
| 391 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 392 | addCWContainer(path); |
| 393 | addCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 394 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 395 | } |
| 396 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 397 | static void testLine12(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 398 | SkPath path; |
| 399 | addCCWContainer(path); |
| 400 | addCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 401 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 402 | } |
| 403 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 404 | static void testLine12x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 405 | SkPath path; |
| 406 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 407 | addCCWContainer(path); |
| 408 | addCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 409 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 410 | } |
| 411 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 412 | static void testLine13(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 413 | SkPath path; |
| 414 | addCWContainer(path); |
| 415 | addCCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 416 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 417 | } |
| 418 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 419 | static void testLine13x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 420 | SkPath path; |
| 421 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 422 | addCWContainer(path); |
| 423 | addCCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 424 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 425 | } |
| 426 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 427 | static void testLine14(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 428 | SkPath path; |
| 429 | addCCWContainer(path); |
| 430 | addCCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 431 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 432 | } |
| 433 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 434 | static void testLine14x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 435 | SkPath path; |
| 436 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 437 | addCCWContainer(path); |
| 438 | addCCWContents(path); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 439 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 440 | } |
| 441 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 442 | static void testLine15(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 443 | SkPath path; |
| 444 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 445 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 446 | } |
| 447 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 448 | static void testLine15x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 449 | SkPath path; |
| 450 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 451 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 452 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 453 | } |
| 454 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 455 | static void testLine16(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 456 | SkPath path; |
| 457 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 458 | path.addRect(0, 4, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 459 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 460 | } |
| 461 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 462 | static void testLine16x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 463 | SkPath path; |
| 464 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 465 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 466 | path.addRect(0, 4, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 467 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 468 | } |
| 469 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 470 | static void testLine17(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 471 | SkPath path; |
| 472 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 473 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 474 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 475 | } |
| 476 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 477 | static void testLine17x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 478 | SkPath path; |
| 479 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 480 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 481 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 482 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 483 | } |
| 484 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 485 | static void testLine18(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 486 | SkPath path; |
| 487 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 488 | path.addRect(12, 4, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 489 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 490 | } |
| 491 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 492 | static void testLine18x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 493 | SkPath path; |
| 494 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 495 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 496 | path.addRect(12, 4, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 497 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 498 | } |
| 499 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 500 | static void testLine19(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 501 | SkPath path; |
| 502 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 503 | path.addRect(12, 16, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 504 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 505 | } |
| 506 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 507 | static void testLine19x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 508 | SkPath path; |
| 509 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 510 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 511 | path.addRect(12, 16, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 512 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 513 | } |
| 514 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 515 | static void testLine20(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 516 | SkPath path; |
| 517 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 518 | path.addRect(0, 12, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 519 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 520 | } |
| 521 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 522 | static void testLine20x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 523 | SkPath path; |
| 524 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 525 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 526 | path.addRect(0, 12, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 527 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 528 | } |
| 529 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 530 | static void testLine21(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 531 | SkPath path; |
| 532 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 533 | path.addRect(0, 16, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 534 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 535 | } |
| 536 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 537 | static void testLine21x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 538 | SkPath path; |
| 539 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 540 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 541 | path.addRect(0, 16, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 542 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 543 | } |
| 544 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 545 | static void testLine22(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 546 | SkPath path; |
| 547 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 548 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 549 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 550 | } |
| 551 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 552 | static void testLine22x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 553 | SkPath path; |
| 554 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 555 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 556 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 557 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 558 | } |
| 559 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 560 | static void testLine23(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 561 | SkPath path; |
| 562 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 563 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 564 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 565 | } |
| 566 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 567 | static void testLine23x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 568 | SkPath path; |
| 569 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 570 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 571 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 572 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 573 | } |
| 574 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 575 | static void testLine24a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 576 | SkPath path; |
| 577 | path.moveTo(2,0); |
| 578 | path.lineTo(4,4); |
| 579 | path.lineTo(0,4); |
| 580 | path.close(); |
| 581 | path.moveTo(2,0); |
| 582 | path.lineTo(1,2); |
| 583 | path.lineTo(2,2); |
| 584 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 585 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 586 | } |
| 587 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 588 | static void testLine24ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 589 | SkPath path; |
| 590 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 591 | path.moveTo(2,0); |
| 592 | path.lineTo(4,4); |
| 593 | path.lineTo(0,4); |
| 594 | path.close(); |
| 595 | path.moveTo(2,0); |
| 596 | path.lineTo(1,2); |
| 597 | path.lineTo(2,2); |
| 598 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 599 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 600 | } |
| 601 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 602 | static void testLine24(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 603 | SkPath path; |
| 604 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 605 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 606 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 607 | } |
| 608 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 609 | static void testLine24x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 610 | SkPath path; |
| 611 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 612 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 613 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 614 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 615 | } |
| 616 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 617 | static void testLine25(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 618 | SkPath path; |
| 619 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 620 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 621 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 622 | } |
| 623 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 624 | static void testLine25x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 625 | SkPath path; |
| 626 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 627 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 628 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 629 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 630 | } |
| 631 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 632 | static void testLine26(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 633 | SkPath path; |
| 634 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 635 | path.addRect(0, 12, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 636 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 637 | } |
| 638 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 639 | static void testLine26x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 640 | SkPath path; |
| 641 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 642 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 643 | path.addRect(0, 12, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 644 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 645 | } |
| 646 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 647 | static void testLine27(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 648 | SkPath path; |
| 649 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 650 | path.addRect(12, 8, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 651 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 652 | } |
| 653 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 654 | static void testLine27x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 655 | SkPath path; |
| 656 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 657 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 658 | path.addRect(12, 8, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 659 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 660 | } |
| 661 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 662 | static void testLine28(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 663 | SkPath path; |
| 664 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 665 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 666 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 667 | } |
| 668 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 669 | static void testLine28x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 670 | SkPath path; |
| 671 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 672 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 673 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 674 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 675 | } |
| 676 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 677 | static void testLine29(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 678 | SkPath path; |
| 679 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 680 | path.addRect(12, 12, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 681 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 682 | } |
| 683 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 684 | static void testLine29x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 685 | SkPath path; |
| 686 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 687 | path.addRect(0, 18, 12, 12, SkPath::kCW_Direction); |
| 688 | path.addRect(12, 12, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 689 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 690 | } |
| 691 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 692 | static void testLine30(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 693 | SkPath path; |
| 694 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 695 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 696 | path.addRect(4, 4, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 697 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 698 | } |
| 699 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 700 | static void testLine30x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 701 | SkPath path; |
| 702 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 703 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 704 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 705 | path.addRect(4, 4, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 706 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 707 | } |
| 708 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 709 | static void testLine31(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 710 | SkPath path; |
| 711 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 712 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 713 | path.addRect(0, 4, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 714 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 715 | } |
| 716 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 717 | static void testLine31x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 718 | SkPath path; |
| 719 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 720 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 721 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 722 | path.addRect(0, 4, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 723 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 724 | } |
| 725 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 726 | static void testLine32(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 727 | SkPath path; |
| 728 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 729 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 730 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 731 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 732 | } |
| 733 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 734 | static void testLine32x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 735 | SkPath path; |
| 736 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 737 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 738 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 739 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 740 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 741 | } |
| 742 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 743 | static void testLine33(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 744 | SkPath path; |
| 745 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 746 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 747 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 748 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 749 | } |
| 750 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 751 | static void testLine33x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 752 | SkPath path; |
| 753 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 754 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 755 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 756 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 757 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 758 | } |
| 759 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 760 | static void testLine34(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 761 | SkPath path; |
| 762 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 763 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 764 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 765 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 766 | } |
| 767 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 768 | static void testLine34x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 769 | SkPath path; |
| 770 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 771 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 772 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 773 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 774 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 775 | } |
| 776 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 777 | static void testLine35(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 778 | SkPath path; |
| 779 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 780 | path.addRect(6, 0, 18, 18, SkPath::kCW_Direction); |
| 781 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 782 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 783 | } |
| 784 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 785 | static void testLine35x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 786 | SkPath path; |
| 787 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 788 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 789 | path.addRect(6, 0, 18, 18, SkPath::kCW_Direction); |
| 790 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 791 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 792 | } |
| 793 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 794 | static void testLine36(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 795 | SkPath path; |
| 796 | path.addRect(0, 10, 20, 20, SkPath::kCW_Direction); |
| 797 | path.addRect(6, 12, 18, 18, SkPath::kCW_Direction); |
| 798 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 799 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 800 | } |
| 801 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 802 | static void testLine36x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 803 | SkPath path; |
| 804 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 805 | path.addRect(0, 10, 20, 20, SkPath::kCW_Direction); |
| 806 | path.addRect(6, 12, 18, 18, SkPath::kCW_Direction); |
| 807 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 808 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 809 | } |
| 810 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 811 | static void testLine37(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 812 | SkPath path; |
| 813 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 814 | path.addRect(18, 24, 30, 30, SkPath::kCW_Direction); |
| 815 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 816 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 817 | } |
| 818 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 819 | static void testLine37x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 820 | SkPath path; |
| 821 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 822 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 823 | path.addRect(18, 24, 30, 30, SkPath::kCW_Direction); |
| 824 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 825 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 826 | } |
| 827 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 828 | static void testLine38(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 829 | SkPath path; |
| 830 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 831 | path.addRect(6, 12, 18, 18, SkPath::kCW_Direction); |
| 832 | path.addRect(12, 12, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 833 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 834 | } |
| 835 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 836 | static void testLine38x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 837 | SkPath path; |
| 838 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 839 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 840 | path.addRect(6, 12, 18, 18, SkPath::kCW_Direction); |
| 841 | path.addRect(12, 12, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 842 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 843 | } |
| 844 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 845 | static void testLine40(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 846 | SkPath path; |
| 847 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 848 | path.addRect(12, 18, 24, 24, SkPath::kCW_Direction); |
| 849 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 850 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 851 | } |
| 852 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 853 | static void testLine40x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 854 | SkPath path; |
| 855 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 856 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 857 | path.addRect(12, 18, 24, 24, SkPath::kCW_Direction); |
| 858 | path.addRect(4, 16, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 859 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 860 | } |
| 861 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 862 | static void testLine41(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 863 | SkPath path; |
| 864 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 865 | path.addRect(18, 24, 30, 30, SkPath::kCW_Direction); |
| 866 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 867 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 868 | } |
| 869 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 870 | static void testLine41x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 871 | SkPath path; |
| 872 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 873 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 874 | path.addRect(18, 24, 30, 30, SkPath::kCW_Direction); |
| 875 | path.addRect(12, 0, 21, 21, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 876 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 877 | } |
| 878 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 879 | static void testLine42(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 880 | SkPath path; |
| 881 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 882 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 883 | path.addRect(8, 16, 17, 17, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 884 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 885 | } |
| 886 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 887 | static void testLine42x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 888 | SkPath path; |
| 889 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 890 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 891 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 892 | path.addRect(8, 16, 17, 17, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 893 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 894 | } |
| 895 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 896 | static void testLine43(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 897 | SkPath path; |
| 898 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 899 | path.addRect(6, 24, 18, 18, SkPath::kCW_Direction); |
| 900 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 901 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 902 | } |
| 903 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 904 | static void testLine43x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 905 | SkPath path; |
| 906 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 907 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 908 | path.addRect(6, 24, 18, 18, SkPath::kCW_Direction); |
| 909 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 910 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 911 | } |
| 912 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 913 | static void testLine44(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 914 | SkPath path; |
| 915 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 916 | path.addRect(18, 0, 30, 30, SkPath::kCW_Direction); |
| 917 | path.addRect(18, 32, 27, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 918 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 919 | } |
| 920 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 921 | static void testLine44x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 922 | SkPath path; |
| 923 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 924 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 925 | path.addRect(18, 0, 30, 30, SkPath::kCW_Direction); |
| 926 | path.addRect(18, 32, 27, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 927 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 928 | } |
| 929 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 930 | static void testLine45(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 931 | SkPath path; |
| 932 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 933 | path.addRect(18, 0, 30, 30, SkPath::kCW_Direction); |
| 934 | path.addRect(24, 32, 33, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 935 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 936 | } |
| 937 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 938 | static void testLine45x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 939 | SkPath path; |
| 940 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 941 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 942 | path.addRect(18, 0, 30, 30, SkPath::kCW_Direction); |
| 943 | path.addRect(24, 32, 33, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 944 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 945 | } |
| 946 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 947 | static void testLine46(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 948 | SkPath path; |
| 949 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 950 | path.addRect(24, 0, 36, 36, SkPath::kCW_Direction); |
| 951 | path.addRect(24, 32, 33, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 952 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 953 | } |
| 954 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 955 | static void testLine46x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 956 | SkPath path; |
| 957 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 958 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 959 | path.addRect(24, 0, 36, 36, SkPath::kCW_Direction); |
| 960 | path.addRect(24, 32, 33, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 961 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 962 | } |
| 963 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 964 | static void testLine47(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 965 | SkPath path; |
| 966 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 967 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 968 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 969 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 970 | } |
| 971 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 972 | static void testLine47x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 973 | SkPath path; |
| 974 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 975 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 976 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 977 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 978 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 979 | } |
| 980 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 981 | static void testLine48(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 982 | SkPath path; |
| 983 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 984 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 985 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 986 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 987 | } |
| 988 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 989 | static void testLine48x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 990 | SkPath path; |
| 991 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 992 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 993 | path.addRect(0, 6, 12, 12, SkPath::kCW_Direction); |
| 994 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 995 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 996 | } |
| 997 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 998 | static void testLine49(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 999 | SkPath path; |
| 1000 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1001 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 1002 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1003 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1004 | } |
| 1005 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1006 | static void testLine49x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1007 | SkPath path; |
| 1008 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1009 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1010 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 1011 | path.addRect(0, 0, 9, 9, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1012 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1013 | } |
| 1014 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1015 | static void testLine50(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1016 | SkPath path; |
| 1017 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 1018 | path.addRect(24, 20, 36, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1019 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1020 | } |
| 1021 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1022 | static void testLine50x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1023 | SkPath path; |
| 1024 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1025 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 1026 | path.addRect(24, 20, 36, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1027 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1028 | } |
| 1029 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1030 | static void testLine51(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1031 | SkPath path; |
| 1032 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1033 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 1034 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1035 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1036 | } |
| 1037 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1038 | static void testLine51x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1039 | SkPath path; |
| 1040 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1041 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1042 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 1043 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1044 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1045 | } |
| 1046 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1047 | static void testLine52(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1048 | SkPath path; |
| 1049 | path.addRect(0, 30, 20, 20, SkPath::kCW_Direction); |
| 1050 | path.addRect(6, 20, 18, 30, SkPath::kCW_Direction); |
| 1051 | path.addRect(32, 0, 36, 41, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1052 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1053 | } |
| 1054 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1055 | static void testLine52x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1056 | SkPath path; |
| 1057 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1058 | path.addRect(0, 30, 20, 20, SkPath::kCW_Direction); |
| 1059 | path.addRect(6, 20, 18, 30, SkPath::kCW_Direction); |
| 1060 | path.addRect(32, 0, 36, 41, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1061 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1062 | } |
| 1063 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1064 | static void testLine53(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1065 | SkPath path; |
| 1066 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 1067 | path.addRect(12, 20, 24, 30, SkPath::kCW_Direction); |
| 1068 | path.addRect(12, 32, 21, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1069 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1070 | } |
| 1071 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1072 | static void testLine53x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1073 | SkPath path; |
| 1074 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1075 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 1076 | path.addRect(12, 20, 24, 30, SkPath::kCW_Direction); |
| 1077 | path.addRect(12, 32, 21, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1078 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1079 | } |
| 1080 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1081 | static void testLine54(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1082 | SkPath path; |
| 1083 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1084 | path.addRect(6, 0, 18, 18, SkPath::kCW_Direction); |
| 1085 | path.addRect(8, 4, 17, 17, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1086 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1087 | } |
| 1088 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1089 | static void testLine54x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1090 | SkPath path; |
| 1091 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1092 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1093 | path.addRect(6, 0, 18, 18, SkPath::kCW_Direction); |
| 1094 | path.addRect(8, 4, 17, 17, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1095 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1096 | } |
| 1097 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1098 | static void testLine55(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1099 | SkPath path; |
| 1100 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1101 | path.addRect(6, 6, 18, 18, SkPath::kCW_Direction); |
| 1102 | path.addRect(4, 4, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1103 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1104 | } |
| 1105 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1106 | static void testLine55x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1107 | SkPath path; |
| 1108 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1109 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1110 | path.addRect(6, 6, 18, 18, SkPath::kCW_Direction); |
| 1111 | path.addRect(4, 4, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1112 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1113 | } |
| 1114 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1115 | static void testLine56(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1116 | SkPath path; |
| 1117 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 1118 | path.addRect(18, 20, 30, 30, SkPath::kCW_Direction); |
| 1119 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1120 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1121 | } |
| 1122 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1123 | static void testLine56x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1124 | SkPath path; |
| 1125 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1126 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 1127 | path.addRect(18, 20, 30, 30, SkPath::kCW_Direction); |
| 1128 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1129 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1130 | } |
| 1131 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1132 | static void testLine57(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1133 | SkPath path; |
| 1134 | path.addRect(20, 0, 40, 40, SkPath::kCW_Direction); |
| 1135 | path.addRect(20, 0, 30, 40, SkPath::kCW_Direction); |
| 1136 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1137 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1138 | } |
| 1139 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1140 | static void testLine57x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1141 | SkPath path; |
| 1142 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1143 | path.addRect(20, 0, 40, 40, SkPath::kCW_Direction); |
| 1144 | path.addRect(20, 0, 30, 40, SkPath::kCW_Direction); |
| 1145 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1146 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1147 | } |
| 1148 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1149 | static void testLine58(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1150 | SkPath path; |
| 1151 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1152 | path.addRect(0, 0, 12, 12, SkPath::kCCW_Direction); |
| 1153 | path.addRect(0, 12, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1154 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1155 | } |
| 1156 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1157 | static void testLine58x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1158 | SkPath path; |
| 1159 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1160 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1161 | path.addRect(0, 0, 12, 12, SkPath::kCCW_Direction); |
| 1162 | path.addRect(0, 12, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1163 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1164 | } |
| 1165 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1166 | static void testLine59(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1167 | SkPath path; |
| 1168 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1169 | path.addRect(6, 6, 18, 18, SkPath::kCCW_Direction); |
| 1170 | path.addRect(4, 4, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1171 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1172 | } |
| 1173 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1174 | static void testLine59x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1175 | SkPath path; |
| 1176 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1177 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1178 | path.addRect(6, 6, 18, 18, SkPath::kCCW_Direction); |
| 1179 | path.addRect(4, 4, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1180 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1181 | } |
| 1182 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1183 | static void testLine60(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1184 | SkPath path; |
| 1185 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1186 | path.addRect(6, 12, 18, 18, SkPath::kCCW_Direction); |
| 1187 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1188 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1189 | } |
| 1190 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1191 | static void testLine60x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1192 | SkPath path; |
| 1193 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1194 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1195 | path.addRect(6, 12, 18, 18, SkPath::kCCW_Direction); |
| 1196 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1197 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1198 | } |
| 1199 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1200 | static void testLine61(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1201 | SkPath path; |
| 1202 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1203 | path.addRect(12, 0, 24, 24, SkPath::kCCW_Direction); |
| 1204 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1205 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1206 | } |
| 1207 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1208 | static void testLine61x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1209 | SkPath path; |
| 1210 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1211 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1212 | path.addRect(12, 0, 24, 24, SkPath::kCCW_Direction); |
| 1213 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1214 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1215 | } |
| 1216 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1217 | static void testLine62(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1218 | SkPath path; |
| 1219 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1220 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1221 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 1222 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1223 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1224 | } |
| 1225 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1226 | static void testLine62x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1227 | SkPath path; |
| 1228 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1229 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1230 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1231 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 1232 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1233 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1234 | } |
| 1235 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1236 | static void testLine63(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1237 | SkPath path; |
| 1238 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1239 | path.addRect(0, 10, 20, 20, SkPath::kCW_Direction); |
| 1240 | path.addRect(0, 6, 12, 12, SkPath::kCCW_Direction); |
| 1241 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1242 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1243 | } |
| 1244 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1245 | static void testLine63x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1246 | SkPath path; |
| 1247 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1248 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1249 | path.addRect(0, 10, 20, 20, SkPath::kCW_Direction); |
| 1250 | path.addRect(0, 6, 12, 12, SkPath::kCCW_Direction); |
| 1251 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1252 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1253 | } |
| 1254 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1255 | static void testLine64(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1256 | SkPath path; |
| 1257 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1258 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1259 | path.addRect(18, 6, 30, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1260 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1261 | } |
| 1262 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1263 | static void testLine64x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1264 | SkPath path; |
| 1265 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1266 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1267 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1268 | path.addRect(18, 6, 30, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1269 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1270 | } |
| 1271 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1272 | static void testLine65(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1273 | SkPath path; |
| 1274 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1275 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 1276 | path.addRect(24, 0, 36, 36, SkPath::kCW_Direction); |
| 1277 | path.addRect(32, 6, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1278 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1279 | } |
| 1280 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1281 | static void testLine65x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1282 | SkPath path; |
| 1283 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1284 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1285 | path.addRect(10, 0, 30, 30, SkPath::kCW_Direction); |
| 1286 | path.addRect(24, 0, 36, 36, SkPath::kCW_Direction); |
| 1287 | path.addRect(32, 6, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1288 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1289 | } |
| 1290 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1291 | static void testLine66(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1292 | SkPath path; |
| 1293 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1294 | path.addRect(0, 30, 20, 20, SkPath::kCW_Direction); |
| 1295 | path.addRect(12, 20, 24, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1296 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1297 | } |
| 1298 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1299 | static void testLine66x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1300 | SkPath path; |
| 1301 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1302 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1303 | path.addRect(0, 30, 20, 20, SkPath::kCW_Direction); |
| 1304 | path.addRect(12, 20, 24, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1305 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1306 | } |
| 1307 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1308 | static void testLine67(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1309 | SkPath path; |
| 1310 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1311 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1312 | path.addRect(24, 20, 36, 30, SkPath::kCW_Direction); |
| 1313 | path.addRect(32, 0, 36, 41, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1314 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1315 | } |
| 1316 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1317 | static void testLine67x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1318 | SkPath path; |
| 1319 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1320 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1321 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1322 | path.addRect(24, 20, 36, 30, SkPath::kCW_Direction); |
| 1323 | path.addRect(32, 0, 36, 41, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1324 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1325 | } |
| 1326 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1327 | static void testLine68a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1328 | SkPath path; |
| 1329 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1330 | path.addRect(2, 2, 6, 6, SkPath::kCW_Direction); |
| 1331 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1332 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1333 | } |
| 1334 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1335 | static void testLine68ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1336 | SkPath path; |
| 1337 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1338 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1339 | path.addRect(2, 2, 6, 6, SkPath::kCW_Direction); |
| 1340 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1341 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1342 | } |
| 1343 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1344 | static void testLine68b(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1345 | SkPath path; |
| 1346 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1347 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1348 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1349 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1350 | } |
| 1351 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1352 | static void testLine68bx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1353 | SkPath path; |
| 1354 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1355 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1356 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1357 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1358 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1359 | } |
| 1360 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1361 | static void testLine68c(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1362 | SkPath path; |
| 1363 | path.addRect(0, 0, 8, 8, SkPath::kCCW_Direction); |
| 1364 | path.addRect(2, 2, 6, 6, SkPath::kCW_Direction); |
| 1365 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1366 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1367 | } |
| 1368 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1369 | static void testLine68cx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1370 | SkPath path; |
| 1371 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1372 | path.addRect(0, 0, 8, 8, SkPath::kCCW_Direction); |
| 1373 | path.addRect(2, 2, 6, 6, SkPath::kCW_Direction); |
| 1374 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1375 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1376 | } |
| 1377 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1378 | static void testLine68d(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1379 | SkPath path; |
| 1380 | path.addRect(0, 0, 8, 8, SkPath::kCCW_Direction); |
| 1381 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1382 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1383 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1384 | } |
| 1385 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1386 | static void testLine68dx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1387 | SkPath path; |
| 1388 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1389 | path.addRect(0, 0, 8, 8, SkPath::kCCW_Direction); |
| 1390 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1391 | path.addRect(1, 2, 4, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1392 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1393 | } |
| 1394 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1395 | static void testLine68e(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1396 | SkPath path; |
| 1397 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1398 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1399 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1400 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1401 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1402 | } |
| 1403 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1404 | static void testLine68ex(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1405 | SkPath path; |
| 1406 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1407 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1408 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1409 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1410 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1411 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1412 | } |
| 1413 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1414 | static void testLine68f(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1415 | SkPath path; |
| 1416 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1417 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1418 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1419 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1420 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1421 | } |
| 1422 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1423 | static void testLine68fx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1424 | SkPath path; |
| 1425 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1426 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1427 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1428 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1429 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1430 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1431 | } |
| 1432 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1433 | static void testLine68g(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1434 | SkPath path; |
| 1435 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1436 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1437 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1438 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1439 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1440 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1441 | } |
| 1442 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1443 | static void testLine68gx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1444 | SkPath path; |
| 1445 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1446 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1447 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1448 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1449 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1450 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1451 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1452 | } |
| 1453 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1454 | static void testLine68h(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1455 | SkPath path; |
| 1456 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1457 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1458 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1459 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1460 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1461 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1462 | } |
| 1463 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1464 | static void testLine68hx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1465 | SkPath path; |
| 1466 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1467 | path.addRect(0, 0, 8, 8, SkPath::kCW_Direction); |
| 1468 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1469 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1470 | path.addRect(2, 2, 6, 6, SkPath::kCCW_Direction); |
| 1471 | path.addRect(1, 2, 2, 2, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1472 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1473 | } |
| 1474 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1475 | static void testLine69(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1476 | SkPath path; |
| 1477 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 1478 | path.addRect(0, 20, 12, 30, SkPath::kCW_Direction); |
| 1479 | path.addRect(12, 32, 21, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1480 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1481 | } |
| 1482 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1483 | static void testLine69x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1484 | SkPath path; |
| 1485 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1486 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 1487 | path.addRect(0, 20, 12, 30, SkPath::kCW_Direction); |
| 1488 | path.addRect(12, 32, 21, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1489 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1490 | } |
| 1491 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1492 | static void testLine70(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1493 | SkPath path; |
| 1494 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1495 | path.addRect(0, 24, 12, 12, SkPath::kCW_Direction); |
| 1496 | path.addRect(12, 32, 21, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1497 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1498 | } |
| 1499 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1500 | static void testLine70x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1501 | SkPath path; |
| 1502 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1503 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1504 | path.addRect(0, 24, 12, 12, SkPath::kCW_Direction); |
| 1505 | path.addRect(12, 32, 21, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1506 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1507 | } |
| 1508 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1509 | static void testLine71(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1510 | SkPath path; |
| 1511 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1512 | path.addRect(12, 0, 24, 24, SkPath::kCW_Direction); |
| 1513 | path.addRect(12, 32, 21, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1514 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1515 | } |
| 1516 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1517 | static void testLine71x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1518 | SkPath path; |
| 1519 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1520 | path.addRect(0, 0, 20, 20, SkPath::kCW_Direction); |
| 1521 | path.addRect(12, 0, 24, 24, SkPath::kCW_Direction); |
| 1522 | path.addRect(12, 32, 21, 36, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1523 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1524 | } |
| 1525 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1526 | static void testLine72(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1527 | SkPath path; |
| 1528 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1529 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1530 | path.addRect(6, 20, 18, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1531 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1532 | } |
| 1533 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1534 | static void testLine72x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1535 | SkPath path; |
| 1536 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1537 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1538 | path.addRect(10, 40, 30, 30, SkPath::kCW_Direction); |
| 1539 | path.addRect(6, 20, 18, 30, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1540 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1541 | } |
| 1542 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1543 | static void testLine73(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1544 | SkPath path; |
| 1545 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1546 | path.addRect(0, 40, 20, 20, SkPath::kCW_Direction); |
| 1547 | path.addRect(0, 20, 12, 30, SkPath::kCW_Direction); |
| 1548 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1549 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1550 | } |
| 1551 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1552 | static void testLine73x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1553 | SkPath path; |
| 1554 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1555 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1556 | path.addRect(0, 40, 20, 20, SkPath::kCW_Direction); |
| 1557 | path.addRect(0, 20, 12, 30, SkPath::kCW_Direction); |
| 1558 | path.addRect(0, 0, 9, 9, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1559 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1560 | } |
| 1561 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1562 | static void testLine74(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1563 | SkPath path; |
| 1564 | path.addRect(20, 30, 40, 40, SkPath::kCW_Direction); |
| 1565 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 1566 | path.addRect(32, 24, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1567 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1568 | } |
| 1569 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1570 | static void testLine74x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1571 | SkPath path; |
| 1572 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1573 | path.addRect(20, 30, 40, 40, SkPath::kCW_Direction); |
| 1574 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 1575 | path.addRect(32, 24, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1576 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1577 | } |
| 1578 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1579 | static void testLine75(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1580 | SkPath path; |
| 1581 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1582 | path.addRect(10, 0, 30, 30, SkPath::kCCW_Direction); |
| 1583 | path.addRect(18, 0, 30, 30, SkPath::kCCW_Direction); |
| 1584 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1585 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1586 | } |
| 1587 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1588 | static void testLine75x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1589 | SkPath path; |
| 1590 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1591 | path.addRect(0, 0, 60, 60, SkPath::kCW_Direction); |
| 1592 | path.addRect(10, 0, 30, 30, SkPath::kCCW_Direction); |
| 1593 | path.addRect(18, 0, 30, 30, SkPath::kCCW_Direction); |
| 1594 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1595 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1596 | } |
| 1597 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1598 | static void testLine76(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1599 | SkPath path; |
| 1600 | path.addRect(36, 0, 66, 60, SkPath::kCW_Direction); |
| 1601 | path.addRect(10, 20, 40, 30, SkPath::kCW_Direction); |
| 1602 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 1603 | path.addRect(32, 6, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1604 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1605 | } |
| 1606 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1607 | static void testLine76x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1608 | SkPath path; |
| 1609 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1610 | path.addRect(36, 0, 66, 60, SkPath::kCW_Direction); |
| 1611 | path.addRect(10, 20, 40, 30, SkPath::kCW_Direction); |
| 1612 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 1613 | path.addRect(32, 6, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1614 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1615 | } |
| 1616 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1617 | static void testLine77(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1618 | SkPath path; |
| 1619 | path.addRect(20, 0, 40, 40, SkPath::kCW_Direction); |
| 1620 | path.addRect(24, 6, 36, 36, SkPath::kCCW_Direction); |
| 1621 | path.addRect(24, 32, 33, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1622 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1623 | } |
| 1624 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1625 | static void testLine77x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1626 | SkPath path; |
| 1627 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1628 | path.addRect(20, 0, 40, 40, SkPath::kCW_Direction); |
| 1629 | path.addRect(24, 6, 36, 36, SkPath::kCCW_Direction); |
| 1630 | path.addRect(24, 32, 33, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1631 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1632 | } |
| 1633 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1634 | static void testLine78(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1635 | SkPath path; |
| 1636 | path.addRect(0, 0, 30, 60, SkPath::kCW_Direction); |
| 1637 | path.addRect(10, 20, 30, 30, SkPath::kCCW_Direction); |
| 1638 | path.addRect(18, 20, 30, 30, SkPath::kCCW_Direction); |
| 1639 | path.addRect(32, 0, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1640 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1641 | } |
| 1642 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1643 | static void testLine78x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1644 | SkPath path; |
| 1645 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1646 | path.addRect(0, 0, 30, 60, SkPath::kCW_Direction); |
| 1647 | path.addRect(10, 20, 30, 30, SkPath::kCCW_Direction); |
| 1648 | path.addRect(18, 20, 30, 30, SkPath::kCCW_Direction); |
| 1649 | path.addRect(32, 0, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1650 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1651 | } |
| 1652 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1653 | static void testLine79(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1654 | SkPath path; |
| 1655 | path.addRect(0, 36, 60, 30, SkPath::kCW_Direction); |
| 1656 | path.addRect(10, 30, 40, 30, SkPath::kCW_Direction); |
| 1657 | path.addRect(0, 20, 12, 30, SkPath::kCCW_Direction); |
| 1658 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1659 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1660 | } |
| 1661 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1662 | static void testLine79x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1663 | SkPath path; |
| 1664 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1665 | path.addRect(0, 36, 60, 30, SkPath::kCW_Direction); |
| 1666 | path.addRect(10, 30, 40, 30, SkPath::kCW_Direction); |
| 1667 | path.addRect(0, 20, 12, 30, SkPath::kCCW_Direction); |
| 1668 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1669 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1670 | } |
| 1671 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1672 | static void testLine81(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1673 | SkPath path; |
| 1674 | path.addRect(-1, -1, 3, 3, SkPath::kCW_Direction); |
| 1675 | path.addRect(0, 0, 1, 1, SkPath::kCW_Direction); |
| 1676 | path.addRect(0, 0, 1, 1, SkPath::kCW_Direction); |
| 1677 | path.addRect(0, 0, 1, 1, SkPath::kCW_Direction); |
| 1678 | path.addRect(1, 1, 2, 2, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1679 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1680 | } |
| 1681 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1682 | static void testDegenerate1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1683 | SkPath path; |
| 1684 | path.moveTo(0, 0); |
| 1685 | path.lineTo(0, 0); |
| 1686 | path.lineTo(2, 0); |
| 1687 | path.close(); |
| 1688 | path.moveTo(0, 0); |
| 1689 | path.lineTo(1, 0); |
| 1690 | path.lineTo(2, 0); |
| 1691 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1692 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1693 | } |
| 1694 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1695 | static void testDegenerate1x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1696 | SkPath path; |
| 1697 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1698 | path.moveTo(0, 0); |
| 1699 | path.lineTo(0, 0); |
| 1700 | path.lineTo(2, 0); |
| 1701 | path.close(); |
| 1702 | path.moveTo(0, 0); |
| 1703 | path.lineTo(1, 0); |
| 1704 | path.lineTo(2, 0); |
| 1705 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1706 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1707 | } |
| 1708 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1709 | static void testDegenerate2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1710 | SkPath path; |
| 1711 | path.moveTo(0, 0); |
| 1712 | path.lineTo(0, 0); |
| 1713 | path.lineTo(0, 0); |
| 1714 | path.close(); |
| 1715 | path.moveTo(0, 0); |
| 1716 | path.lineTo(1, 0); |
| 1717 | path.lineTo(0, 1); |
| 1718 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1719 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1720 | } |
| 1721 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1722 | static void testDegenerate2x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1723 | SkPath path; |
| 1724 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1725 | path.moveTo(0, 0); |
| 1726 | path.lineTo(0, 0); |
| 1727 | path.lineTo(0, 0); |
| 1728 | path.close(); |
| 1729 | path.moveTo(0, 0); |
| 1730 | path.lineTo(1, 0); |
| 1731 | path.lineTo(0, 1); |
| 1732 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1733 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1734 | } |
| 1735 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1736 | static void testDegenerate3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1737 | SkPath path; |
| 1738 | path.moveTo(0, 0); |
| 1739 | path.lineTo(2, 0); |
| 1740 | path.lineTo(1, 0); |
| 1741 | path.close(); |
| 1742 | path.moveTo(0, 0); |
| 1743 | path.lineTo(0, 0); |
| 1744 | path.lineTo(3, 0); |
| 1745 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1746 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1747 | } |
| 1748 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1749 | static void testDegenerate3x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1750 | SkPath path; |
| 1751 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1752 | path.moveTo(0, 0); |
| 1753 | path.lineTo(2, 0); |
| 1754 | path.lineTo(1, 0); |
| 1755 | path.close(); |
| 1756 | path.moveTo(0, 0); |
| 1757 | path.lineTo(0, 0); |
| 1758 | path.lineTo(3, 0); |
| 1759 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1760 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1761 | } |
| 1762 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1763 | static void testDegenerate4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1764 | SkPath path; |
| 1765 | path.moveTo(0, 0); |
| 1766 | path.lineTo(1, 0); |
| 1767 | path.lineTo(1, 3); |
| 1768 | path.close(); |
| 1769 | path.moveTo(1, 0); |
| 1770 | path.lineTo(1, 1); |
| 1771 | path.lineTo(1, 2); |
| 1772 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1773 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1774 | } |
| 1775 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1776 | static void testDegenerate4x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1777 | SkPath path; |
| 1778 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1779 | path.moveTo(0, 0); |
| 1780 | path.lineTo(1, 0); |
| 1781 | path.lineTo(1, 3); |
| 1782 | path.close(); |
| 1783 | path.moveTo(1, 0); |
| 1784 | path.lineTo(1, 1); |
| 1785 | path.lineTo(1, 2); |
| 1786 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1787 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1788 | } |
| 1789 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1790 | static void testNondegenerate1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1791 | SkPath path; |
| 1792 | path.moveTo(0, 0); |
| 1793 | path.lineTo(3, 0); |
| 1794 | path.lineTo(1, 3); |
| 1795 | path.close(); |
| 1796 | path.moveTo(1, 1); |
| 1797 | path.lineTo(2, 1); |
| 1798 | path.lineTo(1, 2); |
| 1799 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1800 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1801 | } |
| 1802 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1803 | static void testNondegenerate1x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1804 | SkPath path; |
| 1805 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1806 | path.moveTo(0, 0); |
| 1807 | path.lineTo(3, 0); |
| 1808 | path.lineTo(1, 3); |
| 1809 | path.close(); |
| 1810 | path.moveTo(1, 1); |
| 1811 | path.lineTo(2, 1); |
| 1812 | path.lineTo(1, 2); |
| 1813 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1814 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1815 | } |
| 1816 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1817 | static void testNondegenerate2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1818 | SkPath path; |
| 1819 | path.moveTo(1, 0); |
| 1820 | path.lineTo(0, 1); |
| 1821 | path.lineTo(1, 1); |
| 1822 | path.close(); |
| 1823 | path.moveTo(0, 2); |
| 1824 | path.lineTo(0, 3); |
| 1825 | path.lineTo(1, 2); |
| 1826 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1827 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1828 | } |
| 1829 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1830 | static void testNondegenerate2x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1831 | SkPath path; |
| 1832 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1833 | path.moveTo(1, 0); |
| 1834 | path.lineTo(0, 1); |
| 1835 | path.lineTo(1, 1); |
| 1836 | path.close(); |
| 1837 | path.moveTo(0, 2); |
| 1838 | path.lineTo(0, 3); |
| 1839 | path.lineTo(1, 2); |
| 1840 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1841 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1842 | } |
| 1843 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1844 | static void testNondegenerate3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1845 | SkPath path; |
| 1846 | path.moveTo(0, 0); |
| 1847 | path.lineTo(1, 0); |
| 1848 | path.lineTo(2, 1); |
| 1849 | path.close(); |
| 1850 | path.moveTo(0, 1); |
| 1851 | path.lineTo(1, 1); |
| 1852 | path.lineTo(0, 2); |
| 1853 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1854 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1855 | } |
| 1856 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1857 | static void testNondegenerate3x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1858 | SkPath path; |
| 1859 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1860 | path.moveTo(0, 0); |
| 1861 | path.lineTo(1, 0); |
| 1862 | path.lineTo(2, 1); |
| 1863 | path.close(); |
| 1864 | path.moveTo(0, 1); |
| 1865 | path.lineTo(1, 1); |
| 1866 | path.lineTo(0, 2); |
| 1867 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1868 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1869 | } |
| 1870 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1871 | static void testNondegenerate4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1872 | SkPath path; |
| 1873 | path.moveTo(1, 0); |
| 1874 | path.lineTo(0, 1); |
| 1875 | path.lineTo(1, 2); |
| 1876 | path.close(); |
| 1877 | path.moveTo(0, 2); |
| 1878 | path.lineTo(0, 3); |
| 1879 | path.lineTo(1, 3); |
| 1880 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1881 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1882 | } |
| 1883 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1884 | static void testNondegenerate4x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1885 | SkPath path; |
| 1886 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1887 | path.moveTo(1, 0); |
| 1888 | path.lineTo(0, 1); |
| 1889 | path.lineTo(1, 2); |
| 1890 | path.close(); |
| 1891 | path.moveTo(0, 2); |
| 1892 | path.lineTo(0, 3); |
| 1893 | path.lineTo(1, 3); |
| 1894 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1895 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1896 | } |
| 1897 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1898 | static void testQuadralateral5(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1899 | SkPath path; |
| 1900 | path.moveTo(0, 0); |
| 1901 | path.lineTo(0, 0); |
| 1902 | path.lineTo(1, 0); |
| 1903 | path.lineTo(1, 1); |
| 1904 | path.close(); |
| 1905 | path.moveTo(0, 0); |
| 1906 | path.lineTo(2, 2); |
| 1907 | path.lineTo(3, 2); |
| 1908 | path.lineTo(3, 3); |
| 1909 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1910 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1911 | } |
| 1912 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1913 | static void testQuadralateral5x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1914 | SkPath path; |
| 1915 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1916 | path.moveTo(0, 0); |
| 1917 | path.lineTo(0, 0); |
| 1918 | path.lineTo(1, 0); |
| 1919 | path.lineTo(1, 1); |
| 1920 | path.close(); |
| 1921 | path.moveTo(0, 0); |
| 1922 | path.lineTo(2, 2); |
| 1923 | path.lineTo(3, 2); |
| 1924 | path.lineTo(3, 3); |
| 1925 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1926 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1927 | } |
| 1928 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1929 | static void testQuadralateral6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1930 | SkPath path; |
| 1931 | path.moveTo(0, 0); |
| 1932 | path.lineTo(0, 0); |
| 1933 | path.lineTo(1, 0); |
| 1934 | path.lineTo(1, 1); |
| 1935 | path.close(); |
| 1936 | path.moveTo(1, 0); |
| 1937 | path.lineTo(2, 0); |
| 1938 | path.lineTo(0, 2); |
| 1939 | path.lineTo(2, 2); |
| 1940 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1941 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1942 | } |
| 1943 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1944 | static void testQuadralateral6x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1945 | SkPath path; |
| 1946 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1947 | path.moveTo(0, 0); |
| 1948 | path.lineTo(0, 0); |
| 1949 | path.lineTo(1, 0); |
| 1950 | path.lineTo(1, 1); |
| 1951 | path.close(); |
| 1952 | path.moveTo(1, 0); |
| 1953 | path.lineTo(2, 0); |
| 1954 | path.lineTo(0, 2); |
| 1955 | path.lineTo(2, 2); |
| 1956 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1957 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1958 | } |
| 1959 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1960 | static void testFauxQuadralateral6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1961 | SkPath path; |
| 1962 | path.moveTo(0, 0); |
| 1963 | path.lineTo(1, 0); |
| 1964 | path.lineTo(1, 1); |
| 1965 | path.close(); |
| 1966 | path.moveTo(1, 0); |
| 1967 | path.lineTo(2, 0); |
| 1968 | path.lineTo(1 + 1.0f/3, 2.0f/3); |
| 1969 | path.close(); |
| 1970 | path.moveTo(1 + 1.0f/3, 2.0f/3); |
| 1971 | path.lineTo(0, 2); |
| 1972 | path.lineTo(2, 2); |
| 1973 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1974 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1975 | } |
| 1976 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1977 | static void testFauxQuadralateral6x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1978 | SkPath path; |
| 1979 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1980 | path.moveTo(0, 0); |
| 1981 | path.lineTo(1, 0); |
| 1982 | path.lineTo(1, 1); |
| 1983 | path.close(); |
| 1984 | path.moveTo(1, 0); |
| 1985 | path.lineTo(2, 0); |
| 1986 | path.lineTo(1 + 1.0f/3, 2.0f/3); |
| 1987 | path.close(); |
| 1988 | path.moveTo(1 + 1.0f/3, 2.0f/3); |
| 1989 | path.lineTo(0, 2); |
| 1990 | path.lineTo(2, 2); |
| 1991 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1992 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1993 | } |
| 1994 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 1995 | static void testFauxQuadralateral6a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 1996 | SkPath path; |
| 1997 | path.moveTo(0, 0); |
| 1998 | path.lineTo(3, 0); |
| 1999 | path.lineTo(3, 3); |
| 2000 | path.close(); |
| 2001 | path.moveTo(3, 0); |
| 2002 | path.lineTo(6, 0); |
| 2003 | path.lineTo(4, 2); |
| 2004 | path.close(); |
| 2005 | path.moveTo(4, 2); |
| 2006 | path.lineTo(0, 6); |
| 2007 | path.lineTo(6, 6); |
| 2008 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2009 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2010 | } |
| 2011 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2012 | static void testFauxQuadralateral6ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2013 | SkPath path; |
| 2014 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2015 | path.moveTo(0, 0); |
| 2016 | path.lineTo(3, 0); |
| 2017 | path.lineTo(3, 3); |
| 2018 | path.close(); |
| 2019 | path.moveTo(3, 0); |
| 2020 | path.lineTo(6, 0); |
| 2021 | path.lineTo(4, 2); |
| 2022 | path.close(); |
| 2023 | path.moveTo(4, 2); |
| 2024 | path.lineTo(0, 6); |
| 2025 | path.lineTo(6, 6); |
| 2026 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2027 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2028 | } |
| 2029 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2030 | static void testFauxQuadralateral6b(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2031 | SkPath path; |
| 2032 | path.moveTo(0, 0); |
| 2033 | path.lineTo(3, 0); |
| 2034 | path.lineTo(3, 3); |
| 2035 | path.close(); |
| 2036 | path.moveTo(3, 0); |
| 2037 | path.lineTo(6, 0); |
| 2038 | path.lineTo(4, 2); |
| 2039 | path.close(); |
| 2040 | path.moveTo(4, 2); |
| 2041 | path.lineTo(6, 6); |
| 2042 | path.lineTo(0, 6); |
| 2043 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2044 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2045 | } |
| 2046 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2047 | static void testFauxQuadralateral6bx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2048 | SkPath path; |
| 2049 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2050 | path.moveTo(0, 0); |
| 2051 | path.lineTo(3, 0); |
| 2052 | path.lineTo(3, 3); |
| 2053 | path.close(); |
| 2054 | path.moveTo(3, 0); |
| 2055 | path.lineTo(6, 0); |
| 2056 | path.lineTo(4, 2); |
| 2057 | path.close(); |
| 2058 | path.moveTo(4, 2); |
| 2059 | path.lineTo(6, 6); |
| 2060 | path.lineTo(0, 6); |
| 2061 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2062 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2063 | } |
| 2064 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2065 | static void testFauxQuadralateral6c(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2066 | SkPath path; |
| 2067 | path.moveTo(0, 0); |
| 2068 | path.lineTo(3, 3); |
| 2069 | path.lineTo(3, 0); |
| 2070 | path.close(); |
| 2071 | path.moveTo(3, 0); |
| 2072 | path.lineTo(6, 0); |
| 2073 | path.lineTo(4, 2); |
| 2074 | path.close(); |
| 2075 | path.moveTo(4, 2); |
| 2076 | path.lineTo(0, 6); |
| 2077 | path.lineTo(6, 6); |
| 2078 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2079 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2080 | } |
| 2081 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2082 | static void testFauxQuadralateral6cx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2083 | SkPath path; |
| 2084 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2085 | path.moveTo(0, 0); |
| 2086 | path.lineTo(3, 3); |
| 2087 | path.lineTo(3, 0); |
| 2088 | path.close(); |
| 2089 | path.moveTo(3, 0); |
| 2090 | path.lineTo(6, 0); |
| 2091 | path.lineTo(4, 2); |
| 2092 | path.close(); |
| 2093 | path.moveTo(4, 2); |
| 2094 | path.lineTo(0, 6); |
| 2095 | path.lineTo(6, 6); |
| 2096 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2097 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2098 | } |
| 2099 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2100 | static void testFauxQuadralateral6d(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2101 | SkPath path; |
| 2102 | path.moveTo(0, 0); |
| 2103 | path.lineTo(3, 3); |
| 2104 | path.lineTo(3, 0); |
| 2105 | path.close(); |
| 2106 | path.moveTo(3, 0); |
| 2107 | path.lineTo(6, 0); |
| 2108 | path.lineTo(4, 2); |
| 2109 | path.close(); |
| 2110 | path.moveTo(4, 2); |
| 2111 | path.lineTo(6, 6); |
| 2112 | path.lineTo(0, 6); |
| 2113 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2114 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2115 | } |
| 2116 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2117 | static void testFauxQuadralateral6dx(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2118 | SkPath path; |
| 2119 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2120 | path.moveTo(0, 0); |
| 2121 | path.lineTo(3, 3); |
| 2122 | path.lineTo(3, 0); |
| 2123 | path.close(); |
| 2124 | path.moveTo(3, 0); |
| 2125 | path.lineTo(6, 0); |
| 2126 | path.lineTo(4, 2); |
| 2127 | path.close(); |
| 2128 | path.moveTo(4, 2); |
| 2129 | path.lineTo(6, 6); |
| 2130 | path.lineTo(0, 6); |
| 2131 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2132 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2133 | } |
| 2134 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2135 | static void testQuadralateral6a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2136 | SkPath path; |
| 2137 | path.moveTo(0, 0); |
| 2138 | path.lineTo(0, 0); |
| 2139 | path.lineTo(3, 0); |
| 2140 | path.lineTo(3, 3); |
| 2141 | path.close(); |
| 2142 | path.moveTo(3, 0); |
| 2143 | path.lineTo(6, 0); |
| 2144 | path.lineTo(0, 6); |
| 2145 | path.lineTo(6, 6); |
| 2146 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2147 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2148 | } |
| 2149 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2150 | static void testQuadralateral6ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2151 | SkPath path; |
| 2152 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2153 | path.moveTo(0, 0); |
| 2154 | path.lineTo(0, 0); |
| 2155 | path.lineTo(3, 0); |
| 2156 | path.lineTo(3, 3); |
| 2157 | path.close(); |
| 2158 | path.moveTo(3, 0); |
| 2159 | path.lineTo(6, 0); |
| 2160 | path.lineTo(0, 6); |
| 2161 | path.lineTo(6, 6); |
| 2162 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2163 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2164 | } |
| 2165 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2166 | static void testQuadralateral7(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2167 | SkPath path; |
| 2168 | path.moveTo(0, 0); |
| 2169 | path.lineTo(0, 0); |
| 2170 | path.lineTo(1, 0); |
| 2171 | path.lineTo(2, 1); |
| 2172 | path.close(); |
| 2173 | path.moveTo(1, 0); |
| 2174 | path.lineTo(1, 1); |
| 2175 | path.lineTo(2, 2); |
| 2176 | path.lineTo(1, 3); |
| 2177 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2178 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2179 | } |
| 2180 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2181 | static void testQuadralateral7x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2182 | SkPath path; |
| 2183 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2184 | path.moveTo(0, 0); |
| 2185 | path.lineTo(0, 0); |
| 2186 | path.lineTo(1, 0); |
| 2187 | path.lineTo(2, 1); |
| 2188 | path.close(); |
| 2189 | path.moveTo(1, 0); |
| 2190 | path.lineTo(1, 1); |
| 2191 | path.lineTo(2, 2); |
| 2192 | path.lineTo(1, 3); |
| 2193 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2194 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2195 | } |
| 2196 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2197 | static void testQuadralateral8(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2198 | SkPath path; |
| 2199 | path.moveTo(0, 0); |
| 2200 | path.lineTo(3, 1); |
| 2201 | path.lineTo(1, 3); |
| 2202 | path.lineTo(3, 3); |
| 2203 | path.close(); |
| 2204 | path.moveTo(2, 1); |
| 2205 | path.lineTo(0, 2); |
| 2206 | path.lineTo(3, 2); |
| 2207 | path.lineTo(2, 3); |
| 2208 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2209 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2210 | } |
| 2211 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2212 | static void testQuadralateral8x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2213 | SkPath path; |
| 2214 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2215 | path.moveTo(0, 0); |
| 2216 | path.lineTo(3, 1); |
| 2217 | path.lineTo(1, 3); |
| 2218 | path.lineTo(3, 3); |
| 2219 | path.close(); |
| 2220 | path.moveTo(2, 1); |
| 2221 | path.lineTo(0, 2); |
| 2222 | path.lineTo(3, 2); |
| 2223 | path.lineTo(2, 3); |
| 2224 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2225 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2226 | } |
| 2227 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2228 | static void testQuadralateral9(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2229 | SkPath path; |
| 2230 | path.moveTo(0, 0); |
| 2231 | path.lineTo(1, 0); |
| 2232 | path.lineTo(1, 2); |
| 2233 | path.lineTo(2, 2); |
| 2234 | path.close(); |
| 2235 | path.moveTo(1, 1); |
| 2236 | path.lineTo(2, 1); |
| 2237 | path.lineTo(1, 3); |
| 2238 | path.lineTo(2, 3); |
| 2239 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2240 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2241 | } |
| 2242 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2243 | static void testQuadralateral9x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2244 | SkPath path; |
| 2245 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2246 | path.moveTo(0, 0); |
| 2247 | path.lineTo(1, 0); |
| 2248 | path.lineTo(1, 2); |
| 2249 | path.lineTo(2, 2); |
| 2250 | path.close(); |
| 2251 | path.moveTo(1, 1); |
| 2252 | path.lineTo(2, 1); |
| 2253 | path.lineTo(1, 3); |
| 2254 | path.lineTo(2, 3); |
| 2255 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2256 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2257 | } |
| 2258 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2259 | static void testLine1a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2260 | SkPath path; |
| 2261 | path.setFillType(SkPath::kWinding_FillType); |
| 2262 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 2263 | path.addRect(4, 0, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2264 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2265 | } |
| 2266 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2267 | static void testLine1ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2268 | SkPath path; |
| 2269 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2270 | path.addRect(0, 0, 12, 12, SkPath::kCW_Direction); |
| 2271 | path.addRect(4, 0, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2272 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2273 | } |
| 2274 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2275 | static void testLine2ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2276 | SkPath path; |
| 2277 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2278 | path.addRect(0, 20, 20, 20, SkPath::kCW_Direction); |
| 2279 | path.addRect(0, 20, 12, 30, SkPath::kCW_Direction); |
| 2280 | path.addRect(12, 0, 21, 21, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2281 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2282 | } |
| 2283 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2284 | static void testLine3aax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2285 | SkPath path; |
| 2286 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2287 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 2288 | path.addRect(18, 20, 30, 30, SkPath::kCCW_Direction); |
| 2289 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2290 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2291 | } |
| 2292 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2293 | static void testLine4ax(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2294 | SkPath path; |
| 2295 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2296 | path.addRect(10, 30, 30, 30, SkPath::kCW_Direction); |
| 2297 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 2298 | path.addRect(0, 32, 9, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2299 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2300 | } |
| 2301 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2302 | static void testQuadratic1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2303 | SkPath path; |
| 2304 | path.moveTo(0, 0); |
| 2305 | path.quadTo(0, 0, 0, 0); |
| 2306 | path.lineTo(1, 0); |
| 2307 | path.close(); |
| 2308 | path.moveTo(0, 0); |
| 2309 | path.lineTo(0, 0); |
| 2310 | path.quadTo(0, 0, 0, 0); |
| 2311 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2312 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2313 | } |
| 2314 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2315 | static void testQuadratic1x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2316 | SkPath path; |
| 2317 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2318 | path.moveTo(0, 0); |
| 2319 | path.quadTo(0, 0, 0, 0); |
| 2320 | path.lineTo(1, 0); |
| 2321 | path.close(); |
| 2322 | path.moveTo(0, 0); |
| 2323 | path.lineTo(0, 0); |
| 2324 | path.quadTo(0, 0, 0, 0); |
| 2325 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2326 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2327 | } |
| 2328 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2329 | static void testQuadratic2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2330 | SkPath path; |
| 2331 | path.moveTo(0, 0); |
| 2332 | path.quadTo(0, 0, 0, 0); |
| 2333 | path.lineTo(3, 0); |
| 2334 | path.close(); |
| 2335 | path.moveTo(0, 0); |
| 2336 | path.lineTo(0, 0); |
| 2337 | path.quadTo(1, 0, 0, 1); |
| 2338 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2339 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2340 | } |
| 2341 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2342 | static void testQuadratic2x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2343 | SkPath path; |
| 2344 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2345 | path.moveTo(0, 0); |
| 2346 | path.quadTo(0, 0, 0, 0); |
| 2347 | path.lineTo(3, 0); |
| 2348 | path.close(); |
| 2349 | path.moveTo(0, 0); |
| 2350 | path.lineTo(0, 0); |
| 2351 | path.quadTo(1, 0, 0, 1); |
| 2352 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2353 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2354 | } |
| 2355 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2356 | static void testQuadratic3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2357 | SkPath path; |
| 2358 | path.moveTo(0, 0); |
| 2359 | path.quadTo(0, 0, 1, 0); |
| 2360 | path.lineTo(0, 2); |
| 2361 | path.close(); |
| 2362 | path.moveTo(0, 0); |
| 2363 | path.lineTo(0, 0); |
| 2364 | path.quadTo(1, 0, 0, 1); |
| 2365 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2366 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2367 | } |
| 2368 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2369 | static void testQuadratic3x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2370 | SkPath path; |
| 2371 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2372 | path.moveTo(0, 0); |
| 2373 | path.quadTo(0, 0, 1, 0); |
| 2374 | path.lineTo(0, 2); |
| 2375 | path.close(); |
| 2376 | path.moveTo(0, 0); |
| 2377 | path.lineTo(0, 0); |
| 2378 | path.quadTo(1, 0, 0, 1); |
| 2379 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2380 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2381 | } |
| 2382 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2383 | static void testQuadratic4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2384 | SkPath path; |
| 2385 | path.moveTo(0, 0); |
| 2386 | path.quadTo(0, 0, 1, 0); |
| 2387 | path.lineTo(0, 2); |
| 2388 | path.close(); |
| 2389 | path.moveTo(0, 0); |
| 2390 | path.lineTo(0, 0); |
| 2391 | path.quadTo(1, 0, 0, 2); |
| 2392 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2393 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2394 | } |
| 2395 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2396 | static void testQuadratic4x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2397 | SkPath path; |
| 2398 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2399 | path.moveTo(0, 0); |
| 2400 | path.quadTo(0, 0, 1, 0); |
| 2401 | path.lineTo(0, 2); |
| 2402 | path.close(); |
| 2403 | path.moveTo(0, 0); |
| 2404 | path.lineTo(0, 0); |
| 2405 | path.quadTo(1, 0, 0, 2); |
| 2406 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2407 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2408 | } |
| 2409 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2410 | static void testQuadratic5(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2411 | SkPath path; |
| 2412 | path.moveTo(0, 0); |
| 2413 | path.quadTo(0, 0, 0, 0); |
| 2414 | path.lineTo(0, 1); |
| 2415 | path.close(); |
| 2416 | path.moveTo(0, 0); |
| 2417 | path.lineTo(1, 0); |
| 2418 | path.quadTo(0, 1, 0, 2); |
| 2419 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2420 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2421 | } |
| 2422 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2423 | static void testQuadratic6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2424 | SkPath path; |
| 2425 | path.moveTo(0, 0); |
| 2426 | path.quadTo(0, 0, 1, 0); |
| 2427 | path.lineTo(2, 1); |
| 2428 | path.close(); |
| 2429 | path.moveTo(0, 0); |
| 2430 | path.lineTo(0, 0); |
| 2431 | path.quadTo(2, 0, 0, 1); |
| 2432 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2433 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2434 | } |
| 2435 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2436 | static void testQuadratic7(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2437 | SkPath path; |
| 2438 | path.moveTo(0, 0); |
| 2439 | path.quadTo(0, 0, 1, 0); |
| 2440 | path.lineTo(3, 1); |
| 2441 | path.close(); |
| 2442 | path.moveTo(0, 0); |
| 2443 | path.lineTo(0, 0); |
| 2444 | path.quadTo(3, 0, 1, 2); |
| 2445 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2446 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2447 | } |
| 2448 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2449 | static void testQuadratic8(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2450 | SkPath path; |
| 2451 | path.moveTo(0, 0); |
| 2452 | path.quadTo(0, 0, 1, 0); |
| 2453 | path.lineTo(0, 2); |
| 2454 | path.close(); |
| 2455 | path.moveTo(0, 0); |
| 2456 | path.lineTo(1, 0); |
| 2457 | path.quadTo(0, 1, 1, 2); |
| 2458 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2459 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2460 | } |
| 2461 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2462 | static void testQuadratic9(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2463 | SkPath path; |
| 2464 | path.moveTo(0, 0); |
| 2465 | path.quadTo(0, 0, 1, 0); |
| 2466 | path.lineTo(3, 1); |
| 2467 | path.close(); |
| 2468 | path.moveTo(0, 0); |
| 2469 | path.lineTo(1, 0); |
| 2470 | path.quadTo(1, 2, 3, 2); |
| 2471 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2472 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2473 | } |
| 2474 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2475 | static void testQuadratic14(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2476 | SkPath path; |
| 2477 | path.moveTo(0, 0); |
| 2478 | path.quadTo(0, 0, 1, 0); |
| 2479 | path.lineTo(3, 2); |
| 2480 | path.close(); |
| 2481 | path.moveTo(0, 0); |
| 2482 | path.lineTo(1, 0); |
| 2483 | path.quadTo(3, 2, 3, 3); |
| 2484 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2485 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2486 | } |
| 2487 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2488 | static void testQuadratic15(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2489 | SkPath path; |
| 2490 | path.moveTo(0, 0); |
| 2491 | path.quadTo(0, 0, 1, 0); |
| 2492 | path.lineTo(1, 3); |
| 2493 | path.close(); |
| 2494 | path.moveTo(1, 0); |
| 2495 | path.lineTo(0, 1); |
| 2496 | path.quadTo(1, 1, 0, 3); |
| 2497 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2498 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2499 | } |
| 2500 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2501 | static void testQuadratic17x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2502 | SkPath path; |
| 2503 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2504 | path.moveTo(0, 0); |
| 2505 | path.quadTo(0, 0, 3, 1); |
| 2506 | path.lineTo(0, 2); |
| 2507 | path.close(); |
| 2508 | path.moveTo(0, 0); |
| 2509 | path.lineTo(1, 0); |
| 2510 | path.quadTo(3, 1, 0, 2); |
| 2511 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2512 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2513 | } |
| 2514 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2515 | static void testQuadratic18(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2516 | SkPath path; |
| 2517 | path.moveTo(0, 0); |
| 2518 | path.quadTo(1, 0, 0, 1); |
| 2519 | path.lineTo(0, 1); |
| 2520 | path.close(); |
| 2521 | path.moveTo(0, 0); |
| 2522 | path.lineTo(0, 0); |
| 2523 | path.quadTo(1, 0, 1, 1); |
| 2524 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2525 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2526 | } |
| 2527 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2528 | static void testQuadratic19(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2529 | SkPath path; |
| 2530 | path.moveTo(0, 0); |
| 2531 | path.quadTo(1, 0, 0, 1); |
| 2532 | path.lineTo(0, 1); |
| 2533 | path.close(); |
| 2534 | path.moveTo(0, 0); |
| 2535 | path.lineTo(0, 0); |
| 2536 | path.quadTo(2, 0, 0, 1); |
| 2537 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2538 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2539 | } |
| 2540 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2541 | static void testQuadratic20(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2542 | SkPath path; |
| 2543 | path.moveTo(0, 0); |
| 2544 | path.quadTo(1, 0, 0, 1); |
| 2545 | path.lineTo(0, 1); |
| 2546 | path.close(); |
| 2547 | path.moveTo(0, 0); |
| 2548 | path.lineTo(0, 0); |
| 2549 | path.quadTo(1, 0, 0, 1); |
| 2550 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2551 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2552 | } |
| 2553 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2554 | static void testQuadratic21(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2555 | SkPath path; |
| 2556 | path.moveTo(0, 0); |
| 2557 | path.quadTo(1, 0, 0, 1); |
| 2558 | path.lineTo(0, 1); |
| 2559 | path.close(); |
| 2560 | path.moveTo(0, 0); |
| 2561 | path.lineTo(0, 0); |
| 2562 | path.quadTo(1, 0, 0, 2); |
| 2563 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2564 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2565 | } |
| 2566 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2567 | static void testQuadratic22(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2568 | SkPath path; |
| 2569 | path.moveTo(0, 0); |
| 2570 | path.quadTo(1, 0, 0, 1); |
| 2571 | path.lineTo(0, 1); |
| 2572 | path.close(); |
| 2573 | path.moveTo(0, 0); |
| 2574 | path.lineTo(0, 0); |
| 2575 | path.quadTo(0, 1, 2, 1); |
| 2576 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2577 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2578 | } |
| 2579 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2580 | static void testQuadratic23(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2581 | SkPath path; |
| 2582 | path.moveTo(0, 0); |
| 2583 | path.quadTo(1, 0, 0, 1); |
| 2584 | path.lineTo(0, 1); |
| 2585 | path.close(); |
| 2586 | path.moveTo(0, 0); |
| 2587 | path.lineTo(0, 0); |
| 2588 | path.quadTo(0, 2, 1, 2); |
| 2589 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2590 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2591 | } |
| 2592 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2593 | static void testQuadratic24(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2594 | SkPath path; |
| 2595 | path.moveTo(0, 0); |
| 2596 | path.quadTo(1, 0, 0, 1); |
| 2597 | path.lineTo(0, 1); |
| 2598 | path.close(); |
| 2599 | path.moveTo(0, 0); |
| 2600 | path.lineTo(1, 0); |
| 2601 | path.quadTo(2, 0, 0, 1); |
| 2602 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2603 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2604 | } |
| 2605 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2606 | static void testQuadratic25(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2607 | SkPath path; |
| 2608 | path.moveTo(0, 0); |
| 2609 | path.quadTo(1, 0, 1, 1); |
| 2610 | path.lineTo(1, 1); |
| 2611 | path.close(); |
| 2612 | path.moveTo(0, 0); |
| 2613 | path.lineTo(0, 0); |
| 2614 | path.quadTo(2, 1, 0, 2); |
| 2615 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2616 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2617 | } |
| 2618 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2619 | static void testQuadratic26(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2620 | SkPath path; |
| 2621 | path.moveTo(0, 0); |
| 2622 | path.quadTo(1, 0, 1, 1); |
| 2623 | path.lineTo(0, 2); |
| 2624 | path.close(); |
| 2625 | path.moveTo(0, 0); |
| 2626 | path.lineTo(0, 0); |
| 2627 | path.quadTo(1, 0, 0, 1); |
| 2628 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2629 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2630 | } |
| 2631 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2632 | static void testQuadratic27(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2633 | SkPath path; |
| 2634 | path.moveTo(0, 0); |
| 2635 | path.quadTo(1, 0, 1, 1); |
| 2636 | path.lineTo(2, 1); |
| 2637 | path.close(); |
| 2638 | path.moveTo(0, 0); |
| 2639 | path.lineTo(0, 0); |
| 2640 | path.quadTo(2, 1, 0, 2); |
| 2641 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2642 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2643 | } |
| 2644 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2645 | static void testQuadratic28(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2646 | SkPath path; |
| 2647 | path.moveTo(0, 0); |
| 2648 | path.quadTo(1, 0, 0, 1); |
| 2649 | path.lineTo(0, 1); |
| 2650 | path.close(); |
| 2651 | path.moveTo(0, 0); |
| 2652 | path.lineTo(0, 2); |
| 2653 | path.quadTo(1, 2, 0, 3); |
| 2654 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2655 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2656 | } |
| 2657 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2658 | static void testQuadratic29(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2659 | SkPath path; |
| 2660 | path.moveTo(0, 0); |
| 2661 | path.quadTo(1, 0, 2, 1); |
| 2662 | path.lineTo(0, 2); |
| 2663 | path.close(); |
| 2664 | path.moveTo(0, 0); |
| 2665 | path.lineTo(0, 0); |
| 2666 | path.quadTo(1, 0, 0, 1); |
| 2667 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2668 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2669 | } |
| 2670 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2671 | static void testQuadratic30(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2672 | SkPath path; |
| 2673 | path.moveTo(0, 0); |
| 2674 | path.quadTo(1, 0, 1, 2); |
| 2675 | path.lineTo(1, 2); |
| 2676 | path.close(); |
| 2677 | path.moveTo(0, 0); |
| 2678 | path.lineTo(1, 0); |
| 2679 | path.quadTo(0, 1, 1, 2); |
| 2680 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2681 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2682 | } |
| 2683 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2684 | static void testQuadratic31(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2685 | SkPath path; |
| 2686 | path.moveTo(0, 0); |
| 2687 | path.quadTo(1, 0, 1, 2); |
| 2688 | path.lineTo(1, 2); |
| 2689 | path.close(); |
| 2690 | path.moveTo(0, 0); |
| 2691 | path.lineTo(1, 0); |
| 2692 | path.quadTo(0, 1, 1, 3); |
| 2693 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2694 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2695 | } |
| 2696 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2697 | static void testQuadratic32(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2698 | SkPath path; |
| 2699 | path.moveTo(0, 0); |
| 2700 | path.quadTo(1, 0, 2, 3); |
| 2701 | path.lineTo(2, 3); |
| 2702 | path.close(); |
| 2703 | path.moveTo(0, 0); |
| 2704 | path.lineTo(0, 0); |
| 2705 | path.quadTo(3, 1, 0, 2); |
| 2706 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2707 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2708 | } |
| 2709 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2710 | static void testQuadratic33(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2711 | SkPath path; |
| 2712 | path.moveTo(0, 0); |
| 2713 | path.quadTo(2, 0, 0, 1); |
| 2714 | path.lineTo(0, 1); |
| 2715 | path.close(); |
| 2716 | path.moveTo(0, 0); |
| 2717 | path.lineTo(1, 1); |
| 2718 | path.quadTo(2, 1, 2, 2); |
| 2719 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2720 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2721 | } |
| 2722 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2723 | static void testQuadratic34(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2724 | SkPath path; |
| 2725 | path.moveTo(0, 0); |
| 2726 | path.quadTo(2, 0, 0, 1); |
| 2727 | path.lineTo(0, 1); |
| 2728 | path.close(); |
| 2729 | path.moveTo(1, 0); |
| 2730 | path.lineTo(1, 1); |
| 2731 | path.quadTo(2, 1, 1, 2); |
| 2732 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2733 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2734 | } |
| 2735 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2736 | static void testQuadratic35(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2737 | SkPath path; |
| 2738 | path.moveTo(0, 0); |
| 2739 | path.quadTo(0, 1, 1, 1); |
| 2740 | path.lineTo(1, 3); |
| 2741 | path.close(); |
| 2742 | path.moveTo(2, 0); |
| 2743 | path.lineTo(3, 0); |
| 2744 | path.quadTo(0, 1, 1, 1); |
| 2745 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2746 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2747 | } |
| 2748 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2749 | static void testQuadratic36(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2750 | SkPath path; |
| 2751 | path.moveTo(0, 0); |
| 2752 | path.quadTo(2, 1, 2, 3); |
| 2753 | path.lineTo(2, 3); |
| 2754 | path.close(); |
| 2755 | path.moveTo(3, 1); |
| 2756 | path.lineTo(1, 2); |
| 2757 | path.quadTo(3, 2, 1, 3); |
| 2758 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2759 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2760 | } |
| 2761 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2762 | static void testQuadratic37(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2763 | SkPath path; |
| 2764 | path.moveTo(0, 0); |
| 2765 | path.quadTo(0, 2, 1, 2); |
| 2766 | path.lineTo(1, 2); |
| 2767 | path.close(); |
| 2768 | path.moveTo(0, 0); |
| 2769 | path.lineTo(3, 1); |
| 2770 | path.quadTo(0, 2, 1, 2); |
| 2771 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2772 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2773 | } |
| 2774 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2775 | static void testQuadratic38(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2776 | SkPath path; |
| 2777 | path.moveTo(1, 0); |
| 2778 | path.quadTo(0, 1, 1, 1); |
| 2779 | path.lineTo(1, 1); |
| 2780 | path.close(); |
| 2781 | path.moveTo(1, 0); |
| 2782 | path.lineTo(1, 2); |
| 2783 | path.quadTo(2, 2, 1, 3); |
| 2784 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2785 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2786 | } |
| 2787 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2788 | static void testQuadratic51(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2789 | SkPath path; |
| 2790 | path.moveTo(369.863983f, 145.645813f); |
| 2791 | path.quadTo(382.380371f, 121.254936f, 406.236359f, 121.254936f); |
| 2792 | path.lineTo(369.863983f, 145.645813f); |
| 2793 | path.close(); |
| 2794 | path.moveTo(369.970581f, 137.94342f); |
| 2795 | path.quadTo(383.98465f, 121.254936f, 406.235992f, 121.254936f); |
| 2796 | path.lineTo(369.970581f, 137.94342f); |
| 2797 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2798 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2799 | } |
| 2800 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2801 | static void testQuadratic53(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2802 | SkPath path; |
| 2803 | path.moveTo(303.12088f, 141.299606f); |
| 2804 | path.lineTo(330.463562f, 217.659027f); |
| 2805 | path.lineTo(303.12088f, 141.299606f); |
| 2806 | path.close(); |
| 2807 | path.moveTo(371.919067f, 205.854996f); |
| 2808 | path.lineTo(326.236786f, 205.854996f); |
| 2809 | path.quadTo(329.104431f, 231.663818f, 351.512085f, 231.663818f); |
| 2810 | path.lineTo(371.919067f, 205.854996f); |
| 2811 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2812 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2813 | } |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 2814 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2815 | static void testQuadratic55(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2816 | SkPath path; |
| 2817 | path.moveTo(303.12088f, 141.299606f); |
| 2818 | path.lineTo(330.463562f, 217.659027f); |
| 2819 | path.lineTo(358.606506f, 141.299606f); |
| 2820 | path.lineTo(303.12088f, 141.299606f); |
| 2821 | path.close(); |
| 2822 | path.moveTo(326.236786f, 205.854996f); |
| 2823 | path.quadTo(329.104431f, 231.663818f, 351.512085f, 231.663818f); |
| 2824 | path.lineTo(326.236786f, 205.854996f); |
| 2825 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2826 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2827 | } |
| 2828 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2829 | static void testQuadratic56(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2830 | SkPath path; |
| 2831 | path.moveTo(366.608826f, 151.196014f); |
| 2832 | path.quadTo(378.803101f, 136.674606f, 398.164948f, 136.674606f); |
| 2833 | path.lineTo(354.009216f, 208.816208f); |
| 2834 | path.lineTo(393.291473f, 102.232819f); |
| 2835 | path.lineTo(359.978058f, 136.581512f); |
| 2836 | path.quadTo(378.315979f, 136.581512f, 388.322723f, 149.613556f); |
| 2837 | path.lineTo(364.390686f, 157.898193f); |
| 2838 | path.quadTo(375.281769f, 136.674606f, 396.039917f, 136.674606f); |
| 2839 | path.lineTo(350, 120); |
| 2840 | path.lineTo(366.608826f, 151.196014f); |
| 2841 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2842 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2843 | } |
| 2844 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2845 | static void testLine80(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2846 | SkPath path; |
| 2847 | path.moveTo(4, 0); |
| 2848 | path.lineTo(3, 7); |
| 2849 | path.lineTo(7, 5); |
| 2850 | path.lineTo(2, 2); |
| 2851 | path.close(); |
| 2852 | path.moveTo(0, 6); |
| 2853 | path.lineTo(6, 12); |
| 2854 | path.lineTo(8, 3); |
| 2855 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2856 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2857 | } |
| 2858 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2859 | static void testQuadratic58(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2860 | SkPath path; |
caryclark@google.com | 07e97fc | 2013-07-08 17:17:02 +0000 | [diff] [blame] | 2861 | path.moveTo(283.714233f, 240); |
| 2862 | path.lineTo(283.714233f, 141.299606f); |
| 2863 | path.lineTo(303.12088f, 141.299606f); |
| 2864 | path.lineTo(330.463562f, 217.659027f); |
| 2865 | path.lineTo(358.606506f, 141.299606f); |
| 2866 | path.lineTo(362.874634f, 159.705902f); |
| 2867 | path.lineTo(335.665344f, 233.397751f); |
| 2868 | path.lineTo(322.12738f, 233.397751f); |
| 2869 | path.lineTo(295.718353f, 159.505829f); |
| 2870 | path.lineTo(295.718353f, 240); |
| 2871 | path.lineTo(283.714233f, 240); |
| 2872 | path.close(); |
| 2873 | path.moveTo(322.935669f, 231.030273f); |
| 2874 | path.quadTo(312.832214f, 220.393295f, 312.832214f, 203.454178f); |
| 2875 | path.quadTo(312.832214f, 186.981888f, 321.73526f, 176.444946f); |
| 2876 | path.quadTo(330.638306f, 165.90802f, 344.509705f, 165.90802f); |
| 2877 | path.quadTo(357.647522f, 165.90802f, 364.81665f, 175.244537f); |
| 2878 | path.lineTo(371.919067f, 205.854996f); |
| 2879 | path.lineTo(326.236786f, 205.854996f); |
| 2880 | path.quadTo(329.104431f, 231.663818f, 351.512085f, 231.663818f); |
| 2881 | path.lineTo(322.935669f, 231.030273f); |
| 2882 | path.close(); |
| 2883 | path.moveTo(326.837006f, 195.984955f); |
| 2884 | path.lineTo(358.78125f, 195.984955f); |
| 2885 | path.quadTo(358.78125f, 175.778046f, 343.709442f, 175.778046f); |
| 2886 | path.quadTo(328.570923f, 175.778046f, 326.837006f, 195.984955f); |
| 2887 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2888 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2889 | } |
| 2890 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2891 | static void testQuadratic59x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2892 | SkPath path; |
| 2893 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2894 | path.moveTo(0, 0); |
| 2895 | path.quadTo(0, 0, 0, 0); |
| 2896 | path.lineTo(2, 2); |
| 2897 | path.close(); |
| 2898 | path.moveTo(0, 0); |
| 2899 | path.lineTo(2, 0); |
| 2900 | path.quadTo(3, 1, 1, 2); |
| 2901 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2902 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2903 | } |
| 2904 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2905 | static void testQuadratic59(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2906 | SkPath path; |
| 2907 | path.setFillType(SkPath::kWinding_FillType); |
| 2908 | path.moveTo(0, 0); |
| 2909 | path.quadTo(0, 0, 0, 0); |
| 2910 | path.lineTo(2, 2); |
| 2911 | path.close(); |
| 2912 | path.moveTo(0, 0); |
| 2913 | path.lineTo(2, 0); |
| 2914 | path.quadTo(3, 1, 1, 2); |
| 2915 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2916 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2917 | } |
| 2918 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2919 | static void testQuadratic63(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2920 | SkPath path; |
| 2921 | path.moveTo(0, 0); |
| 2922 | path.quadTo(0, 0, 0, 0); |
| 2923 | path.lineTo(3, 2); |
| 2924 | path.close(); |
| 2925 | path.moveTo(1, 0); |
| 2926 | path.lineTo(2, 1); |
| 2927 | path.quadTo(2, 1, 2, 2); |
| 2928 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2929 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2930 | } |
| 2931 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2932 | static void testQuadratic64(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2933 | SkPath path; |
| 2934 | path.moveTo(0, 0); |
| 2935 | path.quadTo(0, 0, 0, 0); |
| 2936 | path.lineTo(2, 3); |
| 2937 | path.close(); |
| 2938 | path.moveTo(1, 2); |
| 2939 | path.lineTo(2, 2); |
| 2940 | path.quadTo(0, 3, 3, 3); |
| 2941 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2942 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2943 | } |
| 2944 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2945 | static void testQuadratic65(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2946 | SkPath path; |
| 2947 | path.moveTo(0, 0); |
| 2948 | path.quadTo(0, 0, 0, 0); |
| 2949 | path.lineTo(3, 2); |
| 2950 | path.close(); |
| 2951 | path.moveTo(2, 1); |
| 2952 | path.lineTo(2, 2); |
| 2953 | path.quadTo(0, 3, 1, 3); |
| 2954 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2955 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2956 | } |
| 2957 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2958 | static void testQuadratic67x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2959 | SkPath path; |
| 2960 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 2961 | path.moveTo(0, 0); |
| 2962 | path.quadTo(0, 0, 2, 1); |
| 2963 | path.lineTo(2, 2); |
| 2964 | path.close(); |
| 2965 | path.moveTo(0, 0); |
| 2966 | path.lineTo(2, 0); |
| 2967 | path.quadTo(1, 1, 3, 2); |
| 2968 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2969 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2970 | } |
| 2971 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2972 | static void testQuadratic68(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2973 | SkPath path; |
| 2974 | path.moveTo(0, 0); |
| 2975 | path.quadTo(1, 0, 0, 1); |
| 2976 | path.lineTo(1, 2); |
| 2977 | path.close(); |
| 2978 | path.moveTo(0, 0); |
| 2979 | path.lineTo(0, 0); |
| 2980 | path.quadTo(0, 1, 2, 1); |
| 2981 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2982 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2983 | } |
| 2984 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2985 | static void testQuadratic69(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2986 | SkPath path; |
| 2987 | path.moveTo(0, 0); |
| 2988 | path.quadTo(0, 0, 0, 1); |
| 2989 | path.lineTo(3, 2); |
| 2990 | path.close(); |
| 2991 | path.moveTo(2, 0); |
| 2992 | path.lineTo(1, 1); |
| 2993 | path.quadTo(3, 2, 2, 3); |
| 2994 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2995 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2996 | } |
| 2997 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 2998 | static void testQuadratic70x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 2999 | SkPath path; |
| 3000 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3001 | path.moveTo(0, 0); |
| 3002 | path.quadTo(1, 0, 0, 1); |
| 3003 | path.lineTo(1, 2); |
| 3004 | path.close(); |
| 3005 | path.moveTo(0, 0); |
| 3006 | path.lineTo(0, 0); |
| 3007 | path.quadTo(0, 1, 2, 1); |
| 3008 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3009 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3010 | } |
| 3011 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3012 | static void testQuadratic71(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3013 | SkPath path; |
| 3014 | path.moveTo(0, 0); |
| 3015 | path.quadTo(1, 0, 1, 1); |
| 3016 | path.lineTo(3, 2); |
| 3017 | path.close(); |
| 3018 | path.moveTo(0, 0); |
| 3019 | path.lineTo(0, 0); |
| 3020 | path.quadTo(1, 1, 3, 1); |
| 3021 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3022 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3023 | } |
| 3024 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3025 | static void testQuadratic72(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3026 | SkPath path; |
| 3027 | path.moveTo(0, 0); |
| 3028 | path.quadTo(1, 0, 1, 2); |
| 3029 | path.lineTo(1, 2); |
| 3030 | path.close(); |
| 3031 | path.moveTo(0, 0); |
| 3032 | path.lineTo(1, 0); |
| 3033 | path.quadTo(0, 1, 3, 2); |
| 3034 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3035 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3036 | } |
| 3037 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3038 | static void testQuadratic73(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3039 | SkPath path; |
| 3040 | path.moveTo(0, 0); |
| 3041 | path.quadTo(1, 0, 0, 3); |
| 3042 | path.lineTo(0, 3); |
| 3043 | path.close(); |
| 3044 | path.moveTo(0, 0); |
| 3045 | path.lineTo(1, 0); |
| 3046 | path.quadTo(0, 1, 1, 1); |
| 3047 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3048 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3049 | } |
| 3050 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3051 | static void testQuadratic74(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3052 | SkPath path; |
| 3053 | path.moveTo(0, 0); |
| 3054 | path.quadTo(1, 0, 1, 3); |
| 3055 | path.lineTo(1, 3); |
| 3056 | path.close(); |
| 3057 | path.moveTo(0, 0); |
| 3058 | path.lineTo(0, 1); |
| 3059 | path.quadTo(3, 2, 2, 3); |
| 3060 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3061 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3062 | } |
| 3063 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3064 | static void testQuadratic75(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3065 | SkPath path; |
| 3066 | path.moveTo(0, 0); |
| 3067 | path.quadTo(1, 0, 1, 3); |
| 3068 | path.lineTo(2, 3); |
| 3069 | path.close(); |
| 3070 | path.moveTo(0, 0); |
| 3071 | path.lineTo(0, 1); |
| 3072 | path.quadTo(3, 2, 2, 3); |
| 3073 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3074 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3075 | } |
| 3076 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3077 | static void testQuadratic76(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3078 | SkPath path; |
| 3079 | path.moveTo(0, 0); |
| 3080 | path.quadTo(0, 0, 0, 0); |
| 3081 | path.lineTo(2, 3); |
| 3082 | path.close(); |
| 3083 | path.moveTo(1, 0); |
| 3084 | path.lineTo(1, 2); |
| 3085 | path.quadTo(1, 2, 2, 2); |
| 3086 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3087 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3088 | } |
| 3089 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3090 | static void testQuadratic77(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3091 | SkPath path; |
| 3092 | path.moveTo(0, 0); |
| 3093 | path.quadTo(1, 0, 1, 1); |
| 3094 | path.lineTo(3, 1); |
| 3095 | path.close(); |
| 3096 | path.moveTo(0, 0); |
| 3097 | path.lineTo(1, 0); |
| 3098 | path.quadTo(0, 1, 3, 2); |
| 3099 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3100 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3101 | } |
| 3102 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3103 | static void testQuadratic78(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3104 | SkPath path; |
| 3105 | path.moveTo(0, 0); |
| 3106 | path.quadTo(1, 0, 1, 2); |
| 3107 | path.lineTo(3, 2); |
| 3108 | path.close(); |
| 3109 | path.moveTo(0, 0); |
| 3110 | path.lineTo(0, 0); |
| 3111 | path.quadTo(2, 1, 0, 2); |
| 3112 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3113 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3114 | } |
| 3115 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3116 | static void testQuadratic79(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3117 | SkPath path; |
| 3118 | path.moveTo(0, 0); |
| 3119 | path.quadTo(1, 0, 1, 2); |
| 3120 | path.lineTo(3, 2); |
| 3121 | path.close(); |
| 3122 | path.moveTo(0, 0); |
| 3123 | path.lineTo(1, 0); |
| 3124 | path.quadTo(0, 1, 3, 2); |
| 3125 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3126 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3127 | } |
| 3128 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3129 | static void testEight1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3130 | SkPath path; |
| 3131 | path.moveTo(0, 0); |
| 3132 | path.lineTo(2, 2); |
| 3133 | path.lineTo(0, 2); |
| 3134 | path.lineTo(2, 0); |
| 3135 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3136 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3137 | } |
| 3138 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3139 | static void testEight2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3140 | SkPath path; |
| 3141 | path.moveTo(0, 0); |
| 3142 | path.lineTo(2, 0); |
| 3143 | path.lineTo(0, 2); |
| 3144 | path.lineTo(2, 2); |
| 3145 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3146 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3147 | } |
| 3148 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3149 | static void testEight3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3150 | SkPath path; |
| 3151 | path.moveTo(0, 0); |
| 3152 | path.lineTo(0, 2); |
| 3153 | path.lineTo(2, 0); |
| 3154 | path.lineTo(2, 2); |
| 3155 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3156 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3157 | } |
| 3158 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3159 | static void testEight4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3160 | SkPath path; |
| 3161 | path.moveTo(0, 0); |
| 3162 | path.lineTo(2, 2); |
| 3163 | path.lineTo(2, 0); |
| 3164 | path.lineTo(0, 2); |
| 3165 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3166 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3167 | } |
| 3168 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3169 | static void testEight5(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3170 | SkPath path; |
| 3171 | path.moveTo(1, 0); |
| 3172 | path.lineTo(1, 2); |
| 3173 | path.lineTo(0, 2); |
| 3174 | path.lineTo(2, 0); |
| 3175 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3176 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3177 | } |
| 3178 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3179 | static void testEight6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3180 | SkPath path; |
| 3181 | path.moveTo(1, 0); |
| 3182 | path.lineTo(2, 0); |
| 3183 | path.lineTo(0, 2); |
| 3184 | path.lineTo(1, 2); |
| 3185 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3186 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3187 | } |
| 3188 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3189 | static void testEight7(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3190 | SkPath path; |
| 3191 | path.moveTo(0, 0); |
| 3192 | path.lineTo(0, 1); |
| 3193 | path.lineTo(2, 1); |
| 3194 | path.lineTo(2, 2); |
| 3195 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3196 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3197 | } |
| 3198 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3199 | static void testEight8(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3200 | SkPath path; |
| 3201 | path.moveTo(0, 0); |
| 3202 | path.lineTo(2, 2); |
| 3203 | path.lineTo(2, 1); |
| 3204 | path.lineTo(0, 1); |
| 3205 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3206 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3207 | } |
| 3208 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3209 | static void testEight9(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3210 | SkPath path; |
| 3211 | path.moveTo(1, 0); |
| 3212 | path.lineTo(1, 2); |
| 3213 | path.lineTo(2, 1); |
| 3214 | path.lineTo(0, 1); |
| 3215 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3216 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3217 | } |
| 3218 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3219 | static void testEight10(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3220 | SkPath path; |
| 3221 | path.moveTo(1, 0); |
| 3222 | path.lineTo(0, 1); |
| 3223 | path.lineTo(2, 1); |
| 3224 | path.lineTo(1, 2); |
| 3225 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3226 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3227 | } |
| 3228 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3229 | static void testQuadratic80(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3230 | SkPath path; |
| 3231 | path.moveTo(0, 0); |
| 3232 | path.quadTo(1, 0, 2, 3); |
| 3233 | path.lineTo(2, 3); |
| 3234 | path.close(); |
| 3235 | path.moveTo(1, 0); |
| 3236 | path.lineTo(3, 0); |
| 3237 | path.quadTo(0, 1, 1, 1); |
| 3238 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3239 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3240 | } |
| 3241 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3242 | static void testQuadratic81(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3243 | SkPath path; |
| 3244 | path.moveTo(0, 0); |
| 3245 | path.quadTo(2, 0, 1, 1); |
| 3246 | path.lineTo(1, 1); |
| 3247 | path.close(); |
| 3248 | path.moveTo(0, 0); |
| 3249 | path.lineTo(0, 0); |
| 3250 | path.quadTo(2, 1, 0, 2); |
| 3251 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3252 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3253 | } |
| 3254 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3255 | static void testQuadratic82(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3256 | SkPath path; |
| 3257 | path.moveTo(0, 0); |
| 3258 | path.quadTo(2, 0, 1, 1); |
| 3259 | path.lineTo(0, 3); |
| 3260 | path.close(); |
| 3261 | path.moveTo(0, 0); |
| 3262 | path.lineTo(0, 0); |
| 3263 | path.quadTo(2, 1, 0, 2); |
| 3264 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3265 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3266 | } |
| 3267 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3268 | static void testQuadratic83(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3269 | SkPath path; |
| 3270 | path.moveTo(0, 0); |
| 3271 | path.quadTo(0, 0, 2, 0); |
| 3272 | path.lineTo(2, 2); |
| 3273 | path.close(); |
| 3274 | path.moveTo(0, 1); |
| 3275 | path.lineTo(0, 2); |
| 3276 | path.quadTo(2, 2, 1, 3); |
| 3277 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3278 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3279 | } |
| 3280 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3281 | static void testQuadratic84(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3282 | SkPath path; |
| 3283 | path.moveTo(0, 0); |
| 3284 | path.quadTo(2, 0, 1, 1); |
| 3285 | path.lineTo(2, 1); |
| 3286 | path.close(); |
| 3287 | path.moveTo(1, 0); |
| 3288 | path.lineTo(2, 0); |
| 3289 | path.quadTo(0, 1, 2, 2); |
| 3290 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3291 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3292 | } |
| 3293 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3294 | static void testQuadratic85(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3295 | SkPath path; |
| 3296 | path.moveTo(0, 0); |
| 3297 | path.quadTo(3, 0, 1, 1); |
| 3298 | path.lineTo(1, 1); |
| 3299 | path.close(); |
| 3300 | path.moveTo(1, 0); |
| 3301 | path.lineTo(3, 0); |
| 3302 | path.quadTo(0, 1, 1, 2); |
| 3303 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3304 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3305 | } |
| 3306 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3307 | static void testQuadratic86(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3308 | SkPath path; |
| 3309 | path.moveTo(0, 0); |
| 3310 | path.quadTo(0, 1, 1, 1); |
| 3311 | path.lineTo(2, 3); |
| 3312 | path.close(); |
| 3313 | path.moveTo(0, 0); |
| 3314 | path.lineTo(0, 0); |
| 3315 | path.quadTo(1, 1, 1, 3); |
| 3316 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3317 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3318 | } |
| 3319 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3320 | static void testQuadratic87(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3321 | SkPath path; |
| 3322 | path.moveTo(0, 0); |
| 3323 | path.quadTo(2, 1, 0, 2); |
| 3324 | path.lineTo(2, 3); |
| 3325 | path.close(); |
| 3326 | path.moveTo(0, 0); |
| 3327 | path.lineTo(1, 1); |
| 3328 | path.quadTo(0, 2, 3, 2); |
| 3329 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3330 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3331 | } |
| 3332 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3333 | static void testQuadratic88(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3334 | SkPath path; |
| 3335 | path.moveTo(0, 0); |
| 3336 | path.quadTo(2, 1, 0, 2); |
| 3337 | path.lineTo(2, 2); |
| 3338 | path.close(); |
| 3339 | path.moveTo(1, 0); |
| 3340 | path.lineTo(1, 1); |
| 3341 | path.quadTo(0, 2, 2, 2); |
| 3342 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3343 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3344 | } |
| 3345 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3346 | static void testQuadratic89x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3347 | SkPath path; |
| 3348 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3349 | path.moveTo(0, 0); |
| 3350 | path.quadTo(3, 1, 2, 2); |
| 3351 | path.lineTo(0, 3); |
| 3352 | path.close(); |
| 3353 | path.moveTo(0, 0); |
| 3354 | path.lineTo(2, 1); |
| 3355 | path.quadTo(3, 1, 3, 3); |
| 3356 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3357 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3358 | } |
| 3359 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3360 | static void testQuadratic90x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3361 | SkPath path; |
| 3362 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3363 | path.moveTo(0, 0); |
| 3364 | path.quadTo(3, 0, 2, 2); |
| 3365 | path.lineTo(1, 3); |
| 3366 | path.close(); |
| 3367 | path.moveTo(0, 0); |
| 3368 | path.lineTo(0, 1); |
| 3369 | path.quadTo(3, 2, 2, 3); |
| 3370 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3371 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3372 | } |
| 3373 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3374 | static void testQuadratic91(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3375 | SkPath path; |
| 3376 | path.moveTo(0, 0); |
| 3377 | path.quadTo(3, 2, 2, 3); |
| 3378 | path.lineTo(2, 3); |
| 3379 | path.close(); |
| 3380 | path.moveTo(0, 0); |
| 3381 | path.lineTo(1, 1); |
| 3382 | path.quadTo(2, 1, 2, 3); |
| 3383 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3384 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3385 | } |
| 3386 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3387 | static void testQuadratic92x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3388 | SkPath path; |
| 3389 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3390 | path.moveTo(1, 0); |
| 3391 | path.quadTo(3, 0, 2, 2); |
| 3392 | path.lineTo(2, 2); |
| 3393 | path.close(); |
| 3394 | path.moveTo(2, 0); |
| 3395 | path.lineTo(0, 1); |
| 3396 | path.quadTo(3, 2, 2, 3); |
| 3397 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3398 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3399 | } |
| 3400 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3401 | static void testLine82(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3402 | SkPath path; |
| 3403 | path.addRect(20, 0, 40, 40, SkPath::kCCW_Direction); |
| 3404 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 3405 | path.addRect(24, 32, 33, 36, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3406 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3407 | } |
| 3408 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3409 | static void testLine82a(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3410 | SkPath path; |
| 3411 | path.addRect(0, 0, 6, 10, SkPath::kCW_Direction); |
| 3412 | path.addRect(2, 2, 4, 4, SkPath::kCW_Direction); |
| 3413 | path.addRect(2, 6, 4, 8, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3414 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3415 | } |
| 3416 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3417 | static void testLine82b(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3418 | SkPath path; |
| 3419 | path.addRect(0, 0, 6, 10, SkPath::kCW_Direction); |
| 3420 | path.addRect(2, 2, 4, 4, SkPath::kCW_Direction); |
| 3421 | path.addRect(2, 6, 4, 8, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3422 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3423 | } |
| 3424 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3425 | static void testLine82c(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3426 | SkPath path; |
| 3427 | path.addRect(0, 0, 6, 10, SkPath::kCW_Direction); |
| 3428 | path.addRect(2, 2, 4, 4, SkPath::kCCW_Direction); |
| 3429 | path.addRect(2, 6, 4, 8, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3430 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3431 | } |
| 3432 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3433 | static void testLine82d(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3434 | SkPath path; |
| 3435 | path.addRect(0, 0, 6, 10, SkPath::kCW_Direction); |
| 3436 | path.addRect(2, 2, 4, 4, SkPath::kCCW_Direction); |
| 3437 | path.addRect(2, 6, 4, 8, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3438 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3439 | } |
| 3440 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3441 | static void testLine82e(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3442 | SkPath path; |
| 3443 | path.addRect(0, 0, 6, 10, SkPath::kCCW_Direction); |
| 3444 | path.addRect(2, 2, 4, 4, SkPath::kCW_Direction); |
| 3445 | path.addRect(2, 6, 4, 8, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3446 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3447 | } |
| 3448 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3449 | static void testLine82f(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3450 | SkPath path; |
| 3451 | path.addRect(0, 0, 6, 10, SkPath::kCCW_Direction); |
| 3452 | path.addRect(2, 2, 4, 4, SkPath::kCW_Direction); |
| 3453 | path.addRect(2, 6, 4, 8, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3454 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3455 | } |
| 3456 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3457 | static void testLine82g(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3458 | SkPath path; |
| 3459 | path.addRect(0, 0, 6, 10, SkPath::kCCW_Direction); |
| 3460 | path.addRect(2, 2, 4, 4, SkPath::kCCW_Direction); |
| 3461 | path.addRect(2, 6, 4, 8, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3462 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3463 | } |
| 3464 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3465 | static void testLine82h(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3466 | SkPath path; |
| 3467 | path.addRect(0, 0, 6, 10, SkPath::kCCW_Direction); |
| 3468 | path.addRect(2, 2, 4, 4, SkPath::kCCW_Direction); |
| 3469 | path.addRect(2, 6, 4, 8, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3470 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3471 | } |
| 3472 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3473 | static void testLine83(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3474 | SkPath path; |
| 3475 | path.addRect(10, 30, 30, 40, SkPath::kCCW_Direction); |
| 3476 | path.addRect(0, 12, 12, 18, SkPath::kCCW_Direction); |
| 3477 | path.addRect(4, 13, 13, 16, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3478 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3479 | } |
| 3480 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3481 | static void testLine84(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3482 | SkPath path; |
| 3483 | path.addRect(0, 12, 60, 30, SkPath::kCCW_Direction); |
| 3484 | path.addRect(10, 20, 40, 30, SkPath::kCW_Direction); |
| 3485 | path.addRect(0, 12, 12, 12, SkPath::kCW_Direction); |
| 3486 | path.addRect(4, 12, 13, 13, SkPath::kCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3487 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3488 | } |
| 3489 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3490 | static void testLine84x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3491 | SkPath path; |
| 3492 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3493 | path.addRect(0, 12, 60, 30, SkPath::kCCW_Direction); |
| 3494 | path.addRect(10, 20, 40, 30, SkPath::kCCW_Direction); |
| 3495 | path.addRect(0, 12, 12, 12, SkPath::kCCW_Direction); |
| 3496 | path.addRect(4, 12, 13, 13, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3497 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3498 | } |
| 3499 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3500 | static void testLine85(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3501 | SkPath path; |
| 3502 | path.addRect(36, 0, 66, 60, SkPath::kCCW_Direction); |
| 3503 | path.addRect(20, 0, 40, 40, SkPath::kCCW_Direction); |
| 3504 | path.addRect(12, 0, 24, 24, SkPath::kCCW_Direction); |
| 3505 | path.addRect(32, 0, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3506 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3507 | } |
| 3508 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3509 | static void testQuadralateral1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3510 | SkPath path; |
| 3511 | path.moveTo(0, 0); |
| 3512 | path.lineTo(0, 0); |
| 3513 | path.lineTo(0, 0); |
| 3514 | path.lineTo(3, 2); |
| 3515 | path.close(); |
| 3516 | path.moveTo(0, 0); |
| 3517 | path.lineTo(2, 1); |
| 3518 | path.lineTo(2, 2); |
| 3519 | path.lineTo(2, 3); |
| 3520 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3521 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3522 | } |
| 3523 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3524 | static void testCubic1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3525 | SkPath path; |
| 3526 | path.moveTo(0, 0); |
| 3527 | path.cubicTo(0, 1, 1, 1, 1, 0); |
| 3528 | path.close(); |
| 3529 | path.moveTo(1, 0); |
| 3530 | path.cubicTo(0, 0, 0, 1, 1, 1); |
| 3531 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3532 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3533 | } |
| 3534 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3535 | static void testQuadratic93(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3536 | SkPath path; |
| 3537 | path.moveTo(3, 0); |
| 3538 | path.quadTo(0, 1, 3, 2); |
| 3539 | path.lineTo(0, 3); |
| 3540 | path.close(); |
| 3541 | path.moveTo(1, 0); |
| 3542 | path.lineTo(2, 0); |
| 3543 | path.quadTo(1, 1, 2, 2); |
| 3544 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3545 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3546 | } |
| 3547 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3548 | static void testCubic2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3549 | SkPath path; |
| 3550 | path.moveTo(0,2); |
| 3551 | path.cubicTo(0,3, 2,1, 4,0); |
| 3552 | path.close(); |
| 3553 | path.moveTo(1,2); |
| 3554 | path.cubicTo(0,4, 2,0, 3,0); |
| 3555 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3556 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3557 | } |
| 3558 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3559 | static void testQuad1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3560 | SkPath path; |
| 3561 | path.moveTo(0,0); |
| 3562 | path.quadTo(0,0, 0,1); |
| 3563 | path.lineTo(1,1); |
| 3564 | path.close(); |
| 3565 | path.moveTo(0,0); |
| 3566 | path.quadTo(1,1, 0,2); |
| 3567 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3568 | testSimplify(reporter, path, filename); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3569 | } |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 3570 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3571 | static void testQuadralateral2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | e942bc3 | 2013-04-10 18:53:01 +0000 | [diff] [blame] | 3572 | SkPath path; |
| 3573 | path.moveTo(0, 0); |
| 3574 | path.lineTo(2, 2); |
| 3575 | path.lineTo(0, 3); |
| 3576 | path.lineTo(3, 3); |
| 3577 | path.close(); |
| 3578 | path.moveTo(2, 0); |
| 3579 | path.lineTo(3, 0); |
| 3580 | path.lineTo(0, 1); |
| 3581 | path.lineTo(1, 2); |
| 3582 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3583 | testSimplify(reporter, path, filename); |
caryclark@google.com | e942bc3 | 2013-04-10 18:53:01 +0000 | [diff] [blame] | 3584 | } |
| 3585 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3586 | static void testQuadratic94(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3587 | SkPath path; |
| 3588 | path.moveTo(0, 0); |
| 3589 | path.lineTo(8, 8); |
| 3590 | path.quadTo(8, 4, 4, 4); |
| 3591 | path.quadTo(4, 0, 0, 0); |
| 3592 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3593 | testSimplify(reporter, path, filename); |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3594 | } |
| 3595 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3596 | static void testQuadratic95(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3597 | SkPath path; |
| 3598 | path.moveTo(8, 8); |
| 3599 | path.lineTo(0, 0); |
| 3600 | path.quadTo(4, 0, 4, 4); |
| 3601 | path.quadTo(8, 4, 8, 8); |
| 3602 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3603 | testSimplify(reporter, path, filename); |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3604 | } |
| 3605 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3606 | static void testQuadratic96(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3607 | SkPath path; |
| 3608 | path.moveTo(8, 0); |
| 3609 | path.lineTo(0, 8); |
| 3610 | path.quadTo(0, 4, 4, 4); |
| 3611 | path.quadTo(4, 0, 8, 0); |
| 3612 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3613 | testSimplify(reporter, path, filename); |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3614 | } |
| 3615 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3616 | static void testQuadratic97(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3617 | SkPath path; |
| 3618 | path.moveTo(0, 8); |
| 3619 | path.lineTo(8, 0); |
| 3620 | path.quadTo(4, 0, 4, 4); |
| 3621 | path.quadTo(0, 4, 0, 8); |
| 3622 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3623 | testSimplify(reporter, path, filename); |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 3624 | } |
| 3625 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3626 | static void testTriangles1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 0361032 | 2013-04-18 15:58:21 +0000 | [diff] [blame] | 3627 | SkPath path; |
| 3628 | path.moveTo(0, 0); |
| 3629 | path.lineTo(1, 0); |
| 3630 | path.lineTo(3, 3); |
| 3631 | path.close(); |
| 3632 | path.moveTo(0, 0); |
| 3633 | path.lineTo(1, 2); |
| 3634 | path.lineTo(1, 1); |
| 3635 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3636 | testSimplify(reporter, path, filename); |
caryclark@google.com | 0361032 | 2013-04-18 15:58:21 +0000 | [diff] [blame] | 3637 | } |
| 3638 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3639 | static void testTriangles2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 0361032 | 2013-04-18 15:58:21 +0000 | [diff] [blame] | 3640 | SkPath path; |
| 3641 | path.moveTo(0, 0); |
| 3642 | path.lineTo(1, 0); |
| 3643 | path.lineTo(3, 3); |
| 3644 | path.close(); |
| 3645 | path.moveTo(1, 1); |
| 3646 | path.lineTo(2, 3); |
| 3647 | path.lineTo(1, 2); |
| 3648 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3649 | testSimplify(reporter, path, filename); |
caryclark@google.com | 0361032 | 2013-04-18 15:58:21 +0000 | [diff] [blame] | 3650 | } |
| 3651 | |
caryclark | 5435929 | 2015-03-26 07:52:43 -0700 | [diff] [blame] | 3652 | // A test for this case: |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 3653 | // contourA has two segments that are coincident |
| 3654 | // contourB has two segments that are coincident in the same place |
| 3655 | // each ends up with +2/0 pairs for winding count |
| 3656 | // since logic in OpSegment::addTCoincident doesn't transfer count (only increments/decrements) |
| 3657 | // can this be resolved to +4/0 ? |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3658 | static void testAddTCoincident1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 3659 | SkPath path; |
| 3660 | path.moveTo(2, 0); |
| 3661 | path.lineTo(2, 2); |
| 3662 | path.lineTo(1, 1); |
| 3663 | path.lineTo(2, 0); |
| 3664 | path.lineTo(2, 2); |
| 3665 | path.lineTo(1, 1); |
| 3666 | path.close(); |
| 3667 | path.moveTo(2, 0); |
| 3668 | path.lineTo(2, 2); |
| 3669 | path.lineTo(3, 1); |
| 3670 | path.lineTo(2, 0); |
| 3671 | path.lineTo(2, 2); |
| 3672 | path.lineTo(3, 1); |
| 3673 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3674 | testSimplify(reporter, path, filename); |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 3675 | } |
| 3676 | |
| 3677 | // test with implicit close |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3678 | static void testAddTCoincident2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 3679 | SkPath path; |
| 3680 | path.moveTo(2, 0); |
| 3681 | path.lineTo(2, 2); |
| 3682 | path.lineTo(1, 1); |
| 3683 | path.lineTo(2, 0); |
| 3684 | path.lineTo(2, 2); |
| 3685 | path.lineTo(1, 1); |
| 3686 | path.moveTo(2, 0); |
| 3687 | path.lineTo(2, 2); |
| 3688 | path.lineTo(3, 1); |
| 3689 | path.lineTo(2, 0); |
| 3690 | path.lineTo(2, 2); |
| 3691 | path.lineTo(3, 1); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3692 | testSimplify(reporter, path, filename); |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 3693 | } |
| 3694 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3695 | static void testQuad2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3696 | SkPath path; |
| 3697 | path.moveTo(1, 0); |
| 3698 | path.quadTo(0, 1, 3, 2); |
| 3699 | path.lineTo(2, 3); |
| 3700 | path.close(); |
| 3701 | path.moveTo(0, 0); |
| 3702 | path.lineTo(1, 0); |
| 3703 | path.quadTo(0, 1, 1, 1); |
| 3704 | path.close(); |
| 3705 | } |
| 3706 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3707 | static void testQuad3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3708 | SkPath path; |
| 3709 | path.moveTo(1, 0); |
| 3710 | path.quadTo(0, 1, 3, 2); |
| 3711 | path.lineTo(3, 3); |
| 3712 | path.close(); |
| 3713 | path.moveTo(0, 0); |
| 3714 | path.lineTo(1, 0); |
| 3715 | path.quadTo(0, 1, 1, 1); |
| 3716 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3717 | testSimplify(reporter, path, filename); |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3718 | } |
| 3719 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3720 | static void testQuad4(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3721 | SkPath path; |
| 3722 | path.moveTo(2, 0); |
| 3723 | path.quadTo(0, 1, 1, 1); |
| 3724 | path.lineTo(3, 3); |
| 3725 | path.close(); |
| 3726 | path.moveTo(0, 0); |
| 3727 | path.lineTo(2, 0); |
| 3728 | path.quadTo(0, 1, 2, 2); |
| 3729 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3730 | testSimplify(reporter, path, filename); |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3731 | } |
| 3732 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3733 | static void testQuad5(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3734 | SkPath path; |
| 3735 | path.moveTo(2, 0); |
| 3736 | path.quadTo(0, 1, 2, 2); |
| 3737 | path.lineTo(1, 3); |
| 3738 | path.close(); |
| 3739 | path.moveTo(0, 0); |
| 3740 | path.lineTo(2, 0); |
| 3741 | path.quadTo(0, 1, 1, 1); |
| 3742 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3743 | testSimplify(reporter, path, filename); |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3744 | } |
| 3745 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3746 | static void testQuad6(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3747 | SkPath path; |
| 3748 | path.moveTo(2, 0); |
| 3749 | path.quadTo(0, 1, 2, 2); |
| 3750 | path.lineTo(1, 3); |
| 3751 | path.close(); |
| 3752 | path.moveTo(1, 0); |
| 3753 | path.lineTo(2, 0); |
| 3754 | path.quadTo(0, 1, 1, 1); |
| 3755 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3756 | testSimplify(reporter, path, filename); |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3757 | } |
| 3758 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3759 | static void testQuad7(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3760 | SkPath path; |
| 3761 | path.moveTo(3, 0); |
| 3762 | path.quadTo(0, 1, 1, 1); |
| 3763 | path.lineTo(1, 3); |
| 3764 | path.close(); |
| 3765 | path.moveTo(1, 0); |
| 3766 | path.lineTo(3, 0); |
| 3767 | path.quadTo(0, 1, 1, 2); |
| 3768 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3769 | testSimplify(reporter, path, filename); |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 3770 | } |
| 3771 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3772 | static void testQuadLineIntersect1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3773 | SkPath path; |
| 3774 | path.moveTo(0, 0); |
| 3775 | path.quadTo(3, 1, 0, 3); |
| 3776 | path.lineTo(2, 3); |
| 3777 | path.close(); |
| 3778 | path.moveTo(2, 0); |
| 3779 | path.lineTo(0, 1); |
| 3780 | path.quadTo(3, 1, 0, 2); |
| 3781 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3782 | testSimplify(reporter, path, filename); |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3783 | } |
| 3784 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3785 | static void testQuadLineIntersect2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3786 | SkPath path; |
| 3787 | path.moveTo(0, 0); |
| 3788 | path.quadTo(3, 1, 0, 3); |
| 3789 | path.lineTo(0, 3); |
| 3790 | path.close(); |
| 3791 | path.moveTo(2, 0); |
| 3792 | path.lineTo(0, 1); |
| 3793 | path.quadTo(3, 1, 0, 2); |
| 3794 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3795 | testSimplify(reporter, path, filename); |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3796 | } |
| 3797 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3798 | static void testQuadLineIntersect3(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3799 | SkPath path; |
| 3800 | path.moveTo(0, 0); |
| 3801 | path.quadTo(3, 1, 0, 3); |
| 3802 | path.lineTo(1, 3); |
| 3803 | path.close(); |
| 3804 | path.moveTo(2, 0); |
| 3805 | path.lineTo(0, 1); |
| 3806 | path.quadTo(3, 1, 0, 2); |
| 3807 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3808 | testSimplify(reporter, path, filename); |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 3809 | } |
| 3810 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3811 | static void skphealth_com76(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 07e97fc | 2013-07-08 17:17:02 +0000 | [diff] [blame] | 3812 | SkPath path; |
| 3813 | path.setFillType(SkPath::kWinding_FillType); |
| 3814 | path.moveTo(708.099182f, 7.09919119f); |
| 3815 | path.lineTo(708.099182f, 7.09920025f); |
| 3816 | path.quadTo(704.000000f, 11.2010098f, 704.000000f, 17.0000000f); |
| 3817 | path.lineTo(704.000000f, 33.0000000f); |
| 3818 | path.lineTo(705.000000f, 33.0000000f); |
| 3819 | path.lineTo(705.000000f, 17.0000000f); |
| 3820 | path.cubicTo(705.000000f, 13.4101496f, 706.455078f, 10.1601505f, 708.807617f, 7.80761385f); |
| 3821 | path.lineTo(708.099182f, 7.09919119f); |
| 3822 | path.close(); |
| 3823 | path.moveTo(704.000000f, 3.00000000f); |
| 3824 | path.lineTo(704.000000f, 33.0000000f); |
| 3825 | path.lineTo(705.000000f, 33.0000000f); |
| 3826 | path.lineTo(719.500000f, 3.00000000f); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3827 | testSimplify(reporter, path, filename); |
caryclark@google.com | 07e97fc | 2013-07-08 17:17:02 +0000 | [diff] [blame] | 3828 | } |
| 3829 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3830 | static void tooCloseTest(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3831 | SkPath path; |
| 3832 | path.moveTo(0, 0); |
| 3833 | path.lineTo(1, 1); |
| 3834 | path.lineTo(1,-1); |
| 3835 | path.close(); |
| 3836 | path.moveTo(0, 0); |
| 3837 | path.lineTo(1,-2); |
| 3838 | path.lineTo(1, 2); |
| 3839 | path.lineTo(2, 0); |
| 3840 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3841 | testSimplify(reporter, path, filename); |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3842 | } |
| 3843 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3844 | static void testRect1(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3845 | SkPath path; |
| 3846 | path.addRect(0, 0, 60, 60, SkPath::kCCW_Direction); |
| 3847 | path.addRect(30, 20, 50, 50, SkPath::kCCW_Direction); |
| 3848 | path.addRect(24, 20, 36, 30, SkPath::kCCW_Direction); |
| 3849 | path.addRect(32, 24, 36, 41, SkPath::kCCW_Direction); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3850 | testSimplify(reporter, path, filename); |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3851 | } |
| 3852 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3853 | static void testRect2(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3854 | SkPath path; |
| 3855 | path.setFillType(SkPath::kWinding_FillType); |
| 3856 | path.moveTo(0, 0); |
| 3857 | path.lineTo(60, 0); |
| 3858 | path.lineTo(60, 60); |
| 3859 | path.lineTo(0, 60); |
| 3860 | path.close(); |
| 3861 | path.moveTo(30, 20); |
| 3862 | path.lineTo(30, 50); |
| 3863 | path.lineTo(50, 50); |
| 3864 | path.lineTo(50, 20); |
| 3865 | path.close(); |
| 3866 | path.moveTo(24, 20); |
| 3867 | path.lineTo(24, 30); |
| 3868 | path.lineTo(36, 30); |
| 3869 | path.lineTo(36, 20); |
| 3870 | path.close(); |
| 3871 | path.moveTo(32, 24); |
| 3872 | path.lineTo(32, 41); |
| 3873 | path.lineTo(36, 41); |
| 3874 | path.lineTo(36, 24); |
| 3875 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3876 | testSimplify(reporter, path, filename); |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3877 | } |
| 3878 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3879 | static void testTriangles3x(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3880 | SkPath path; |
| 3881 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3882 | path.moveTo(1, 0); |
| 3883 | path.quadTo(0, 1, 3, 2); |
| 3884 | path.lineTo(1, 3); |
| 3885 | path.close(); |
| 3886 | path.moveTo(0, 0); |
| 3887 | path.lineTo(1, 1); |
| 3888 | path.quadTo(2, 1, 0, 2); |
| 3889 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3890 | testSimplify(reporter, path, filename); |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3891 | } |
| 3892 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3893 | static void testQuad8(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3894 | SkPath path; |
| 3895 | path.moveTo(3, 0); |
| 3896 | path.quadTo(0, 1, 3, 2); |
| 3897 | path.lineTo(0, 3); |
| 3898 | path.close(); |
| 3899 | path.moveTo(1, 0); |
| 3900 | path.lineTo(3, 0); |
| 3901 | path.quadTo(1, 1, 2, 2); |
| 3902 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3903 | testSimplify(reporter, path, filename); |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 3904 | } |
| 3905 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3906 | static void testTriangles4x(skiatest::Reporter* reporter, const char* filename) { |
skia.committer@gmail.com | b0a0589 | 2013-10-03 07:01:37 +0000 | [diff] [blame] | 3907 | SkPath path; |
| 3908 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3909 | path.moveTo(0, 0); |
| 3910 | path.quadTo(2, 0, 0, 3); |
| 3911 | path.lineTo(2, 3); |
| 3912 | path.close(); |
| 3913 | path.moveTo(0, 0); |
| 3914 | path.lineTo(0, 1); |
| 3915 | path.quadTo(3, 2, 2, 3); |
| 3916 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3917 | testSimplify(reporter, path, filename); |
caryclark@google.com | 7eaa53d | 2013-10-02 14:49:34 +0000 | [diff] [blame] | 3918 | } |
| 3919 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3920 | static void testQuad9(skiatest::Reporter* reporter, const char* filename) { |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 3921 | SkPath path; |
| 3922 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3923 | path.moveTo(1, 0); |
| 3924 | path.quadTo(0, 1, 3, 2); |
| 3925 | path.lineTo(1, 3); |
| 3926 | path.close(); |
| 3927 | path.moveTo(1, 0); |
| 3928 | path.lineTo(1, 1); |
| 3929 | path.quadTo(2, 1, 1, 3); |
| 3930 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3931 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 3932 | } |
| 3933 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3934 | static void testQuad10(skiatest::Reporter* reporter, const char* filename) { |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 3935 | SkPath path; |
| 3936 | path.moveTo(1, 0); |
| 3937 | path.quadTo(0, 1, 3, 2); |
| 3938 | path.lineTo(3, 3); |
| 3939 | path.close(); |
| 3940 | path.moveTo(1, 0); |
| 3941 | path.lineTo(2, 0); |
| 3942 | path.quadTo(2, 3, 3, 3); |
| 3943 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3944 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 3945 | } |
| 3946 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3947 | static void testQuad11(skiatest::Reporter* reporter, const char* filename) { |
caryclark@google.com | 28d219c | 2013-11-25 13:39:12 +0000 | [diff] [blame] | 3948 | SkPath path; |
skia.committer@gmail.com | ec18ce7 | 2013-11-26 07:02:21 +0000 | [diff] [blame] | 3949 | path.moveTo(2, 0); |
| 3950 | path.quadTo(0, 1, 1, 2); |
| 3951 | path.lineTo(1, 2); |
| 3952 | path.close(); |
| 3953 | path.moveTo(0, 0); |
| 3954 | path.lineTo(1, 1); |
| 3955 | path.quadTo(1, 3, 3, 3); |
| 3956 | path.close(); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3957 | testSimplify(reporter, path, filename); |
skia.committer@gmail.com | ec18ce7 | 2013-11-26 07:02:21 +0000 | [diff] [blame] | 3958 | } |
caryclark@google.com | 28d219c | 2013-11-25 13:39:12 +0000 | [diff] [blame] | 3959 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 3960 | static void testQuad12(skiatest::Reporter* reporter, const char* filename) { |
| 3961 | SkPath path; |
| 3962 | path.moveTo(0, 0); |
| 3963 | path.quadTo(0, 0, 0, 0); |
| 3964 | path.lineTo(0, 1); |
| 3965 | path.close(); |
| 3966 | path.moveTo(0, 0); |
| 3967 | path.lineTo(0, 0); |
| 3968 | path.quadTo(1, 0, 0, 1); |
| 3969 | path.close(); |
| 3970 | testSimplify(reporter, path, filename); |
| 3971 | } |
| 3972 | |
| 3973 | static void testQuadralateral3(skiatest::Reporter* reporter, const char* filename) { |
| 3974 | SkPath path; |
| 3975 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 3976 | path.moveTo(0, 0); |
| 3977 | path.lineTo(0, 0); |
| 3978 | path.lineTo(0, 0); |
| 3979 | path.lineTo(1, 0); |
| 3980 | path.close(); |
| 3981 | path.moveTo(0, 0); |
| 3982 | path.lineTo(0, 0); |
| 3983 | path.lineTo(1, 0); |
| 3984 | path.lineTo(0, 1); |
| 3985 | path.close(); |
| 3986 | testSimplify(reporter, path, filename); |
| 3987 | } |
| 3988 | |
| 3989 | |
| 3990 | static void testDegenerate5(skiatest::Reporter* reporter, const char* filename) { |
| 3991 | SkPath path; |
| 3992 | path.moveTo(0, 0); |
| 3993 | path.lineTo(0, 0); |
| 3994 | path.lineTo(1, 0); |
| 3995 | path.close(); |
| 3996 | path.moveTo(0, 0); |
| 3997 | path.lineTo(1, 0); |
| 3998 | path.lineTo(0, 1); |
| 3999 | path.close(); |
| 4000 | testSimplify(reporter, path, filename); |
| 4001 | } |
| 4002 | |
| 4003 | static void testQuadralateral4(skiatest::Reporter* reporter, const char* filename) { |
| 4004 | SkPath path; |
| 4005 | path.moveTo(0, 0); |
| 4006 | path.lineTo(0, 0); |
| 4007 | path.lineTo(0, 0); |
| 4008 | path.lineTo(3, 1); |
| 4009 | path.close(); |
| 4010 | path.moveTo(0, 0); |
| 4011 | path.lineTo(0, 0); |
| 4012 | path.lineTo(0, 1); |
| 4013 | path.lineTo(3, 1); |
| 4014 | path.close(); |
| 4015 | testSimplify(reporter, path, filename); |
| 4016 | } |
| 4017 | |
| 4018 | static void testDegenerates1(skiatest::Reporter* reporter, const char* filename) { |
| 4019 | SkPath path; |
| 4020 | path.moveTo(0, 0); |
| 4021 | path.quadTo(0, 0, 1, 1); |
| 4022 | path.lineTo(2, 3); |
| 4023 | path.close(); |
| 4024 | path.moveTo(0, 0); |
| 4025 | path.lineTo(0, 0); |
| 4026 | path.quadTo(3, 2, 2, 3); |
| 4027 | path.close(); |
| 4028 | testSimplify(reporter, path, filename); |
| 4029 | } |
| 4030 | |
| 4031 | static void testQuad13(skiatest::Reporter* reporter, const char* filename) { |
| 4032 | SkPath path; |
| 4033 | path.moveTo(0, 0); |
| 4034 | path.quadTo(0, 0, 1, 1); |
| 4035 | path.lineTo(2, 3); |
| 4036 | path.close(); |
| 4037 | path.moveTo(0, 0); |
| 4038 | path.lineTo(0, 0); |
| 4039 | path.quadTo(3, 2, 2, 3); |
| 4040 | path.close(); |
| 4041 | testSimplify(reporter, path, filename); |
| 4042 | } |
| 4043 | |
| 4044 | static void testQuad14(skiatest::Reporter* reporter, const char* filename) { |
| 4045 | SkPath path; |
| 4046 | path.setFillType(SkPath::kWinding_FillType); |
| 4047 | path.moveTo(0, 0); |
| 4048 | path.quadTo(0, 0, 1, 1); |
| 4049 | path.lineTo(1, 2); |
| 4050 | path.close(); |
| 4051 | path.moveTo(0, 0); |
| 4052 | path.lineTo(0, 0); |
| 4053 | path.quadTo(3, 1, 1, 3); |
| 4054 | path.close(); |
| 4055 | testSimplify(reporter, path, filename); |
| 4056 | } |
| 4057 | |
| 4058 | static void testQuad15(skiatest::Reporter* reporter, const char* filename) { |
| 4059 | SkPath path; |
| 4060 | path.moveTo(0, 0); |
| 4061 | path.quadTo(0, 0, 1, 1); |
| 4062 | path.lineTo(1, 3); |
| 4063 | path.close(); |
| 4064 | path.moveTo(0, 0); |
| 4065 | path.lineTo(0, 0); |
| 4066 | path.quadTo(2, 0, 1, 3); |
| 4067 | path.close(); |
| 4068 | testSimplify(reporter, path, filename); |
| 4069 | } |
| 4070 | |
| 4071 | static void testQuads16(skiatest::Reporter* reporter, const char* filename) { |
| 4072 | SkPath path; |
| 4073 | path.moveTo(0, 0); |
| 4074 | path.quadTo(0, 0, 1, 1); |
| 4075 | path.lineTo(3, 2); |
| 4076 | path.close(); |
| 4077 | path.moveTo(0, 0); |
| 4078 | path.lineTo(0, 0); |
| 4079 | path.quadTo(0, 1, 3, 2); |
| 4080 | path.close(); |
| 4081 | testSimplify(reporter, path, filename); |
| 4082 | } |
| 4083 | |
| 4084 | static void testQuads17(skiatest::Reporter* reporter, const char* filename) { |
| 4085 | SkPath path; |
| 4086 | path.moveTo(0, 0); |
| 4087 | path.quadTo(0, 0, 1, 1); |
| 4088 | path.lineTo(3, 2); |
| 4089 | path.close(); |
| 4090 | path.moveTo(0, 0); |
| 4091 | path.lineTo(0, 0); |
| 4092 | path.quadTo(0, 2, 3, 2); |
| 4093 | path.close(); |
| 4094 | testSimplify(reporter, path, filename); |
| 4095 | } |
| 4096 | |
| 4097 | static void testQuads18(skiatest::Reporter* reporter, const char* filename) { |
| 4098 | SkPath path; |
| 4099 | path.moveTo(0, 0); |
| 4100 | path.quadTo(0, 0, 1, 1); |
| 4101 | path.lineTo(3, 2); |
| 4102 | path.close(); |
| 4103 | path.moveTo(0, 0); |
| 4104 | path.lineTo(0, 0); |
| 4105 | path.quadTo(1, 2, 3, 2); |
| 4106 | path.close(); |
| 4107 | testSimplify(reporter, path, filename); |
| 4108 | } |
| 4109 | |
| 4110 | static void testQuads19(skiatest::Reporter* reporter, const char* filename) { |
| 4111 | SkPath path; |
| 4112 | path.moveTo(0, 0); |
| 4113 | path.quadTo(0, 0, 2, 1); |
| 4114 | path.lineTo(1, 2); |
| 4115 | path.close(); |
| 4116 | path.moveTo(0, 0); |
| 4117 | path.lineTo(0, 0); |
| 4118 | path.quadTo(2, 1, 1, 2); |
| 4119 | path.close(); |
| 4120 | testSimplify(reporter, path, filename); |
| 4121 | } |
| 4122 | |
| 4123 | static void testQuads20(skiatest::Reporter* reporter, const char* filename) { |
| 4124 | SkPath path; |
| 4125 | path.moveTo(0, 0); |
| 4126 | path.quadTo(0, 0, 2, 1); |
| 4127 | path.lineTo(1, 3); |
| 4128 | path.close(); |
| 4129 | path.moveTo(0, 0); |
| 4130 | path.lineTo(0, 0); |
| 4131 | path.quadTo(2, 1, 1, 3); |
| 4132 | path.close(); |
| 4133 | testSimplify(reporter, path, filename); |
| 4134 | } |
| 4135 | |
| 4136 | static void testQuads21(skiatest::Reporter* reporter, const char* filename) { |
| 4137 | SkPath path; |
| 4138 | path.moveTo(0, 0); |
| 4139 | path.quadTo(0, 0, 1, 1); |
| 4140 | path.lineTo(2, 1); |
| 4141 | path.close(); |
| 4142 | path.moveTo(0, 0); |
| 4143 | path.lineTo(0, 0); |
| 4144 | path.quadTo(3, 0, 2, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4145 | path.close(); |
| 4146 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4147 | } |
| 4148 | |
| 4149 | static void testQuads22(skiatest::Reporter* reporter, const char* filename) { |
| 4150 | SkPath path; |
| 4151 | path.moveTo(0, 0); |
| 4152 | path.quadTo(0, 0, 2, 0); |
| 4153 | path.lineTo(1, 1); |
| 4154 | path.close(); |
| 4155 | path.moveTo(0, 0); |
| 4156 | path.lineTo(0, 0); |
| 4157 | path.quadTo(0, 1, 3, 2); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4158 | path.close(); |
| 4159 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4160 | } |
| 4161 | |
| 4162 | static void testQuads23(skiatest::Reporter* reporter, const char* filename) { |
| 4163 | SkPath path; |
| 4164 | path.moveTo(0, 0); |
| 4165 | path.quadTo(0, 0, 1, 0); |
| 4166 | path.lineTo(1, 1); |
| 4167 | path.close(); |
| 4168 | path.moveTo(0, 0); |
| 4169 | path.lineTo(0, 0); |
| 4170 | path.quadTo(0, 1, 3, 2); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4171 | path.close(); |
| 4172 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4173 | } |
| 4174 | |
| 4175 | static void testQuads24(skiatest::Reporter* reporter, const char* filename) { |
| 4176 | SkPath path; |
| 4177 | path.moveTo(0, 0); |
| 4178 | path.quadTo(0, 0, 0, 1); |
| 4179 | path.lineTo(1, 2); |
| 4180 | path.close(); |
| 4181 | path.moveTo(0, 1); |
| 4182 | path.lineTo(0, 1); |
| 4183 | path.quadTo(0, 2, 3, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4184 | path.close(); |
| 4185 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4186 | } |
| 4187 | |
| 4188 | static void testQuads25(skiatest::Reporter* reporter, const char* filename) { |
| 4189 | SkPath path; |
| 4190 | path.moveTo(0, 0); |
| 4191 | path.quadTo(0, 0, 0, 1); |
| 4192 | path.lineTo(2, 1); |
| 4193 | path.close(); |
| 4194 | path.moveTo(0, 0); |
| 4195 | path.lineTo(0, 0); |
| 4196 | path.quadTo(3, 0, 2, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4197 | path.close(); |
| 4198 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4199 | } |
| 4200 | |
| 4201 | static void testQuads26(skiatest::Reporter* reporter, const char* filename) { |
| 4202 | SkPath path; |
| 4203 | path.moveTo(0, 0); |
| 4204 | path.quadTo(0, 0, 3, 0); |
| 4205 | path.lineTo(1, 1); |
| 4206 | path.close(); |
| 4207 | path.moveTo(0, 0); |
| 4208 | path.lineTo(0, 0); |
| 4209 | path.quadTo(0, 1, 3, 2); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4210 | path.close(); |
| 4211 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4212 | } |
| 4213 | |
| 4214 | static void testQuads27(skiatest::Reporter* reporter, const char* filename) { |
| 4215 | SkPath path; |
| 4216 | path.moveTo(0, 0); |
| 4217 | path.quadTo(0, 0, 2, 0); |
| 4218 | path.lineTo(2, 1); |
| 4219 | path.close(); |
| 4220 | path.moveTo(2, 0); |
| 4221 | path.lineTo(2, 0); |
| 4222 | path.quadTo(3, 0, 1, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4223 | path.close(); |
| 4224 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4225 | } |
| 4226 | |
| 4227 | static void testQuads28(skiatest::Reporter* reporter, const char* filename) { |
| 4228 | SkPath path; |
| 4229 | path.moveTo(0, 0); |
| 4230 | path.quadTo(0, 0, 0, 1); |
| 4231 | path.lineTo(2, 2); |
| 4232 | path.close(); |
| 4233 | path.moveTo(0, 0); |
| 4234 | path.lineTo(0, 0); |
| 4235 | path.quadTo(3, 0, 2, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4236 | path.close(); |
| 4237 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4238 | } |
| 4239 | |
| 4240 | static void testQuads29(skiatest::Reporter* reporter, const char* filename) { |
| 4241 | SkPath path; |
| 4242 | path.moveTo(0, 0); |
| 4243 | path.quadTo(0, 0, 3, 0); |
| 4244 | path.lineTo(2, 1); |
| 4245 | path.close(); |
| 4246 | path.moveTo(3, 0); |
| 4247 | path.lineTo(3, 0); |
| 4248 | path.quadTo(3, 1, 0, 2); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4249 | path.close(); |
| 4250 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4251 | } |
| 4252 | |
| 4253 | static void testQuads30(skiatest::Reporter* reporter, const char* filename) { |
| 4254 | SkPath path; |
| 4255 | path.moveTo(0, 0); |
| 4256 | |
| 4257 | path.quadTo(0, 0, 2, 0); |
| 4258 | path.lineTo(2, 2); |
| 4259 | path.close(); |
| 4260 | path.moveTo(2, 0); |
| 4261 | path.lineTo(2, 0); |
| 4262 | path.quadTo(3, 2, 1, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4263 | path.close(); |
| 4264 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4265 | } |
| 4266 | |
| 4267 | static void testQuads31(skiatest::Reporter* reporter, const char* filename) { |
| 4268 | SkPath path; |
| 4269 | path.moveTo(0, 0); |
| 4270 | path.quadTo(0, 0, 2, 1); |
| 4271 | path.lineTo(1, 3); |
| 4272 | path.close(); |
| 4273 | path.moveTo(3, 0); |
| 4274 | path.lineTo(0, 1); |
| 4275 | |
| 4276 | path.quadTo(2, 1, 1, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4277 | path.close(); |
| 4278 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4279 | } |
| 4280 | |
| 4281 | static void testQuads32(skiatest::Reporter* reporter, const char* filename) { |
| 4282 | SkPath path; |
| 4283 | path.moveTo(0, 0); |
| 4284 | path.quadTo(0, 0, 1, 1); |
| 4285 | path.lineTo(1, 2); |
| 4286 | path.close(); |
| 4287 | path.moveTo(1, 1); |
| 4288 | path.lineTo(1, 1); |
| 4289 | path.quadTo(3, 1, 0, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4290 | path.close(); |
| 4291 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4292 | } |
| 4293 | |
| 4294 | static void testQuads33(skiatest::Reporter* reporter, const char* filename) { |
| 4295 | SkPath path; |
| 4296 | path.moveTo(0, 0); |
| 4297 | path.quadTo(0, 0, 1, 1); |
| 4298 | path.lineTo(2, 1); |
| 4299 | path.close(); |
| 4300 | path.moveTo(0, 0); |
| 4301 | path.lineTo(0, 0); |
| 4302 | path.quadTo(3, 0, 2, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4303 | path.close(); |
| 4304 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4305 | } |
| 4306 | |
| 4307 | static void testQuads34(skiatest::Reporter* reporter, const char* filename) { |
| 4308 | SkPath path; |
| 4309 | path.moveTo(0, 0); |
| 4310 | path.quadTo(0, 0, 1, 0); |
| 4311 | path.lineTo(2, 1); |
| 4312 | path.close(); |
| 4313 | path.moveTo(1, 0); |
| 4314 | path.lineTo(1, 0); |
| 4315 | path.quadTo(2, 0, 3, 3); |
skia.committer@gmail.com | a1ed7ae | 2014-04-15 03:04:18 +0000 | [diff] [blame] | 4316 | path.close(); |
| 4317 | testSimplify(reporter, path, filename); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4318 | } |
| 4319 | |
| 4320 | static void testQuads35(skiatest::Reporter* reporter, const char* filename) { |
| 4321 | SkPath path; |
| 4322 | path.moveTo(0, 0); |
| 4323 | path.quadTo(0, 0, 1, 0); |
| 4324 | path.lineTo(1, 2); |
| 4325 | path.close(); |
| 4326 | path.moveTo(1, 0); |
| 4327 | path.lineTo(1, 0); |
| 4328 | path.quadTo(3, 1, 0, 3); |
| 4329 | path.close(); |
| 4330 | testSimplify(reporter, path, filename); |
| 4331 | } |
| 4332 | |
| 4333 | static void testQuads36(skiatest::Reporter* reporter, const char* filename) { |
| 4334 | SkPath path; |
| 4335 | path.moveTo(1, 0); |
| 4336 | path.quadTo(2, 0, 1, 2); |
| 4337 | path.lineTo(2, 2); |
| 4338 | path.close(); |
| 4339 | path.moveTo(1, 0); |
| 4340 | path.lineTo(1, 0); |
| 4341 | path.quadTo(3, 0, 2, 3); |
| 4342 | path.close(); |
| 4343 | testSimplify(reporter, path, filename); |
| 4344 | } |
| 4345 | |
| 4346 | static void testQuads37(skiatest::Reporter* reporter, const char* filename) { |
| 4347 | SkPath path; |
| 4348 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 4349 | path.moveTo(1, 0); |
| 4350 | path.quadTo(2, 0, 1, 2); |
| 4351 | path.lineTo(2, 2); |
| 4352 | path.close(); |
| 4353 | path.moveTo(1, 0); |
| 4354 | path.lineTo(1, 0); |
| 4355 | path.quadTo(3, 0, 2, 3); |
| 4356 | path.close(); |
| 4357 | testSimplify(reporter, path, filename); |
| 4358 | } |
| 4359 | |
| 4360 | static void testQuads38(skiatest::Reporter* reporter, const char* filename) { |
| 4361 | SkPath path; |
| 4362 | path.moveTo(1, 0); |
| 4363 | path.quadTo(3, 0, 0, 2); |
| 4364 | path.lineTo(3, 2); |
| 4365 | path.close(); |
| 4366 | path.moveTo(1, 0); |
| 4367 | path.lineTo(1, 0); |
| 4368 | path.quadTo(2, 1, 3, 1); |
| 4369 | path.close(); |
| 4370 | testSimplify(reporter, path, filename); |
| 4371 | } |
| 4372 | |
| 4373 | static void testQuads39(skiatest::Reporter* reporter, const char* filename) { |
| 4374 | SkPath path; |
| 4375 | path.moveTo(1, 0); |
| 4376 | path.quadTo(3, 0, 0, 3); |
| 4377 | path.lineTo(0, 3); |
| 4378 | path.close(); |
| 4379 | path.moveTo(1, 1); |
| 4380 | path.lineTo(0, 2); |
| 4381 | path.quadTo(1, 2, 0, 3); |
| 4382 | path.close(); |
| 4383 | testSimplify(reporter, path, filename); |
| 4384 | } |
| 4385 | static void testQuads40(skiatest::Reporter* reporter, const char* filename) { |
| 4386 | SkPath path; |
| 4387 | path.moveTo(1, 0); |
| 4388 | path.quadTo(3, 0, 3, 3); |
| 4389 | path.lineTo(3, 3); |
| 4390 | path.close(); |
| 4391 | path.moveTo(2, 1); |
| 4392 | path.lineTo(2, 2); |
| 4393 | path.quadTo(3, 2, 3, 3); |
| 4394 | path.close(); |
| 4395 | testSimplify(reporter, path, filename); |
| 4396 | } |
| 4397 | |
| 4398 | static void testQuads41(skiatest::Reporter* reporter, const char* filename) { |
| 4399 | SkPath path; |
| 4400 | path.moveTo(0, 0); |
| 4401 | path.quadTo(0, 0, 1, 0); |
| 4402 | path.lineTo(2, 1); |
| 4403 | path.close(); |
| 4404 | path.moveTo(0, 0); |
| 4405 | path.lineTo(0, 0); |
| 4406 | path.quadTo(0, 1, 1, 2); |
| 4407 | path.close(); |
| 4408 | testSimplify(reporter, path, filename); |
| 4409 | } |
| 4410 | |
| 4411 | |
| 4412 | static void testQuads54(skiatest::Reporter* reporter, const char* filename) { |
| 4413 | SkPath path; |
| 4414 | path.moveTo(1, 0); |
| 4415 | path.quadTo(2, 0, 1, 1); |
| 4416 | path.lineTo(3, 1); |
| 4417 | path.close(); |
| 4418 | path.moveTo(2, 0); |
| 4419 | path.lineTo(1, 1); |
| 4420 | path.quadTo(1, 1, 2, 3); |
| 4421 | path.close(); |
| 4422 | testSimplify(reporter, path, filename); |
| 4423 | } |
| 4424 | static void testQuads53(skiatest::Reporter* reporter, const char* filename) { |
| 4425 | SkPath path; |
| 4426 | path.moveTo(1, 0); |
| 4427 | path.quadTo(2, 0, 1, 1); |
| 4428 | path.lineTo(3, 1); |
| 4429 | path.close(); |
| 4430 | path.moveTo(2, 0); |
| 4431 | path.lineTo(1, 1); |
| 4432 | path.quadTo(2, 3, 2, 3); |
| 4433 | path.close(); |
| 4434 | testSimplify(reporter, path, filename); |
| 4435 | } |
| 4436 | static void testQuads52(skiatest::Reporter* reporter, const char* filename) { |
| 4437 | SkPath path; |
| 4438 | path.moveTo(1, 0); |
| 4439 | path.quadTo(2, 0, 1, 1); |
| 4440 | path.lineTo(3, 1); |
| 4441 | path.close(); |
| 4442 | path.moveTo(2, 0); |
| 4443 | path.lineTo(1, 1); |
| 4444 | path.quadTo(2, 3, 3, 3); |
| 4445 | path.close(); |
| 4446 | testSimplify(reporter, path, filename); |
| 4447 | } |
| 4448 | static void testQuads51(skiatest::Reporter* reporter, const char* filename) { |
| 4449 | SkPath path; |
| 4450 | path.moveTo(2, 0); |
| 4451 | path.quadTo(3, 0, 2, 1); |
| 4452 | path.lineTo(3, 2); |
| 4453 | path.close(); |
| 4454 | path.moveTo(3, 0); |
| 4455 | path.lineTo(3, 1); |
| 4456 | path.quadTo(3, 1, 1, 2); |
| 4457 | path.close(); |
| 4458 | testSimplify(reporter, path, filename); |
| 4459 | } |
| 4460 | static void testQuads50(skiatest::Reporter* reporter, const char* filename) { |
| 4461 | SkPath path; |
| 4462 | path.moveTo(2, 0); |
| 4463 | path.quadTo(3, 0, 2, 1); |
| 4464 | path.lineTo(3, 2); |
| 4465 | path.close(); |
| 4466 | path.moveTo(3, 0); |
| 4467 | path.lineTo(3, 1); |
| 4468 | path.quadTo(1, 2, 1, 2); |
| 4469 | path.close(); |
| 4470 | testSimplify(reporter, path, filename); |
| 4471 | } |
| 4472 | static void testQuads49(skiatest::Reporter* reporter, const char* filename) { |
| 4473 | SkPath path; |
| 4474 | path.moveTo(2, 0); |
| 4475 | path.quadTo(3, 0, 2, 1); |
| 4476 | path.lineTo(3, 2); |
| 4477 | path.close(); |
| 4478 | path.moveTo(3, 0); |
| 4479 | path.lineTo(2, 2); |
| 4480 | path.quadTo(2, 2, 0, 3); |
| 4481 | path.close(); |
| 4482 | testSimplify(reporter, path, filename); |
| 4483 | } |
| 4484 | static void testQuads48(skiatest::Reporter* reporter, const char* filename) { |
| 4485 | SkPath path; |
| 4486 | path.moveTo(2, 0); |
| 4487 | path.quadTo(3, 0, 2, 1); |
| 4488 | path.lineTo(3, 2); |
| 4489 | path.close(); |
| 4490 | path.moveTo(3, 0); |
| 4491 | path.lineTo(2, 2); |
| 4492 | path.quadTo(3, 2, 0, 3); |
| 4493 | path.close(); |
| 4494 | testSimplify(reporter, path, filename); |
| 4495 | } |
| 4496 | static void testQuads47(skiatest::Reporter* reporter, const char* filename) { |
| 4497 | SkPath path; |
| 4498 | path.moveTo(2, 0); |
| 4499 | path.quadTo(3, 0, 2, 1); |
| 4500 | path.lineTo(3, 2); |
| 4501 | path.close(); |
| 4502 | path.moveTo(3, 0); |
| 4503 | path.lineTo(2, 2); |
| 4504 | path.quadTo(0, 3, 0, 3); |
| 4505 | path.close(); |
| 4506 | testSimplify(reporter, path, filename); |
| 4507 | } |
| 4508 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 4509 | static void testQuads46x(skiatest::Reporter* reporter, const char* filename) { |
| 4510 | SkPath path; |
| 4511 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 4512 | path.moveTo(2, 0); |
| 4513 | path.quadTo(0, 1, 3, 2); |
| 4514 | path.lineTo(1, 3); |
| 4515 | path.close(); |
| 4516 | path.moveTo(0, 0); |
| 4517 | path.lineTo(1, 1); |
| 4518 | path.quadTo(3, 2, 1, 3); |
| 4519 | path.close(); |
| 4520 | testSimplify(reporter, path, filename); |
| 4521 | } |
| 4522 | |
| 4523 | static void testQuads45(skiatest::Reporter* reporter, const char* filename) { |
| 4524 | SkPath path; |
| 4525 | path.moveTo(2, 0); |
| 4526 | path.quadTo(3, 2, 3, 3); |
| 4527 | path.lineTo(3, 3); |
| 4528 | path.close(); |
| 4529 | path.moveTo(0, 0); |
| 4530 | path.lineTo(0, 2); |
| 4531 | path.quadTo(3, 2, 3, 3); |
| 4532 | path.close(); |
| 4533 | testSimplify(reporter, path, filename); |
| 4534 | } |
| 4535 | |
| 4536 | static void testQuads44(skiatest::Reporter* reporter, const char* filename) { |
| 4537 | SkPath path; |
| 4538 | path.moveTo(2, 0); |
| 4539 | path.quadTo(3, 2, 3, 3); |
| 4540 | path.lineTo(3, 3); |
| 4541 | path.close(); |
| 4542 | path.moveTo(1, 0); |
| 4543 | path.lineTo(0, 2); |
| 4544 | path.quadTo(3, 2, 3, 3); |
| 4545 | path.close(); |
| 4546 | testSimplify(reporter, path, filename); |
| 4547 | } |
| 4548 | |
| 4549 | static void testQuads43(skiatest::Reporter* reporter, const char* filename) { |
| 4550 | SkPath path; |
| 4551 | path.moveTo(2, 0); |
| 4552 | path.quadTo(2, 3, 3, 3); |
| 4553 | path.lineTo(3, 3); |
| 4554 | path.close(); |
| 4555 | path.moveTo(0, 2); |
| 4556 | path.lineTo(0, 2); |
| 4557 | path.quadTo(2, 3, 3, 3); |
| 4558 | path.close(); |
| 4559 | testSimplify(reporter, path, filename); |
| 4560 | } |
| 4561 | |
| 4562 | static void testQuads42(skiatest::Reporter* reporter, const char* filename) { |
| 4563 | SkPath path; |
| 4564 | path.moveTo(2, 0); |
| 4565 | path.quadTo(3, 2, 3, 3); |
| 4566 | path.lineTo(3, 3); |
| 4567 | path.close(); |
| 4568 | path.moveTo(2, 0); |
| 4569 | path.lineTo(0, 2); |
| 4570 | path.quadTo(3, 2, 3, 3); |
| 4571 | path.close(); |
| 4572 | testSimplify(reporter, path, filename); |
| 4573 | } |
| 4574 | |
| 4575 | static void testQuads56(skiatest::Reporter* reporter, const char* filename) { |
| 4576 | SkPath path; |
| 4577 | path.moveTo(2, 0); |
| 4578 | path.quadTo(3, 1, 0, 2); |
| 4579 | path.lineTo(3, 2); |
| 4580 | path.close(); |
| 4581 | path.moveTo(3, 0); |
| 4582 | path.lineTo(2, 1); |
| 4583 | path.quadTo(2, 1, 3, 3); |
| 4584 | path.close(); |
| 4585 | testSimplify(reporter, path, filename); |
| 4586 | } |
| 4587 | |
| 4588 | static void testQuads57(skiatest::Reporter* reporter, const char* filename) { |
| 4589 | SkPath path; |
| 4590 | path.moveTo(1, 0); |
| 4591 | path.quadTo(3, 0, 3, 1); |
| 4592 | path.lineTo(2, 2); |
| 4593 | path.close(); |
| 4594 | path.moveTo(2, 0); |
| 4595 | path.lineTo(3, 1); |
| 4596 | path.quadTo(2, 2, 3, 2); |
| 4597 | path.close(); |
| 4598 | testSimplify(reporter, path, filename); |
| 4599 | } |
| 4600 | |
| 4601 | static void testQuads58(skiatest::Reporter* reporter, const char* filename) { |
| 4602 | SkPath path; |
| 4603 | path.moveTo(1, 0); |
| 4604 | path.quadTo(3, 0, 3, 1); |
| 4605 | path.lineTo(1, 3); |
| 4606 | path.close(); |
| 4607 | path.moveTo(2, 0); |
| 4608 | path.lineTo(3, 1); |
| 4609 | path.quadTo(2, 2, 3, 2); |
| 4610 | path.close(); |
| 4611 | testSimplify(reporter, path, filename); |
| 4612 | } |
| 4613 | |
| 4614 | static void testQuads59(skiatest::Reporter* reporter, const char* filename) { |
| 4615 | SkPath path; |
| 4616 | path.moveTo(3, 0); |
| 4617 | path.quadTo(3, 1, 3, 1); |
| 4618 | path.lineTo(2, 2); |
| 4619 | path.close(); |
| 4620 | path.moveTo(2, 0); |
| 4621 | path.lineTo(3, 1); |
| 4622 | path.quadTo(2, 2, 3, 2); |
| 4623 | path.close(); |
| 4624 | testSimplify(reporter, path, filename); |
| 4625 | } |
| 4626 | |
| 4627 | static void testQuads60(skiatest::Reporter* reporter, const char* filename) { |
| 4628 | SkPath path; |
| 4629 | path.moveTo(2, 1); |
| 4630 | path.quadTo(0, 2, 3, 2); |
| 4631 | path.lineTo(2, 3); |
| 4632 | path.close(); |
| 4633 | path.moveTo(0, 0); |
| 4634 | path.lineTo(2, 0); |
| 4635 | path.quadTo(1, 1, 2, 2); |
| 4636 | path.close(); |
| 4637 | testSimplify(reporter, path, filename); |
| 4638 | } |
| 4639 | |
| 4640 | static void testQuads61(skiatest::Reporter* reporter, const char* filename) { |
| 4641 | SkPath path; |
| 4642 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 4643 | path.moveTo(0, 0); |
| 4644 | path.quadTo(0, 0, 2, 0); |
| 4645 | path.lineTo(1, 1); |
| 4646 | path.close(); |
| 4647 | path.moveTo(0, 0); |
| 4648 | path.lineTo(0, 0); |
| 4649 | path.quadTo(1, 0, 2, 2); |
| 4650 | path.close(); |
| 4651 | testSimplify(reporter, path, filename); |
| 4652 | } |
| 4653 | |
caryclark | dac1d17 | 2014-06-17 05:15:38 -0700 | [diff] [blame] | 4654 | static void testQuadralateral10(skiatest::Reporter* reporter, const char* filename) { |
| 4655 | SkPath path; |
| 4656 | path.setFillType(SkPath::kWinding_FillType); |
| 4657 | path.moveTo(0, 0); |
| 4658 | path.lineTo(0, 0); |
| 4659 | path.lineTo(0, 0); |
| 4660 | path.lineTo(2, 2); |
| 4661 | path.close(); |
| 4662 | path.moveTo(1, 0); |
| 4663 | path.lineTo(1, 1); |
| 4664 | path.lineTo(2, 2); |
| 4665 | path.lineTo(1, 3); |
| 4666 | path.close(); |
| 4667 | testSimplify(reporter, path, filename); |
| 4668 | } |
| 4669 | |
caryclark | 19eb3b2 | 2014-07-18 05:08:14 -0700 | [diff] [blame] | 4670 | static void testRect3(skiatest::Reporter* reporter, const char* filename) { |
| 4671 | SkPath path; |
| 4672 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 4673 | path.addRect(0, 0, 60, 60, SkPath::kCCW_Direction); |
| 4674 | path.addRect(10, 30, 40, 30, SkPath::kCCW_Direction); |
| 4675 | path.addRect(24, 6, 36, 36, SkPath::kCCW_Direction); |
| 4676 | path.addRect(32, 6, 36, 41, SkPath::kCCW_Direction); |
| 4677 | testSimplify(reporter, path, filename); |
| 4678 | } |
| 4679 | |
caryclark | 1049f12 | 2015-04-20 08:31:59 -0700 | [diff] [blame] | 4680 | static void testRect4(skiatest::Reporter* reporter, const char* filename) { |
| 4681 | SkPath path; |
| 4682 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 4683 | path.addRect(0, 0, 30, 60, SkPath::kCCW_Direction); |
| 4684 | path.addRect(10, 0, 40, 30, SkPath::kCCW_Direction); |
| 4685 | path.addRect(20, 0, 30, 40, SkPath::kCCW_Direction); |
| 4686 | path.addRect(32, 0, 36, 41, SkPath::kCCW_Direction); |
| 4687 | testSimplify(reporter, path, filename); |
| 4688 | } |
| 4689 | |
| 4690 | static void testQuads62(skiatest::Reporter* reporter, const char* filename) { |
| 4691 | SkPath path; |
| 4692 | path.moveTo(3, 2); |
| 4693 | path.quadTo(1, 3, 3, 3); |
| 4694 | path.lineTo(3, 3); |
| 4695 | path.close(); |
| 4696 | path.moveTo(0, 0); |
| 4697 | path.lineTo(2, 0); |
| 4698 | path.quadTo(1, 3, 3, 3); |
| 4699 | path.close(); |
| 4700 | testSimplify(reporter, path, filename); |
| 4701 | } |
| 4702 | |
| 4703 | static void testQuads63(skiatest::Reporter* reporter,const char* filename) { |
| 4704 | SkPath path; |
| 4705 | path.moveTo(3, 0); |
| 4706 | path.quadTo(0, 1, 1, 2); |
| 4707 | path.lineTo(3, 3); |
| 4708 | path.close(); |
| 4709 | path.moveTo(0, 0); |
| 4710 | path.lineTo(1, 1); |
| 4711 | path.quadTo(0, 2, 3, 3); |
| 4712 | path.close(); |
| 4713 | testSimplify(reporter, path, filename); |
| 4714 | } |
| 4715 | |
| 4716 | static void testQuads64(skiatest::Reporter* reporter,const char* filename) { |
| 4717 | SkPath path; |
| 4718 | path.moveTo(3, 0); |
| 4719 | path.quadTo(0, 1, 1, 2); |
| 4720 | path.lineTo(2, 2); |
| 4721 | path.close(); |
| 4722 | path.moveTo(1, 0); |
| 4723 | path.lineTo(1, 1); |
| 4724 | path.quadTo(0, 2, 3, 3); |
| 4725 | path.close(); |
| 4726 | testSimplify(reporter, path, filename); |
| 4727 | } |
| 4728 | |
caryclark | 624637c | 2015-05-11 07:21:27 -0700 | [diff] [blame] | 4729 | static void testTriangle1(skiatest::Reporter* reporter,const char* filename) { |
| 4730 | SkPath path; |
| 4731 | path.moveTo(0, 0); |
| 4732 | path.lineTo(1, 0); |
| 4733 | path.lineTo(2, 3); |
| 4734 | path.close(); |
| 4735 | path.moveTo(0, 0); |
| 4736 | path.lineTo(1, 2); |
| 4737 | path.lineTo(1, 0); |
| 4738 | path.close(); |
| 4739 | testSimplify(reporter, path, filename); |
| 4740 | } |
| 4741 | |
| 4742 | static void testTriangle2(skiatest::Reporter* reporter,const char* filename) { |
| 4743 | SkPath path; |
| 4744 | path.moveTo(0, 0); |
| 4745 | path.lineTo(1, 0); |
| 4746 | path.lineTo(0, 1); |
| 4747 | path.close(); |
| 4748 | path.moveTo(2, 0); |
| 4749 | path.lineTo(0, 2); |
| 4750 | path.lineTo(2, 2); |
| 4751 | path.close(); |
| 4752 | testSimplify(reporter, path, filename); |
| 4753 | } |
| 4754 | |
caryclark | bca19f7 | 2015-05-13 08:23:48 -0700 | [diff] [blame] | 4755 | static void testArc(skiatest::Reporter* reporter,const char* filename) { |
| 4756 | SkRect r = SkRect::MakeWH(150, 100); |
| 4757 | SkPath path; |
| 4758 | path.arcTo(r, 0, 0.0025f, false); |
| 4759 | testSimplify(reporter, path, filename); |
| 4760 | } |
| 4761 | |
caryclark | fba9da7 | 2015-05-14 14:18:13 -0700 | [diff] [blame] | 4762 | static void testIssue3838(skiatest::Reporter* reporter,const char* filename) { |
| 4763 | SkPath path; |
| 4764 | path.moveTo(220, 170); |
| 4765 | path.lineTo(200, 170); |
| 4766 | path.lineTo(200, 190); |
| 4767 | path.lineTo(180, 190); |
| 4768 | path.lineTo(180, 210); |
| 4769 | path.lineTo(200, 210); |
| 4770 | path.lineTo(200, 250); |
| 4771 | path.lineTo(260, 250); |
| 4772 | path.lineTo(260, 190); |
| 4773 | path.lineTo(220, 190); |
| 4774 | path.lineTo(220, 170); |
| 4775 | path.close(); |
| 4776 | path.moveTo(220, 210); |
| 4777 | path.lineTo(220, 230); |
| 4778 | path.lineTo(240, 230); |
| 4779 | path.lineTo(240, 210); |
| 4780 | path.lineTo(220, 210); |
| 4781 | path.close(); |
| 4782 | testSimplify(reporter, path, filename); |
| 4783 | } |
| 4784 | |
caryclark | 4e1a4c9 | 2015-05-18 12:56:57 -0700 | [diff] [blame] | 4785 | static void testIssue3838_3(skiatest::Reporter* reporter,const char* filename) { |
| 4786 | SkPath path; |
| 4787 | path.moveTo(40, 10); |
| 4788 | path.lineTo(60, 10); |
| 4789 | path.lineTo(60, 30); |
| 4790 | path.lineTo(40, 30); |
| 4791 | path.lineTo(40, 10); |
| 4792 | path.moveTo(41, 11); |
| 4793 | path.lineTo(41, 29); |
| 4794 | path.lineTo(59, 29); |
| 4795 | path.lineTo(59, 11); |
| 4796 | path.lineTo(41, 11); |
| 4797 | testSimplify(reporter, path, filename); |
| 4798 | } |
| 4799 | |
caryclark | 27c8eb8 | 2015-07-06 11:38:33 -0700 | [diff] [blame] | 4800 | static void testQuads65(skiatest::Reporter* reporter,const char* filename) { |
| 4801 | SkPath path; |
| 4802 | path.moveTo(1, 2); |
| 4803 | path.quadTo(3, 2, 0, 3); |
| 4804 | path.lineTo(1, 3); |
| 4805 | path.close(); |
| 4806 | path.moveTo(1, 0); |
| 4807 | path.lineTo(1, 2); |
| 4808 | path.quadTo(3, 2, 1, 3); |
| 4809 | path.close(); |
| 4810 | testSimplify(reporter, path, filename); |
| 4811 | } |
| 4812 | |
caryclark | d434972 | 2015-07-23 12:40:22 -0700 | [diff] [blame] | 4813 | static void fuzz864a(skiatest::Reporter* reporter,const char* filename) { |
| 4814 | SkPath path; |
| 4815 | path.moveTo(10, 90); |
| 4816 | path.lineTo(10, 90); |
| 4817 | path.lineTo(10, 30); |
| 4818 | path.lineTo(10, 30); |
| 4819 | path.lineTo(10, 90); |
| 4820 | path.close(); |
| 4821 | path.moveTo(10, 90); |
| 4822 | path.lineTo(10, 90); |
| 4823 | path.lineTo(10, 30); |
| 4824 | path.lineTo(10, 30); |
| 4825 | path.lineTo(10, 90); |
| 4826 | path.close(); |
| 4827 | path.moveTo(10, 90); |
| 4828 | path.lineTo(110, 90); |
| 4829 | path.lineTo(110, 30); |
| 4830 | path.lineTo(10, 30); |
| 4831 | path.lineTo(10, 90); |
| 4832 | path.close(); |
| 4833 | path.moveTo(10, 30); |
| 4834 | path.lineTo(32678, 30); |
| 4835 | path.lineTo(32678, 30); |
| 4836 | path.lineTo(10, 30); |
| 4837 | path.close(); |
| 4838 | path.moveTo(10, 3.35545e+07f); |
| 4839 | path.lineTo(110, 3.35545e+07f); |
| 4840 | path.lineTo(110, 30); |
| 4841 | path.lineTo(10, 30); |
| 4842 | path.lineTo(10, 3.35545e+07f); |
| 4843 | path.close(); |
| 4844 | path.moveTo(10, 315); |
| 4845 | path.lineTo(110, 315); |
| 4846 | path.lineTo(110, 255); |
| 4847 | path.lineTo(10, 255); |
| 4848 | path.lineTo(10, 315); |
| 4849 | path.close(); |
| 4850 | path.moveTo(0, 60); |
| 4851 | path.lineTo(100, 60); |
| 4852 | path.lineTo(100, 0); |
| 4853 | path.lineTo(0, 0); |
| 4854 | path.lineTo(0, 60); |
| 4855 | path.close(); |
| 4856 | path.moveTo(10, 90); |
| 4857 | path.lineTo(110, 90); |
| 4858 | path.lineTo(110, 30); |
| 4859 | path.lineTo(10, 30); |
| 4860 | path.lineTo(10, 90); |
| 4861 | path.close(); |
| 4862 | path.moveTo(10, 3.35545e+07f); |
| 4863 | path.lineTo(110, 3.35545e+07f); |
| 4864 | path.lineTo(110, 30); |
| 4865 | path.lineTo(10, 30); |
| 4866 | path.lineTo(10, 3.35545e+07f); |
| 4867 | path.close(); |
| 4868 | path.moveTo(10, 90); |
| 4869 | path.lineTo(110, 90); |
| 4870 | path.lineTo(110, 30); |
| 4871 | path.lineTo(10, 30); |
| 4872 | path.lineTo(10, 90); |
| 4873 | path.close(); |
| 4874 | testSimplify(reporter, path, filename); |
| 4875 | } |
| 4876 | |
caryclark | bb13433 | 2015-07-28 05:12:19 -0700 | [diff] [blame] | 4877 | static void cr514118(skiatest::Reporter* reporter,const char* filename) { |
| 4878 | SkPath path; |
| 4879 | path.moveTo(SkBits2Float(0x42c80000), SkBits2Float(0x42480000)); // 100, 50 |
| 4880 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 100, 0, 50, 0, 0.707107f |
| 4881 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 0, 0, 0, 50, 0.707107f |
| 4882 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 0, 100, 50, 100, 0.707107f |
| 4883 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 100, 100, 100, 50, 0.707107f |
| 4884 | path.close(); |
| 4885 | path.moveTo(SkBits2Float(0x42c80133), SkBits2Float(0x42480000)); // 100.002f, 50 |
| 4886 | path.conicTo(SkBits2Float(0x42c80133), SkBits2Float(0x00000000), SkBits2Float(0x42480267), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 100.002f, 0, 50.0023f, 0, 0.707107f |
| 4887 | path.conicTo(SkBits2Float(0x3b19b530), SkBits2Float(0x00000000), SkBits2Float(0x3b19b530), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 0.00234539f, 0, 0.00234539f, 50, 0.707107f |
| 4888 | path.conicTo(SkBits2Float(0x3b19b530), SkBits2Float(0x42c80000), SkBits2Float(0x42480267), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 0.00234539f, 100, 50.0023f, 100, 0.707107f |
| 4889 | path.conicTo(SkBits2Float(0x42c80133), SkBits2Float(0x42c80000), SkBits2Float(0x42c80133), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 100.002f, 100, 100.002f, 50, 0.707107f |
| 4890 | path.close(); |
| 4891 | testSimplify(reporter, path, filename); |
| 4892 | } |
| 4893 | |
caryclark | ef2e4ac | 2015-09-23 18:07:51 -0700 | [diff] [blame] | 4894 | static void fuzz994s_11(skiatest::Reporter* reporter, const char* filename) { |
| 4895 | SkPath path; |
| 4896 | path.setFillType((SkPath::FillType) 0); |
| 4897 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4898 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4899 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4900 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4901 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4902 | path.close(); |
| 4903 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4904 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4905 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4906 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4907 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4908 | path.close(); |
| 4909 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4910 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x42b40000)); // 110, 90 |
| 4911 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x41f00000)); // 110, 30 |
| 4912 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4913 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4914 | path.close(); |
| 4915 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4916 | path.lineTo(SkBits2Float(0x46ff4c00), SkBits2Float(0x41f00000)); // 32678, 30 |
| 4917 | path.lineTo(SkBits2Float(0x46ff4c00), SkBits2Float(0x41f00000)); // 32678, 30 |
| 4918 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4919 | path.close(); |
| 4920 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x4c000006)); // 10, 3.35545e+07f |
| 4921 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x4c000006)); // 110, 3.35545e+07f |
| 4922 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x41f00000)); // 110, 30 |
| 4923 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4924 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x4c000006)); // 10, 3.35545e+07f |
| 4925 | path.close(); |
| 4926 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x439d8000)); // 10, 315 |
| 4927 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x439d8000)); // 110, 315 |
| 4928 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x437f0000)); // 110, 255 |
| 4929 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x437f0000)); // 10, 255 |
| 4930 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x439d8000)); // 10, 315 |
| 4931 | path.close(); |
| 4932 | path.moveTo(SkBits2Float(0x00000000), SkBits2Float(0x42700000)); // 0, 60 |
| 4933 | path.lineTo(SkBits2Float(0x42c80000), SkBits2Float(0x42700000)); // 100, 60 |
| 4934 | path.lineTo(SkBits2Float(0x42c80000), SkBits2Float(0x00000000)); // 100, 0 |
| 4935 | path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000)); // 0, 0 |
| 4936 | path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x42700000)); // 0, 60 |
| 4937 | path.close(); |
| 4938 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4939 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x42b40000)); // 110, 90 |
| 4940 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x41f00000)); // 110, 30 |
| 4941 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4942 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4943 | path.close(); |
| 4944 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x4c000006)); // 10, 3.35545e+07f |
| 4945 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x4c000006)); // 110, 3.35545e+07f |
| 4946 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x41f00000)); // 110, 30 |
| 4947 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4948 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x4c000006)); // 10, 3.35545e+07f |
| 4949 | path.close(); |
| 4950 | path.moveTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4951 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x42b40000)); // 110, 90 |
| 4952 | path.lineTo(SkBits2Float(0x42dc0000), SkBits2Float(0x41f00000)); // 110, 30 |
| 4953 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x41f00000)); // 10, 30 |
| 4954 | path.lineTo(SkBits2Float(0x41200000), SkBits2Float(0x42b40000)); // 10, 90 |
| 4955 | path.close(); |
| 4956 | |
| 4957 | testSimplify(reporter, path, filename); |
| 4958 | } |
| 4959 | |
| 4960 | static void fuzz994s_3414(skiatest::Reporter* reporter, const char* filename) { |
| 4961 | SkPath path; |
| 4962 | path.setFillType((SkPath::FillType) 0); |
| 4963 | path.moveTo(SkBits2Float(0x42c80000), SkBits2Float(0x42480000)); // 100, 50 |
| 4964 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 100, 0, 50, 0, 0.707107f |
| 4965 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 0, 0, 0, 50, 0.707107f |
| 4966 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 0, 100, 50, 100, 0.707107f |
| 4967 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 100, 100, 100, 50, 0.707107f |
| 4968 | path.close(); |
| 4969 | path.moveTo(SkBits2Float(0x42c84964), SkBits2Float(0x42480000)); // 100.143f, 50 |
| 4970 | path.conicTo(SkBits2Float(0x42c84964), SkBits2Float(0x00000000), SkBits2Float(0x424892c8), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 100.143f, 0, 50.1433f, 0, 0.707107f |
| 4971 | path.conicTo(SkBits2Float(0x3e12c788), SkBits2Float(0x00000000), SkBits2Float(0x3e12c788), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 0.143339f, 0, 0.143339f, 50, 0.707107f |
| 4972 | path.conicTo(SkBits2Float(0x3e12c788), SkBits2Float(0x42c80000), SkBits2Float(0x424892c8), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 0.143339f, 100, 50.1433f, 100, 0.707107f |
| 4973 | path.conicTo(SkBits2Float(0x42c84964), SkBits2Float(0x42c80000), SkBits2Float(0x42c84964), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 100.143f, 100, 100.143f, 50, 0.707107f |
| 4974 | path.close(); |
| 4975 | path.moveTo(SkBits2Float(0x42c80000), SkBits2Float(0x42480000)); // 100, 50 |
| 4976 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 100, 0, 50, 0, 0.707107f |
| 4977 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x00000000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 0, 0, 0, 50, 0.707107f |
| 4978 | path.conicTo(SkBits2Float(0x00000000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 0, 100, 50, 100, 0.707107f |
| 4979 | path.conicTo(SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42c80000), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 100, 100, 100, 50, 0.707107f |
| 4980 | path.close(); |
| 4981 | path.moveTo(SkBits2Float(0x4c00006b), SkBits2Float(0x424c0000)); // 3.35549e+07f, 51 |
| 4982 | path.conicTo(SkBits2Float(0x4c00006b), SkBits2Float(0xcbffffe5), SkBits2Float(0x43d6e720), SkBits2Float(0xcbffffe5), SkBits2Float(0x3f3504f3)); // 3.35549e+07f, -3.35544e+07f, 429.806f, -3.35544e+07f, 0.707107f |
| 4983 | path.conicTo(SkBits2Float(0xcbffff28), SkBits2Float(0xcbffffe5), SkBits2Float(0xcbffff28), SkBits2Float(0x424c0000), SkBits2Float(0x3f3504f3)); // -3.3554e+07f, -3.35544e+07f, -3.3554e+07f, 51, 0.707107f |
| 4984 | path.conicTo(SkBits2Float(0xcbffff28), SkBits2Float(0x4c00000c), SkBits2Float(0x43d6e720), SkBits2Float(0x4c00000c), SkBits2Float(0x3f3504f3)); // -3.3554e+07f, 3.35545e+07f, 429.806f, 3.35545e+07f, 0.707107f |
| 4985 | path.conicTo(SkBits2Float(0x4c00006b), SkBits2Float(0x4c00000c), SkBits2Float(0x4c00006b), SkBits2Float(0x424c0000), SkBits2Float(0x3f3504f3)); // 3.35549e+07f, 3.35545e+07f, 3.35549e+07f, 51, 0.707107f |
| 4986 | path.close(); |
| 4987 | path.moveTo(SkBits2Float(0x43ef6720), SkBits2Float(0x42480000)); // 478.806f, 50 |
| 4988 | path.conicTo(SkBits2Float(0x43ef6720), SkBits2Float(0x00000000), SkBits2Float(0x43d66720), SkBits2Float(0x00000000), SkBits2Float(0x3f3504f3)); // 478.806f, 0, 428.806f, 0, 0.707107f |
| 4989 | path.conicTo(SkBits2Float(0x43bd6720), SkBits2Float(0x00000000), SkBits2Float(0x43bd6720), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 378.806f, 0, 378.806f, 50, 0.707107f |
| 4990 | path.conicTo(SkBits2Float(0x43bd6720), SkBits2Float(0x42c80000), SkBits2Float(0x43d66720), SkBits2Float(0x42c80000), SkBits2Float(0x3f3504f3)); // 378.806f, 100, 428.806f, 100, 0.707107f |
| 4991 | path.conicTo(SkBits2Float(0x43ef6720), SkBits2Float(0x42c80000), SkBits2Float(0x43ef6720), SkBits2Float(0x42480000), SkBits2Float(0x3f3504f3)); // 478.806f, 100, 478.806f, 50, 0.707107f |
| 4992 | path.close(); |
| 4993 | |
| 4994 | testSimplify(reporter, path, filename); |
| 4995 | } |
| 4996 | |
caryclark | 26ad22a | 2015-10-16 09:03:38 -0700 | [diff] [blame] | 4997 | static void fuzz_twister(skiatest::Reporter* reporter, const char* filename) { |
| 4998 | SkPath path; |
| 4999 | path.setFillType((SkPath::FillType) 0); |
| 5000 | path.moveTo(0, 600); |
| 5001 | path.lineTo(3.35544e+07f, 600); |
| 5002 | path.lineTo(3.35544e+07f, 0); |
| 5003 | path.lineTo(0, 0); |
| 5004 | path.lineTo(0, 600); |
| 5005 | path.close(); |
| 5006 | path.moveTo(63, 600); |
| 5007 | path.lineTo(3.35545e+07f, 600); |
| 5008 | path.lineTo(3.35545e+07f, 0); |
| 5009 | path.lineTo(63, 0); |
| 5010 | path.lineTo(63, 600); |
| 5011 | path.close(); |
| 5012 | path.moveTo(93, 600); |
| 5013 | path.lineTo(3.35545e+07f, 600); |
| 5014 | path.lineTo(3.35545e+07f, 0); |
| 5015 | path.lineTo(93, 0); |
| 5016 | path.lineTo(93, 600); |
| 5017 | path.close(); |
| 5018 | path.moveTo(123, 600); |
| 5019 | path.lineTo(3.35546e+07f, 600); |
| 5020 | path.lineTo(3.35546e+07f, 0); |
| 5021 | path.lineTo(123, 0); |
| 5022 | path.lineTo(123, 600); |
| 5023 | path.close(); |
| 5024 | testSimplify(reporter, path, filename); |
| 5025 | } |
| 5026 | |
caryclark | 1c9ce61 | 2015-11-20 14:06:28 -0800 | [diff] [blame] | 5027 | static void fuzz_twister2(skiatest::Reporter* reporter, const char* filename) { |
| 5028 | SkPath path; |
| 5029 | |
| 5030 | path.moveTo(SkBits2Float(0x00000000), SkBits2Float(0x44160000)); // 0, 600 |
| 5031 | path.lineTo(SkBits2Float(0x4bfffffe), SkBits2Float(0x44160000)); // 3.35544e+07f, 600 |
| 5032 | path.lineTo(SkBits2Float(0x4bfffffe), SkBits2Float(0x00000000)); // 3.35544e+07f, 0 |
| 5033 | path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x00000000)); // 0, 0 |
| 5034 | path.lineTo(SkBits2Float(0x00000000), SkBits2Float(0x44160000)); // 0, 600 |
| 5035 | path.close(); |
| 5036 | |
| 5037 | path.moveTo(SkBits2Float(0x427c0000), SkBits2Float(0x00000000)); // 63, 0 |
| 5038 | path.lineTo(SkBits2Float(0x4c00000f), SkBits2Float(0x00000000)); // 3.35545e+07f, 0 |
| 5039 | path.lineTo(SkBits2Float(0x4c00000f), SkBits2Float(0x00000000)); // 3.35545e+07f, 0 |
| 5040 | path.lineTo(SkBits2Float(0x427c0000), SkBits2Float(0x00000000)); // 63, 0 |
| 5041 | path.close(); |
| 5042 | |
| 5043 | path.moveTo(SkBits2Float(0x42ba0000), SkBits2Float(0x00000000)); // 93, 0 |
| 5044 | path.lineTo(SkBits2Float(0x4c000016), SkBits2Float(0x00000000)); // 3.35545e+07f, 0 |
| 5045 | path.lineTo(SkBits2Float(0x4c000016), SkBits2Float(0x00000000)); // 3.35545e+07f, 0 |
| 5046 | path.lineTo(SkBits2Float(0x42ba0000), SkBits2Float(0x00000000)); // 93, 0 |
| 5047 | path.close(); |
| 5048 | |
| 5049 | path.moveTo(SkBits2Float(0x42f60000), SkBits2Float(0x00000000)); // 123, 0 |
| 5050 | path.lineTo(SkBits2Float(0x4c00001e), SkBits2Float(0x00000000)); // 3.35546e+07f, 0 |
| 5051 | path.lineTo(SkBits2Float(0x4c00001e), SkBits2Float(0x00000000)); // 3.35546e+07f, 0 |
| 5052 | path.lineTo(SkBits2Float(0x42f60000), SkBits2Float(0x00000000)); // 123, 0 |
| 5053 | path.close(); |
| 5054 | |
caryclark | 55888e4 | 2016-07-18 10:01:36 -0700 | [diff] [blame] | 5055 | testSimplify(reporter, path, filename); |
caryclark | 1c9ce61 | 2015-11-20 14:06:28 -0800 | [diff] [blame] | 5056 | } |
| 5057 | |
caryclark | 2bec26a | 2016-05-26 09:01:47 -0700 | [diff] [blame] | 5058 | static void fuzz763_4713_b(skiatest::Reporter* reporter, const char* filename) { |
| 5059 | SkPath path; |
| 5060 | path.setFillType((SkPath::FillType) 0); |
| 5061 | path.moveTo(SkBits2Float(0x42240000), SkBits2Float(0x42040000)); |
| 5062 | path.quadTo(SkBits2Float(0x42240000), SkBits2Float(0x4211413d), SkBits2Float(0x421aa09e), SkBits2Float(0x421aa09e)); |
| 5063 | path.quadTo(SkBits2Float(0x4211413d), SkBits2Float(0x42240000), SkBits2Float(0x42040000), SkBits2Float(0x42240000)); |
| 5064 | path.quadTo(SkBits2Float(0x41ed7d86), SkBits2Float(0x42240000), SkBits2Float(0x41dabec3), SkBits2Float(0x421aa09e)); |
| 5065 | path.quadTo(SkBits2Float(0x41c80000), SkBits2Float(0x4211413d), SkBits2Float(0x41c80000), SkBits2Float(0x42040000)); |
| 5066 | path.quadTo(SkBits2Float(0x41c80000), SkBits2Float(0x41ed7d86), SkBits2Float(0x41dabec3), SkBits2Float(0x41dabec3)); |
| 5067 | path.quadTo(SkBits2Float(0x41ed7d86), SkBits2Float(0x41c80000), SkBits2Float(0x42040000), SkBits2Float(0x41c80000)); |
| 5068 | path.quadTo(SkBits2Float(0x4211413d), SkBits2Float(0x41c80000), SkBits2Float(0x421aa09e), SkBits2Float(0x41dabec3)); |
| 5069 | path.quadTo(SkBits2Float(0x42240000), SkBits2Float(0x41ed7d86), SkBits2Float(0x42240000), SkBits2Float(0x42040000)); |
| 5070 | path.close(); |
| 5071 | |
| 5072 | path.moveTo(SkBits2Float(0x4204f72e), SkBits2Float(0x41c56cd2)); |
| 5073 | path.quadTo(SkBits2Float(0x42123842), SkBits2Float(0x41c52adf), SkBits2Float(0x421baed7), SkBits2Float(0x41d7bac6)); |
| 5074 | path.quadTo(SkBits2Float(0x4225256d), SkBits2Float(0x41ea4aad), SkBits2Float(0x42254667), SkBits2Float(0x4202666b)); |
| 5075 | path.quadTo(SkBits2Float(0x42256760), SkBits2Float(0x420fa77f), SkBits2Float(0x421c1f6c), SkBits2Float(0x42191e14)); |
| 5076 | path.quadTo(SkBits2Float(0x421bff97), SkBits2Float(0x42193e89), SkBits2Float(0x421bdf6b), SkBits2Float(0x42195eb8)); |
| 5077 | path.quadTo(SkBits2Float(0x421bbff6), SkBits2Float(0x42197f32), SkBits2Float(0x421ba03b), SkBits2Float(0x42199f57)); |
| 5078 | path.quadTo(SkBits2Float(0x421b605e), SkBits2Float(0x4219e00a), SkBits2Float(0x421b1fa8), SkBits2Float(0x421a1f22)); |
| 5079 | path.quadTo(SkBits2Float(0x421ae0f1), SkBits2Float(0x421a604b), SkBits2Float(0x421aa09e), SkBits2Float(0x421aa09e)); |
| 5080 | path.quadTo(SkBits2Float(0x4211413d), SkBits2Float(0x42240000), SkBits2Float(0x42040000), SkBits2Float(0x42240000)); |
| 5081 | path.quadTo(SkBits2Float(0x41ed7d86), SkBits2Float(0x42240000), SkBits2Float(0x41dabec3), SkBits2Float(0x421aa09e)); |
| 5082 | path.quadTo(SkBits2Float(0x41c80000), SkBits2Float(0x4211413d), SkBits2Float(0x41c80000), SkBits2Float(0x42040000)); |
| 5083 | path.quadTo(SkBits2Float(0x41c80000), SkBits2Float(0x41ed7d86), SkBits2Float(0x41dabec3), SkBits2Float(0x41dabec3)); |
| 5084 | path.quadTo(SkBits2Float(0x41db19b1), SkBits2Float(0x41da63d5), SkBits2Float(0x41db755b), SkBits2Float(0x41da0a9b)); |
| 5085 | path.quadTo(SkBits2Float(0x41dbce01), SkBits2Float(0x41d9ae59), SkBits2Float(0x41dc285e), SkBits2Float(0x41d952ce)); |
| 5086 | path.quadTo(SkBits2Float(0x41dc55b6), SkBits2Float(0x41d924df), SkBits2Float(0x41dc82cd), SkBits2Float(0x41d8f7cd)); |
| 5087 | path.quadTo(SkBits2Float(0x41dcaf1e), SkBits2Float(0x41d8ca01), SkBits2Float(0x41dcdc4c), SkBits2Float(0x41d89bf0)); |
| 5088 | path.quadTo(SkBits2Float(0x41ef6c33), SkBits2Float(0x41c5aec5), SkBits2Float(0x4204f72e), SkBits2Float(0x41c56cd2)); |
| 5089 | path.close(); |
caryclark | e839e78 | 2016-09-15 07:48:18 -0700 | [diff] [blame] | 5090 | testSimplify(reporter, path, filename); |
caryclark | 55888e4 | 2016-07-18 10:01:36 -0700 | [diff] [blame] | 5091 | } |
| 5092 | |
| 5093 | static void dean4(skiatest::Reporter* reporter, const char* filename) { |
| 5094 | SkPath path; |
| 5095 | |
| 5096 | // start region |
| 5097 | // start loop, contour: 1 |
| 5098 | // Segment 1145.3381097316742 2017.6783947944641 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2017.0033947825432 |
| 5099 | path.moveTo(1145.3381347656250, 2017.6783447265625); |
| 5100 | path.lineTo(1145.3381347656250, 2017.0034179687500); |
| 5101 | // Segment 1145.3381097316742 2017.0033947825432 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6927231521568 2017.0033947825432 |
| 5102 | path.lineTo(1143.6927490234375, 2017.0034179687500); |
| 5103 | // Segment 1143.6927231521568 2017.0033947825432 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1144.8640675112890 2018.1589246992417 |
| 5104 | path.lineTo(1144.8640136718750, 2018.1589355468750); |
| 5105 | // Segment 1144.8640675112890 2018.1589246992417 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2017.6783947944641 |
| 5106 | path.lineTo(1145.3381347656250, 2017.6783447265625); |
| 5107 | path.close(); |
| 5108 | // start loop, contour: 2 |
| 5109 | // Segment 1145.3381097316742 2016.3216052055359 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1144.8640675258462 2015.8410752863977 |
| 5110 | path.moveTo(1145.3381347656250, 2016.3216552734375); |
| 5111 | path.lineTo(1144.8640136718750, 2015.8410644531250); |
| 5112 | // Segment 1144.8640675258462 2015.8410752863977 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6927230811802 2016.9966052174568 |
| 5113 | path.lineTo(1143.6927490234375, 2016.9965820312500); |
| 5114 | // Segment 1143.6927230811802 2016.9966052174568 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2016.9966052174568 |
| 5115 | path.lineTo(1145.3381347656250, 2016.9965820312500); |
| 5116 | // Segment 1145.3381097316742 2016.9966052174568 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2016.3216052055359 |
| 5117 | path.lineTo(1145.3381347656250, 2016.3216552734375); |
| 5118 | path.close(); |
| 5119 | // start loop, contour: 3 |
| 5120 | // Segment 1147.3323798179626 2014.3542600870132 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220239557 2014.8347900059885 |
| 5121 | path.moveTo(1147.3323974609375, 2014.3542480468750); |
| 5122 | path.lineTo(1147.8063964843750, 2014.8348388671875); |
| 5123 | // Segment 1147.8064220239557 2014.8347900059885 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220516883 2014.8347899786306 |
| 5124 | path.lineTo(1147.8063964843750, 2014.8348388671875); |
| 5125 | // Segment 1147.8064220516883 2014.8347899786306 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.3323798179626 2014.3542600870132 |
| 5126 | path.lineTo(1147.3323974609375, 2014.3542480468750); |
| 5127 | path.close(); |
| 5128 | // start loop, contour: 4 |
| 5129 | // Segment 1146.3696286678314 2013.4045072346926 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436708778083 2013.8850371497379 |
| 5130 | path.moveTo(1146.3696289062500, 2013.4045410156250); |
| 5131 | path.lineTo(1146.8436279296875, 2013.8850097656250); |
| 5132 | // Segment 1146.8436708778083 2013.8850371497379 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436709015571 2013.8850371263100 |
| 5133 | path.lineTo(1146.8436279296875, 2013.8850097656250); |
| 5134 | // Segment 1146.8436709015571 2013.8850371263100 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.3696286678314 2013.4045072346926 |
| 5135 | path.lineTo(1146.3696289062500, 2013.4045410156250); |
| 5136 | path.close(); |
| 5137 | // start loop, contour: 5 |
| 5138 | // Segment 1143.2063037902117 2016.5251235961914 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615802348 2016.0445936811461 |
| 5139 | path.moveTo(1143.2062988281250, 2016.5251464843750); |
| 5140 | path.lineTo(1142.7322998046875, 2016.0445556640625); |
| 5141 | // Segment 1142.7322615802348 2016.0445936811461 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615564860 2016.0445937045740 |
| 5142 | path.lineTo(1142.7322998046875, 2016.0445556640625); |
| 5143 | // Segment 1142.7322615564860 2016.0445937045740 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.2063037902117 2016.5251235961914 |
| 5144 | path.lineTo(1143.2062988281250, 2016.5251464843750); |
| 5145 | path.close(); |
| 5146 | // start loop, contour: 6 |
| 5147 | // Segment 1143.0687679275870 2016.7286419868469 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.5428101613127 2017.2091718784643 |
| 5148 | path.moveTo(1143.0687255859375, 2016.7286376953125); |
| 5149 | path.lineTo(1143.5428466796875, 2017.2092285156250); |
| 5150 | // Segment 1143.5428101613127 2017.2091718784643 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.7437679395080 2017.0109272411960 |
| 5151 | path.lineTo(1143.7437744140625, 2017.0109863281250); |
| 5152 | // Segment 1143.7437679395080 2017.0109272411960 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.7437679395080 2016.7286419868469 |
| 5153 | path.lineTo(1143.7437744140625, 2016.7286376953125); |
| 5154 | // Segment 1143.7437679395080 2016.7286419868469 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.0687679275870 2016.7286419868469 |
| 5155 | path.lineTo(1143.0687255859375, 2016.7286376953125); |
| 5156 | path.close(); |
| 5157 | // start loop, contour: 7 |
| 5158 | // Segment 1143.2063037902117 2017.4748764038086 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615603032 2017.9554062991915 |
| 5159 | path.moveTo(1143.2062988281250, 2017.4748535156250); |
| 5160 | path.lineTo(1142.7322998046875, 2017.9554443359375); |
| 5161 | // Segment 1142.7322615603032 2017.9554062991915 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615746241 2017.9554063133189 |
| 5162 | path.lineTo(1142.7322998046875, 2017.9554443359375); |
| 5163 | // Segment 1142.7322615746241 2017.9554063133189 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.2063037902117 2017.4748764038086 |
| 5164 | path.lineTo(1143.2062988281250, 2017.4748535156250); |
| 5165 | path.close(); |
| 5166 | // start loop, contour: 8 |
| 5167 | // Segment 1146.3696286678314 2020.5954928398132 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436708977399 2020.1149629444303 |
| 5168 | path.moveTo(1146.3696289062500, 2020.5954589843750); |
| 5169 | path.lineTo(1146.8436279296875, 2020.1149902343750); |
| 5170 | // Segment 1146.8436708977399 2020.1149629444303 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436708834190 2020.1149629303029 |
| 5171 | path.lineTo(1146.8436279296875, 2020.1149902343750); |
| 5172 | // Segment 1146.8436708834190 2020.1149629303029 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.3696286678314 2020.5954928398132 |
| 5173 | path.lineTo(1146.3696289062500, 2020.5954589843750); |
| 5174 | path.close(); |
| 5175 | // start loop, contour: 9 |
| 5176 | // Segment 1147.3323798179626 2019.6457400321960 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220484741 2019.1652101374082 |
| 5177 | path.moveTo(1147.3323974609375, 2019.6457519531250); |
| 5178 | path.lineTo(1147.8063964843750, 2019.1651611328125); |
| 5179 | // Segment 1147.8064220484741 2019.1652101374082 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220383478 2019.1652101274185 |
| 5180 | path.lineTo(1147.8063964843750, 2019.1651611328125); |
| 5181 | // Segment 1147.8064220383478 2019.1652101274185 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.3323798179626 2019.6457400321960 |
| 5182 | path.lineTo(1147.3323974609375, 2019.6457519531250); |
| 5183 | path.close(); |
| 5184 | // start loop, contour: 10 |
| 5185 | // Segment 1145.3381097316742 2018.3533948063850 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2018.3533948063850 |
| 5186 | path.moveTo(1145.3381347656250, 2018.3533935546875); |
| 5187 | path.lineTo(1156.6848144531250, 2018.3533935546875); |
| 5188 | // Segment 1156.6848182678223 2018.3533948063850 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2017.0033947825432 |
| 5189 | path.lineTo(1156.6848144531250, 2017.0034179687500); |
| 5190 | // Segment 1156.6848182678223 2017.0033947825432 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2017.0033947825432 |
| 5191 | path.lineTo(1145.3381347656250, 2017.0034179687500); |
| 5192 | // Segment 1145.3381097316742 2017.0033947825432 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2018.3533948063850 |
| 5193 | path.lineTo(1145.3381347656250, 2018.3533935546875); |
| 5194 | path.close(); |
| 5195 | // start loop, contour: 11 |
| 5196 | // Segment 1156.6848182678223 2018.3533948063850 0.3569631313191 0.0000000000000 -0.2645167304388 0.2609454237780 1157.6574279406423 2017.9723661860094 |
| 5197 | path.moveTo(1156.6848144531250, 2018.3533935546875); |
| 5198 | path.cubicTo(1157.0417480468750, 2018.3533935546875, 1157.3929443359375, 2018.2332763671875, 1157.6574707031250, 2017.9724121093750); |
| 5199 | // Segment 1157.6574279406423 2017.9723661860094 0.2653344079822 -0.2617520616521 0.0000000000000 0.3596905289350 1158.0474975705147 2017.0000000000000 |
| 5200 | path.cubicTo(1157.9227294921875, 2017.7105712890625, 1158.0474853515625, 2017.3597412109375, 1158.0474853515625, 2017.0000000000000); |
| 5201 | // Segment 1158.0474975705147 2017.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6974975466728 2017.0000000000000 |
| 5202 | path.lineTo(1156.6975097656250, 2017.0000000000000); |
| 5203 | // Segment 1156.6974975466728 2017.0000000000000 0.0028009248351 0.0403311981485 0.0118595244351 -0.0220843520393 1156.6941780622435 2017.0325257649940 |
| 5204 | path.cubicTo(1156.7003173828125, 2017.0402832031250, 1156.7060546875000, 2017.0104980468750, 1156.6942138671875, 2017.0324707031250); |
| 5205 | // Segment 1156.6941780622435 2017.0325257649940 -0.0032637855860 0.0184860248562 0.0120617528380 -0.0065934603083 1156.7093435710913 2017.0113063061967 |
| 5206 | path.cubicTo(1156.6909179687500, 2017.0510253906250, 1156.7214355468750, 2017.0047607421875, 1156.7093505859375, 2017.0113525390625); |
| 5207 | // split at 0.4496445953846 |
| 5208 | // path.cubicTo(1156.6927490234375, 2017.0407714843750, 1156.6981201171875, 2017.0360107421875, 1156.7033691406250, 2017.0289306640625); |
| 5209 | // path.cubicTo(1156.7097167968750, 2017.0201416015625, 1156.7159423828125, 2017.0076904296875, 1156.7093505859375, 2017.0113525390625); |
| 5210 | // Segment 1156.7093435710913 2017.0113063061967 -0.0070717276929 0.0122220954353 0.0203483811973 -0.0039136894418 1156.7268834554304 2016.9985353221975 |
| 5211 | path.cubicTo(1156.7022705078125, 2017.0235595703125, 1156.7471923828125, 2016.9946289062500, 1156.7269287109375, 2016.9985351562500); |
| 5212 | // Segment 1156.7268834554304 2016.9985353221975 -0.0244396787691 0.0123649140586 0.0433322464027 0.0026558844666 1156.6848182678223 2017.0033947825432 |
| 5213 | path.cubicTo(1156.7023925781250, 2017.0108642578125, 1156.7281494140625, 2017.0061035156250, 1156.6848144531250, 2017.0034179687500); |
| 5214 | // split at 0.4418420493603 |
| 5215 | // path.cubicTo(1156.7160644531250, 2017.0040283203125, 1156.7150878906250, 2017.0061035156250, 1156.7136230468750, 2017.0065917968750); |
| 5216 | // path.cubicTo(1156.7116699218750, 2017.0070800781250, 1156.7089843750000, 2017.0048828125000, 1156.6848144531250, 2017.0034179687500); |
| 5217 | // Segment 1156.6848182678223 2017.0033947825432 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2018.3533948063850 |
| 5218 | path.lineTo(1156.6848144531250, 2018.3533935546875); |
| 5219 | path.close(); |
| 5220 | // start loop, contour: 12 |
| 5221 | // Segment 1158.0474975705147 2017.0000000000000 0.0000000000000 -0.3596905289350 0.2653344079822 0.2617520616521 1157.6574279406423 2016.0276338139906 |
| 5222 | path.moveTo(1158.0474853515625, 2017.0000000000000); |
| 5223 | path.cubicTo(1158.0474853515625, 2016.6402587890625, 1157.9227294921875, 2016.2894287109375, 1157.6574707031250, 2016.0275878906250); |
| 5224 | // Segment 1157.6574279406423 2016.0276338139906 -0.2645167304388 -0.2609454237780 0.3569631313191 0.0000000000000 1156.6848182678223 2015.6466051936150 |
| 5225 | path.cubicTo(1157.3929443359375, 2015.7667236328125, 1157.0417480468750, 2015.6466064453125, 1156.6848144531250, 2015.6466064453125); |
| 5226 | // split at 0.5481675863266 |
| 5227 | // path.cubicTo(1157.5124511718750, 2015.8846435546875, 1157.3414306640625, 2015.7839355468750, 1157.1577148437500, 2015.7220458984375); |
| 5228 | // path.cubicTo(1157.0062255859375, 2015.6711425781250, 1156.8460693359375, 2015.6466064453125, 1156.6848144531250, 2015.6466064453125); |
| 5229 | // Segment 1156.6848182678223 2015.6466051936150 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2016.9966052174568 |
| 5230 | path.lineTo(1156.6848144531250, 2016.9965820312500); |
| 5231 | // Segment 1156.6848182678223 2016.9966052174568 0.0433322464027 -0.0026558844666 -0.0244396787691 -0.0123649140586 1156.7268834554304 2017.0014646778025 |
| 5232 | path.cubicTo(1156.7281494140625, 2016.9938964843750, 1156.7023925781250, 2016.9891357421875, 1156.7269287109375, 2017.0014648437500); |
| 5233 | // split at 0.5581579208374 |
| 5234 | // path.cubicTo(1156.7089843750000, 2016.9951171875000, 1156.7116699218750, 2016.9929199218750, 1156.7136230468750, 2016.9934082031250); |
| 5235 | // path.cubicTo(1156.7150878906250, 2016.9938964843750, 1156.7160644531250, 2016.9959716796875, 1156.7269287109375, 2017.0014648437500); |
| 5236 | // Segment 1156.7268834554304 2017.0014646778025 0.0203483811973 0.0039136894418 -0.0070717276929 -0.0122220954353 1156.7093435710913 2016.9886936938033 |
| 5237 | path.cubicTo(1156.7471923828125, 2017.0053710937500, 1156.7022705078125, 2016.9764404296875, 1156.7093505859375, 2016.9886474609375); |
| 5238 | // Segment 1156.7093435710913 2016.9886936938033 0.0120617528380 0.0065934603083 -0.0032637855860 -0.0184860248562 1156.6941780622435 2016.9674742350060 |
| 5239 | path.cubicTo(1156.7214355468750, 2016.9952392578125, 1156.6909179687500, 2016.9489746093750, 1156.6942138671875, 2016.9675292968750); |
| 5240 | // Segment 1156.6941780622435 2016.9674742350060 0.0118595244351 0.0220843520393 0.0028009248351 -0.0403311981485 1156.6974975466728 2017.0000000000000 |
| 5241 | path.cubicTo(1156.7060546875000, 2016.9895019531250, 1156.7003173828125, 2016.9597167968750, 1156.6975097656250, 2017.0000000000000); |
| 5242 | // split at 0.4572408795357 |
| 5243 | // path.cubicTo(1156.6995849609375, 2016.9775390625000, 1156.7014160156250, 2016.9768066406250, 1156.7014160156250, 2016.9768066406250); |
| 5244 | // path.cubicTo(1156.7014160156250, 2016.9769287109375, 1156.6989746093750, 2016.9781494140625, 1156.6975097656250, 2017.0000000000000); |
| 5245 | // Segment 1156.6974975466728 2017.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1158.0474975705147 2017.0000000000000 |
| 5246 | path.lineTo(1158.0474853515625, 2017.0000000000000); |
| 5247 | path.close(); |
| 5248 | // start loop, contour: 13 |
| 5249 | // Segment 1156.6848182678223 2015.6466051936150 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2015.6466051936150 |
| 5250 | path.moveTo(1156.6848144531250, 2015.6466064453125); |
| 5251 | path.lineTo(1145.3381347656250, 2015.6466064453125); |
| 5252 | // Segment 1145.3381097316742 2015.6466051936150 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.3381097316742 2016.9966052174568 |
| 5253 | path.lineTo(1145.3381347656250, 2016.9965820312500); |
| 5254 | // Segment 1145.3381097316742 2016.9966052174568 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2016.9966052174568 |
| 5255 | path.lineTo(1156.6848144531250, 2016.9965820312500); |
| 5256 | // Segment 1156.6848182678223 2016.9966052174568 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1156.6848182678223 2015.6466051936150 |
| 5257 | path.lineTo(1156.6848144531250, 2015.6466064453125); |
| 5258 | path.close(); |
| 5259 | // start loop, contour: 14 |
| 5260 | // Segment 1145.8121519375022 2016.8021351246741 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220237907 2014.8347900061515 |
| 5261 | path.moveTo(1145.8121337890625, 2016.8021240234375); |
| 5262 | path.lineTo(1147.8063964843750, 2014.8348388671875); |
| 5263 | // Segment 1147.8064220237907 2014.8347900061515 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8583376121346 2013.8737301678750 |
| 5264 | path.lineTo(1146.8583984375000, 2013.8737792968750); |
| 5265 | // Segment 1146.8583376121346 2013.8737301678750 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1144.8640675258462 2015.8410752863977 |
| 5266 | path.lineTo(1144.8640136718750, 2015.8410644531250); |
| 5267 | // Segment 1144.8640675258462 2015.8410752863977 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.8121519375022 2016.8021351246741 |
| 5268 | path.lineTo(1145.8121337890625, 2016.8021240234375); |
| 5269 | path.close(); |
| 5270 | // start loop, contour: 15 |
| 5271 | // Segment 1147.8064220516883 2014.8347899786306 0.5430154146087 -0.5356841365729 0.5430154146087 0.5356841365729 1147.8064220516883 2012.9239773430752 |
| 5272 | path.moveTo(1147.8063964843750, 2014.8348388671875); |
| 5273 | path.cubicTo(1148.3494873046875, 2014.2990722656250, 1148.3494873046875, 2013.4597167968750, 1147.8063964843750, 2012.9239501953125); |
| 5274 | // Segment 1147.8064220516883 2012.9239773430752 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8583375842370 2013.8850371263100 |
| 5275 | path.lineTo(1146.8583984375000, 2013.8850097656250); |
| 5276 | // Segment 1146.8583375842370 2013.8850371263100 0.0071280060876 0.0070317705240 0.0071280060876 -0.0070317705240 1146.8583375842370 2013.8737301953959 |
| 5277 | path.cubicTo(1146.8654785156250, 2013.8920898437500, 1146.8654785156250, 2013.8666992187500, 1146.8583984375000, 2013.8737792968750); |
| 5278 | // Segment 1146.8583375842370 2013.8737301953959 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220516883 2014.8347899786306 |
| 5279 | path.lineTo(1147.8063964843750, 2014.8348388671875); |
| 5280 | path.close(); |
| 5281 | // start loop, contour: 16 |
| 5282 | // Segment 1147.8064220516883 2012.9239773430752 -0.5379138488298 -0.5306514472866 0.5379138488298 -0.5306514472866 1145.8955864341058 2012.9239773430752 |
| 5283 | path.moveTo(1147.8063964843750, 2012.9239501953125); |
| 5284 | path.cubicTo(1147.2685546875000, 2012.3933105468750, 1146.4334716796875, 2012.3933105468750, 1145.8956298828125, 2012.9239501953125); |
| 5285 | // Segment 1145.8955864341058 2012.9239773430752 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436709015571 2013.8850371263100 |
| 5286 | path.lineTo(1146.8436279296875, 2013.8850097656250); |
| 5287 | // Segment 1146.8436709015571 2013.8850371263100 0.0122295718664 -0.0120644598103 -0.0122295718664 -0.0120644598103 1146.8583375842370 2013.8850371263100 |
| 5288 | path.cubicTo(1146.8559570312500, 2013.8729248046875, 1146.8460693359375, 2013.8729248046875, 1146.8583984375000, 2013.8850097656250); |
| 5289 | // Segment 1146.8583375842370 2013.8850371263100 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220516883 2012.9239773430752 |
| 5290 | path.lineTo(1147.8063964843750, 2012.9239501953125); |
| 5291 | path.close(); |
| 5292 | // start loop, contour: 17 |
| 5293 | // Segment 1145.8955864579798 2012.9239773195236 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615803600 2016.0445936810224 |
| 5294 | path.moveTo(1145.8956298828125, 2012.9239501953125); |
| 5295 | path.lineTo(1142.7322998046875, 2016.0445556640625); |
| 5296 | // Segment 1142.7322615803600 2016.0445936810224 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6803460000633 2017.0056535113604 |
| 5297 | path.lineTo(1143.6802978515625, 2017.0056152343750); |
| 5298 | // Segment 1143.6803460000633 2017.0056535113604 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436708776831 2013.8850371498615 |
| 5299 | path.lineTo(1146.8436279296875, 2013.8850097656250); |
| 5300 | // Segment 1146.8436708776831 2013.8850371498615 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.8955864579798 2012.9239773195236 |
| 5301 | path.lineTo(1145.8956298828125, 2012.9239501953125); |
| 5302 | path.close(); |
| 5303 | // start loop, contour: 18 |
| 5304 | // Segment 1142.7322615564860 2016.0445937045740 -0.0343838913237 0.0339196727021 0.0561572931720 -0.0710493024751 1142.5744069596683 2016.2183613784646 |
| 5305 | path.moveTo(1142.7322998046875, 2016.0445556640625); |
| 5306 | path.cubicTo(1142.6978759765625, 2016.0784912109375, 1142.6306152343750, 2016.1473388671875, 1142.5744628906250, 2016.2183837890625); |
| 5307 | // Segment 1142.5744069596683 2016.2183613784646 -0.0547779032556 0.0720510806539 0.0000000000000 -0.2570904015602 1142.3937679156661 2016.7286419868469 |
| 5308 | path.cubicTo(1142.5196533203125, 2016.2904052734375, 1142.3937988281250, 2016.4715576171875, 1142.3937988281250, 2016.7286376953125); |
| 5309 | // Segment 1142.3937679156661 2016.7286419868469 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.7437679395080 2016.7286419868469 |
| 5310 | path.lineTo(1143.7437744140625, 2016.7286376953125); |
| 5311 | // Segment 1143.7437679395080 2016.7286419868469 -0.0051909534315 0.0665915567290 0.0133980913650 -0.0361675066532 1143.6976291086639 2016.9514128270803 |
| 5312 | path.cubicTo(1143.7385253906250, 2016.7952880859375, 1143.7110595703125, 2016.9152832031250, 1143.6976318359375, 2016.9514160156250); |
| 5313 | // Segment 1143.6976291086639 2016.9514128270803 -0.0142876819622 0.0277028472317 0.0040377216094 -0.0063254385208 1143.6490888124401 2017.0354042045738 |
| 5314 | path.cubicTo(1143.6833496093750, 2016.9791259765625, 1143.6530761718750, 2017.0290527343750, 1143.6490478515625, 2017.0354003906250); |
| 5315 | // Segment 1143.6490888124401 2017.0354042045738 -0.0045813437564 0.0032098513409 -0.0343840362634 0.0339198156850 1143.6803460239373 2017.0056534878088 |
| 5316 | path.cubicTo(1143.6445312500000, 2017.0385742187500, 1143.6459960937500, 2017.0395507812500, 1143.6802978515625, 2017.0056152343750); |
| 5317 | // Segment 1143.6803460239373 2017.0056534878088 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615564860 2016.0445937045740 |
| 5318 | path.lineTo(1142.7322998046875, 2016.0445556640625); |
| 5319 | path.close(); |
| 5320 | // start loop, contour: 19 |
| 5321 | // Segment 1142.5947256938614 2016.2481120952295 -0.1857487117715 0.1832409092043 0.0167379373694 -0.0990717748979 1142.3430278987244 2016.7518748698508 |
| 5322 | path.moveTo(1142.5947265625000, 2016.2481689453125); |
| 5323 | path.cubicTo(1142.4089355468750, 2016.4313964843750, 1142.3597412109375, 2016.6528320312500, 1142.3430175781250, 2016.7518310546875); |
| 5324 | // Segment 1142.3430278987244 2016.7518748698508 -0.0156657977007 0.1069052535795 0.0000000000000 -0.0339197441936 1142.3249999880791 2017.0000000000000 |
| 5325 | path.cubicTo(1142.3273925781250, 2016.8587646484375, 1142.3249511718750, 2016.9660644531250, 1142.3249511718750, 2017.0000000000000); |
| 5326 | // Segment 1142.3249999880791 2017.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6750000119209 2017.0000000000000 |
| 5327 | path.lineTo(1143.6750488281250, 2017.0000000000000); |
| 5328 | // Segment 1143.6750000119209 2017.0000000000000 0.0000000000000 -0.0339197441936 -0.0015261841961 -0.0051459911965 1143.6741640831724 2016.9767671169961 |
| 5329 | path.cubicTo(1143.6750488281250, 2016.9660644531250, 1143.6726074218750, 2016.9716796875000, 1143.6741943359375, 2016.9768066406250); |
| 5330 | // Segment 1143.6741640831724 2016.9767671169961 -0.0007886982052 0.0013596649622 0.0074114058388 -0.0224954551713 1143.6525251830094 2017.0486861571169 |
| 5331 | path.cubicTo(1143.6733398437500, 2016.9781494140625, 1143.6599121093750, 2017.0262451171875, 1143.6524658203125, 2017.0487060546875); |
| 5332 | // split at 0.4203657805920 |
| 5333 | // path.cubicTo(1143.6738281250000, 2016.9774169921875, 1143.6712646484375, 2016.9862060546875, 1143.6678466796875, 2016.9979248046875); |
| 5334 | // path.cubicTo(1143.6630859375000, 2017.0140380859375, 1143.6567382812500, 2017.0356445312500, 1143.6524658203125, 2017.0487060546875); |
| 5335 | // Segment 1143.6525251830094 2017.0486861571169 -0.0119644334077 0.0236755853369 0.0381324473830 -0.0447670202574 1143.5428101613127 2017.2091718784643 |
| 5336 | path.cubicTo(1143.6405029296875, 2017.0723876953125, 1143.5809326171875, 2017.1644287109375, 1143.5428466796875, 2017.2092285156250); |
| 5337 | // Segment 1143.5428101613127 2017.2091718784643 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.5947256938614 2016.2481120952295 |
| 5338 | path.lineTo(1142.5947265625000, 2016.2481689453125); |
| 5339 | path.close(); |
| 5340 | // start loop, contour: 20 |
| 5341 | // Segment 1142.3249999880791 2017.0000000000000 0.0000000000000 0.0339197441936 -0.0156657977007 -0.1069052535795 1142.3430278987244 2017.2481251301492 |
| 5342 | path.moveTo(1142.3249511718750, 2017.0000000000000); |
| 5343 | path.cubicTo(1142.3249511718750, 2017.0339355468750, 1142.3273925781250, 2017.1412353515625, 1142.3430175781250, 2017.2481689453125); |
| 5344 | // Segment 1142.3430278987244 2017.2481251301492 0.0167379373694 0.0990717748979 -0.1857487117715 -0.1832409092043 1142.5947256938614 2017.7518879047705 |
| 5345 | path.cubicTo(1142.3597412109375, 2017.3471679687500, 1142.4089355468750, 2017.5686035156250, 1142.5947265625000, 2017.7518310546875); |
| 5346 | // split at 0.4008532166481 |
| 5347 | // path.cubicTo(1142.3497314453125, 2017.2878417968750, 1142.3616943359375, 2017.3471679687500, 1142.3854980468750, 2017.4158935546875); |
| 5348 | // path.cubicTo(1142.4211425781250, 2017.5185546875000, 1142.4833984375000, 2017.6420898437500, 1142.5947265625000, 2017.7518310546875); |
| 5349 | // Segment 1142.5947256938614 2017.7518879047705 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.5428101613127 2016.7908281215357 |
| 5350 | path.lineTo(1143.5428466796875, 2016.7907714843750); |
| 5351 | // Segment 1143.5428101613127 2016.7908281215357 0.0381324473830 0.0447670202574 -0.0119644334077 -0.0236755853369 1143.6525251830094 2016.9513138428831 |
| 5352 | path.cubicTo(1143.5809326171875, 2016.8355712890625, 1143.6405029296875, 2016.9276123046875, 1143.6524658203125, 2016.9512939453125); |
| 5353 | // Segment 1143.6525251830094 2016.9513138428831 0.0074114058388 0.0224954551713 -0.0007886982052 -0.0013596649622 1143.6741640831724 2017.0232328830039 |
| 5354 | path.cubicTo(1143.6599121093750, 2016.9737548828125, 1143.6733398437500, 2017.0218505859375, 1143.6741943359375, 2017.0231933593750); |
| 5355 | // Segment 1143.6741640831724 2017.0232328830039 -0.0015261841961 0.0051459911965 0.0000000000000 0.0339197441936 1143.6750000119209 2017.0000000000000 |
| 5356 | path.cubicTo(1143.6726074218750, 2017.0283203125000, 1143.6750488281250, 2017.0339355468750, 1143.6750488281250, 2017.0000000000000); |
| 5357 | // Segment 1143.6750000119209 2017.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.3249999880791 2017.0000000000000 |
| 5358 | path.lineTo(1142.3249511718750, 2017.0000000000000); |
| 5359 | path.close(); |
| 5360 | // start loop, contour: 21 |
| 5361 | // Segment 1142.5947256938614 2017.7518879047705 -0.0799271403989 -0.1522613934208 -0.2174629955730 -0.2879403701950 1142.7322615564860 2017.9554062954260 |
| 5362 | path.moveTo(1142.5947265625000, 2017.7518310546875); |
| 5363 | path.cubicTo(1142.5147705078125, 2017.5996093750000, 1142.5147705078125, 2017.6674804687500, 1142.7322998046875, 2017.9554443359375); |
| 5364 | // Segment 1142.7322615564860 2017.9554062954260 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6803460239373 2016.9943465121912 |
| 5365 | path.lineTo(1143.6802978515625, 2016.9943847656250); |
| 5366 | // Segment 1143.6803460239373 2016.9943465121912 0.0799271403989 0.1522613934208 0.2174629955730 0.2879403701950 1143.5428101613127 2016.7908281215357 |
| 5367 | path.cubicTo(1143.7602539062500, 2017.1466064453125, 1143.7602539062500, 2017.0787353515625, 1143.5428466796875, 2016.7907714843750); |
| 5368 | // Segment 1143.5428101613127 2016.7908281215357 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.5947256938614 2017.7518879047705 |
| 5369 | path.lineTo(1142.5947265625000, 2017.7518310546875); |
| 5370 | path.close(); |
| 5371 | // start loop, contour: 22 |
| 5372 | // Segment 1142.7322615746241 2017.9554063133189 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.8955864522438 2021.0760227493236 |
| 5373 | path.moveTo(1142.7322998046875, 2017.9554443359375); |
| 5374 | path.lineTo(1145.8956298828125, 2021.0760498046875); |
| 5375 | // Segment 1145.8955864522438 2021.0760227493236 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8436708834190 2020.1149629303029 |
| 5376 | path.lineTo(1146.8436279296875, 2020.1149902343750); |
| 5377 | // Segment 1146.8436708834190 2020.1149629303029 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1143.6803460057993 2016.9943464942983 |
| 5378 | path.lineTo(1143.6802978515625, 2016.9943847656250); |
| 5379 | // Segment 1143.6803460057993 2016.9943464942983 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1142.7322615746241 2017.9554063133189 |
| 5380 | path.lineTo(1142.7322998046875, 2017.9554443359375); |
| 5381 | path.close(); |
| 5382 | // start loop, contour: 23 |
| 5383 | // Segment 1145.8955864341058 2021.0760227314306 0.2730164534637 0.2693304447891 -0.3016608168437 0.0000000000000 1146.8510041236877 2021.4740112423897 |
| 5384 | path.moveTo(1145.8956298828125, 2021.0760498046875); |
| 5385 | path.cubicTo(1146.1685791015625, 2021.3453369140625, 1146.5493164062500, 2021.4739990234375, 1146.8509521484375, 2021.4739990234375); |
| 5386 | // Segment 1146.8510041236877 2021.4740112423897 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8510041236877 2020.1240112185478 |
| 5387 | path.lineTo(1146.8509521484375, 2020.1240234375000); |
| 5388 | // Segment 1146.8510041236877 2020.1240112185478 -0.0031276099109 0.0031991747760 0.0281856144058 0.0140930868099 1146.8580791488898 2020.1202473991566 |
| 5389 | path.cubicTo(1146.8479003906250, 2020.1271972656250, 1146.8862304687500, 2020.1343994140625, 1146.8580322265625, 2020.1202392578125); |
| 5390 | // split at 0.3845077157021 |
| 5391 | // path.cubicTo(1146.8497314453125, 2020.1252441406250, 1146.8547363281250, 2020.1270751953125, 1146.8596191406250, 2020.1280517578125); |
| 5392 | // path.cubicTo(1146.8675537109375, 2020.1296386718750, 1146.8753662109375, 2020.1289062500000, 1146.8580322265625, 2020.1202392578125); |
| 5393 | // Segment 1146.8580791488898 2020.1202473991566 -0.0369995545027 -0.0123195805663 0.0067223483810 0.0136883790721 1146.8436709015571 2020.1149629481959 |
| 5394 | path.cubicTo(1146.8210449218750, 2020.1079101562500, 1146.8503417968750, 2020.1286621093750, 1146.8436279296875, 2020.1149902343750); |
| 5395 | // Segment 1146.8436709015571 2020.1149629481959 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.8955864341058 2021.0760227314306 |
| 5396 | path.lineTo(1145.8956298828125, 2021.0760498046875); |
| 5397 | path.close(); |
| 5398 | // start loop, contour: 24 |
| 5399 | // Segment 1146.8510041236877 2021.4740112423897 0.3016605789999 0.0000000000000 -0.2730166120260 0.2693306012106 1147.8064220516883 2021.0760227314306 |
| 5400 | path.moveTo(1146.8509521484375, 2021.4739990234375); |
| 5401 | path.cubicTo(1147.1527099609375, 2021.4739990234375, 1147.5334472656250, 2021.3453369140625, 1147.8063964843750, 2021.0760498046875); |
| 5402 | // Segment 1147.8064220516883 2021.0760227314306 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8583375842370 2020.1149629481959 |
| 5403 | path.lineTo(1146.8583984375000, 2020.1149902343750); |
| 5404 | // Segment 1146.8583375842370 2020.1149629481959 -0.0067222671256 0.0136883164611 0.0369996293611 -0.0123196021258 1146.8439293663473 2020.1202473404985 |
| 5405 | path.cubicTo(1146.8515625000000, 2020.1286621093750, 1146.8809814453125, 2020.1079101562500, 1146.8438720703125, 2020.1202392578125); |
| 5406 | // Segment 1146.8439293663473 2020.1202473404985 -0.0281857033438 0.0140931104690 0.0031276541428 0.0031991704542 1146.8510041236877 2020.1240112185478 |
| 5407 | path.cubicTo(1146.8157958984375, 2020.1343994140625, 1146.8541259765625, 2020.1271972656250, 1146.8509521484375, 2020.1240234375000); |
| 5408 | // Segment 1146.8510041236877 2020.1240112185478 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8510041236877 2021.4740112423897 |
| 5409 | path.lineTo(1146.8509521484375, 2021.4739990234375); |
| 5410 | path.close(); |
| 5411 | // start loop, contour: 25 |
| 5412 | // Segment 1147.8064220516883 2021.0760227314306 0.5430154146087 -0.5356841365729 0.5430154146087 0.5356841365729 1147.8064220516883 2019.1652101405787 |
| 5413 | path.moveTo(1147.8063964843750, 2021.0760498046875); |
| 5414 | path.cubicTo(1148.3494873046875, 2020.5402832031250, 1148.3494873046875, 2019.7009277343750, 1147.8063964843750, 2019.1651611328125); |
| 5415 | // Segment 1147.8064220516883 2019.1652101405787 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8583375842370 2020.1262699238134 |
| 5416 | path.lineTo(1146.8583984375000, 2020.1262207031250); |
| 5417 | // Segment 1146.8583375842370 2020.1262699238134 0.0071280060876 0.0070317705240 0.0071280060876 -0.0070317705240 1146.8583375842370 2020.1149629481959 |
| 5418 | path.cubicTo(1146.8654785156250, 2020.1333007812500, 1146.8654785156250, 2020.1079101562500, 1146.8583984375000, 2020.1149902343750); |
| 5419 | // Segment 1146.8583375842370 2020.1149629481959 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220516883 2021.0760227314306 |
| 5420 | path.lineTo(1147.8063964843750, 2021.0760498046875); |
| 5421 | path.close(); |
| 5422 | // start loop, contour: 26 |
| 5423 | // Segment 1147.8064220383478 2019.1652101274185 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1145.8121519520594 2017.1978648896866 |
| 5424 | path.moveTo(1147.8063964843750, 2019.1651611328125); |
| 5425 | path.lineTo(1145.8121337890625, 2017.1978759765625); |
| 5426 | // Segment 1145.8121519520594 2017.1978648896866 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1144.8640675112890 2018.1589246992417 |
| 5427 | path.lineTo(1144.8640136718750, 2018.1589355468750); |
| 5428 | // Segment 1144.8640675112890 2018.1589246992417 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1146.8583375975775 2020.1262699369736 |
| 5429 | path.lineTo(1146.8583984375000, 2020.1262207031250); |
| 5430 | // Segment 1146.8583375975775 2020.1262699369736 0.0000000000000 0.0000000000000 0.0000000000000 0.0000000000000 1147.8064220383478 2019.1652101274185 |
| 5431 | path.lineTo(1147.8063964843750, 2019.1651611328125); |
| 5432 | path.close(); |
| 5433 | |
| 5434 | testSimplify(reporter, path, filename); |
| 5435 | } |
| 5436 | |
| 5437 | static void testQuads66(skiatest::Reporter* reporter,const char* filename) { |
| 5438 | SkPath path; |
| 5439 | path.moveTo(2, 0); |
| 5440 | path.quadTo(3, 1, 2, 2); |
| 5441 | path.lineTo(2, 3); |
| 5442 | path.close(); |
| 5443 | path.moveTo(2, 1); |
| 5444 | path.lineTo(2, 1); |
| 5445 | path.quadTo(1, 2, 2, 2); |
| 5446 | path.close(); |
| 5447 | testSimplify(reporter, path, filename); |
| 5448 | } |
| 5449 | |
| 5450 | static void testQuads67(skiatest::Reporter* reporter,const char* filename) { |
| 5451 | SkPath path; |
| 5452 | path.moveTo(3, 2); |
| 5453 | path.quadTo(1, 3, 3, 3); |
| 5454 | path.lineTo(3, 3); |
| 5455 | path.close(); |
| 5456 | path.moveTo(0, 0); |
| 5457 | path.lineTo(1, 0); |
| 5458 | path.quadTo(2, 3, 3, 3); |
| 5459 | path.close(); |
| 5460 | testSimplify(reporter, path, filename); |
| 5461 | } |
| 5462 | |
| 5463 | static void testQuads68(skiatest::Reporter* reporter,const char* filename) { |
| 5464 | SkPath path; |
| 5465 | path.moveTo(1, 2); |
| 5466 | path.quadTo(0, 3, 2, 3); |
| 5467 | path.lineTo(2, 3); |
| 5468 | path.close(); |
| 5469 | path.moveTo(1, 0); |
| 5470 | path.lineTo(0, 1); |
| 5471 | path.quadTo(1, 3, 2, 3); |
| 5472 | path.close(); |
| 5473 | testSimplify(reporter, path, filename); |
| 5474 | } |
| 5475 | |
| 5476 | static void testQuads69(skiatest::Reporter* reporter,const char* filename) { |
| 5477 | SkPath path; |
| 5478 | path.moveTo(1, 0); |
| 5479 | path.quadTo(2, 2, 2, 3); |
| 5480 | path.lineTo(2, 3); |
| 5481 | path.close(); |
| 5482 | path.moveTo(1, 0); |
| 5483 | path.lineTo(1, 0); |
| 5484 | path.quadTo(3, 0, 1, 3); |
| 5485 | path.close(); |
| 5486 | testSimplify(reporter, path, filename); |
| 5487 | } |
| 5488 | |
| 5489 | static void testQuads70(skiatest::Reporter* reporter, const char* filename) { |
| 5490 | SkPath path; |
| 5491 | path.moveTo(1, 1); |
| 5492 | path.quadTo(2, 3, 3, 3); |
| 5493 | path.lineTo(3, 3); |
| 5494 | path.close(); |
| 5495 | path.moveTo(2, 0); |
| 5496 | path.lineTo(2, 2); |
| 5497 | path.quadTo(1, 3, 3, 3); |
| 5498 | path.close(); |
| 5499 | testSimplify(reporter, path, filename); |
| 5500 | } |
| 5501 | |
| 5502 | static void testQuads71(skiatest::Reporter* reporter, const char* filename) { |
| 5503 | SkPath path; |
| 5504 | path.moveTo(1, 1); |
| 5505 | path.quadTo(2, 3, 3, 3); |
| 5506 | path.lineTo(3, 3); |
| 5507 | path.close(); |
| 5508 | path.moveTo(3, 0); |
| 5509 | path.lineTo(2, 2); |
| 5510 | path.quadTo(1, 3, 3, 3); |
| 5511 | path.close(); |
| 5512 | testSimplify(reporter, path, filename); |
| 5513 | } |
| 5514 | |
| 5515 | static void testQuads72(skiatest::Reporter* reporter, const char* filename) { |
| 5516 | SkPath path; |
| 5517 | path.moveTo(1, 1); |
| 5518 | path.quadTo(2, 3, 3, 3); |
| 5519 | path.lineTo(3, 3); |
| 5520 | path.close(); |
| 5521 | path.moveTo(0, 1); |
| 5522 | path.lineTo(2, 2); |
| 5523 | path.quadTo(1, 3, 3, 3); |
| 5524 | path.close(); |
| 5525 | testSimplify(reporter, path, filename); |
caryclark | 2bec26a | 2016-05-26 09:01:47 -0700 | [diff] [blame] | 5526 | } |
| 5527 | |
caryclark | e839e78 | 2016-09-15 07:48:18 -0700 | [diff] [blame] | 5528 | static void testQuads73(skiatest::Reporter* reporter, const char* filename) { |
| 5529 | SkPath path; |
| 5530 | path.moveTo(0, 0); |
| 5531 | path.quadTo(0, 1, 1, 2); |
| 5532 | path.lineTo(0, 3); |
| 5533 | path.close(); |
| 5534 | path.moveTo(0, 0); |
| 5535 | path.lineTo(0, 0); |
| 5536 | path.quadTo(0, 1, 1, 1); |
| 5537 | path.close(); |
| 5538 | testSimplify(reporter, path, filename); |
| 5539 | } |
| 5540 | |
caryclark | e3a4e99 | 2016-09-28 09:22:17 -0700 | [diff] [blame] | 5541 | static void bug5169(skiatest::Reporter* reporter, const char* filename) { |
| 5542 | SkPath path; |
| 5543 | path.moveTo(SkBits2Float(0x00000000), SkBits2Float(0x4281c71c)); // 0, 64.8889f |
| 5544 | path.cubicTo(SkBits2Float(0x434e0000), SkBits2Float(0x4281c71c), SkBits2Float(0x00000000), SkBits2Float(0xc2a238e4), SkBits2Float(0x00000000), SkBits2Float(0x4281c71c)); // 206, 64.8889f, 0, -81.1111f, 0, 64.8889f |
| 5545 | path.moveTo(SkBits2Float(0x43300000), SkBits2Float(0x41971c72)); // 176, 18.8889f |
| 5546 | path.cubicTo(SkBits2Float(0xc29e0000), SkBits2Float(0xc25c71c7), SkBits2Float(0x42b20000), SkBits2Float(0x42fbc71c), SkBits2Float(0x43300000), SkBits2Float(0x41971c72)); // -79, -55.1111f, 89, 125.889f, 176, 18.8889f |
| 5547 | testSimplify(reporter, path, filename); |
| 5548 | } |
| 5549 | |
caryclark | b36a3cd | 2016-10-18 07:59:44 -0700 | [diff] [blame] | 5550 | static void tiger8_393(skiatest::Reporter* reporter, const char* filename) { |
| 5551 | SkPath path; |
| 5552 | path.setFillType((SkPath::FillType) 0); |
| 5553 | path.moveTo(SkBits2Float(0x42b93333), SkBits2Float(0x43d5a666)); // 92.6f, 427.3f |
| 5554 | path.cubicTo(SkBits2Float(0x42b93333), SkBits2Float(0x43d5a666), SkBits2Float(0x42b5cccd), SkBits2Float(0x43da1999), SkBits2Float(0x42b80000), SkBits2Float(0x43ddf333)); // 92.6f, 427.3f, 90.9f, 436.2f, 92, 443.9f |
| 5555 | path.cubicTo(SkBits2Float(0x42b80000), SkBits2Float(0x43ddf333), SkBits2Float(0x42b30000), SkBits2Float(0x43e17333), SkBits2Float(0x42cf999a), SkBits2Float(0x43e1b333)); // 92, 443.9f, 89.5f, 450.9f, 103.8f, 451.4f |
| 5556 | path.cubicTo(SkBits2Float(0x42ec3334), SkBits2Float(0x43e14ccd), SkBits2Float(0x42e73334), SkBits2Float(0x43ddf333), SkBits2Float(0x42e73334), SkBits2Float(0x43ddf333)); // 118.1f, 450.6f, 115.6f, 443.9f, 115.6f, 443.9f |
| 5557 | path.cubicTo(SkBits2Float(0x42e7999a), SkBits2Float(0x43de8000), SkBits2Float(0x42ea6667), SkBits2Float(0x43db4000), SkBits2Float(0x42e60001), SkBits2Float(0x43d5a666)); // 115.8f, 445, 117.2f, 438.5f, 115, 427.3f |
| 5558 | testSimplify(reporter, path, filename); |
| 5559 | } |
| 5560 | |
caryclark | 78a37a5 | 2016-10-20 12:36:16 -0700 | [diff] [blame] | 5561 | // triggers angle assert from distance field code |
| 5562 | static void carsvg_1(skiatest::Reporter* reporter, const char* filename) { |
| 5563 | SkPath path; |
| 5564 | path.setFillType((SkPath::FillType) 0); |
| 5565 | path.moveTo(SkBits2Float(0x4393d61e), SkBits2Float(0x43e768f9)); // 295.673f, 462.82f |
| 5566 | path.cubicTo(SkBits2Float(0x4396b50e), SkBits2Float(0x43e63c20), SkBits2Float(0x43998931), SkBits2Float(0x43e6c43e), SkBits2Float(0x439cb6a8), SkBits2Float(0x43e70ef9)); // 301.414f, 460.47f, 307.072f, 461.533f, 313.427f, 462.117f |
| 5567 | path.cubicTo(SkBits2Float(0x439dfc1e), SkBits2Float(0x43e72ce0), SkBits2Float(0x439a285c), SkBits2Float(0x43e717fb), SkBits2Float(0x4398e23c), SkBits2Float(0x43e7027c)); // 315.97f, 462.351f, 308.315f, 462.187f, 305.767f, 462.019f |
| 5568 | path.cubicTo(SkBits2Float(0x4398136f), SkBits2Float(0x43e6f4db), SkBits2Float(0x439a7e14), SkBits2Float(0x43e6d390), SkBits2Float(0x439b4ba9), SkBits2Float(0x43e6b956)); // 304.152f, 461.913f, 308.985f, 461.653f, 310.591f, 461.448f |
| 5569 | path.cubicTo(SkBits2Float(0x439c2b19), SkBits2Float(0x43e68603), SkBits2Float(0x43abf4df), SkBits2Float(0x43e9ca9e), SkBits2Float(0x43a1daea), SkBits2Float(0x43e912a5)); // 312.337f, 461.047f, 343.913f, 467.583f, 323.71f, 466.146f |
| 5570 | path.cubicTo(SkBits2Float(0x43a4f45a), SkBits2Float(0x43e78baf), SkBits2Float(0x43a2a391), SkBits2Float(0x43e86a82), SkBits2Float(0x43a946bd), SkBits2Float(0x43e90c56)); // 329.909f, 463.091f, 325.278f, 464.832f, 338.553f, 466.096f |
| 5571 | path.lineTo(SkBits2Float(0x43a4250b), SkBits2Float(0x43e998dc)); // 328.289f, 467.194f |
| 5572 | path.cubicTo(SkBits2Float(0x43a8a9c8), SkBits2Float(0x43e8f06c), SkBits2Float(0x43a95cb5), SkBits2Float(0x43e84ea6), SkBits2Float(0x43a6f7c1), SkBits2Float(0x43e9bdb5)); // 337.326f, 465.878f, 338.724f, 464.614f, 333.936f, 467.482f |
| 5573 | path.cubicTo(SkBits2Float(0x43a59ed0), SkBits2Float(0x43e9d2ca), SkBits2Float(0x4395ea4d), SkBits2Float(0x43e92afe), SkBits2Float(0x43a06569), SkBits2Float(0x43e7773d)); // 331.241f, 467.647f, 299.83f, 466.336f, 320.792f, 462.932f |
| 5574 | path.cubicTo(SkBits2Float(0x438bf0ff), SkBits2Float(0x43ea0fef), SkBits2Float(0x43a0e17a), SkBits2Float(0x43e5f41b), SkBits2Float(0x4398f3fb), SkBits2Float(0x43e804c8)); // 279.883f, 468.124f, 321.762f, 459.907f, 305.906f, 464.037f |
| 5575 | path.lineTo(SkBits2Float(0x4393d61e), SkBits2Float(0x43e768f9)); // 295.673f, 462.82f |
| 5576 | path.close(); |
| 5577 | |
| 5578 | testSimplify(reporter, path, filename); |
| 5579 | } |
| 5580 | |
caryclark | 34efb70 | 2016-10-24 08:19:06 -0700 | [diff] [blame] | 5581 | static void simplifyTest_1(skiatest::Reporter* reporter, const char* filename) { |
| 5582 | SkPath path; |
| 5583 | path.setFillType((SkPath::FillType) 0); |
| 5584 | path.moveTo(SkBits2Float(0x42bfefd4), SkBits2Float(0x42ef80ef)); // 95.9684f, 119.752f |
| 5585 | path.quadTo(SkBits2Float(0x42c26810), SkBits2Float(0x42e214b8), SkBits2Float(0x42cdcad5), SkBits2Float(0x42d82aa2)); // 97.2032f, 113.04f, 102.896f, 108.083f |
| 5586 | path.lineTo(SkBits2Float(0x42cdcb21), SkBits2Float(0x42d82a61)); // 102.897f, 108.083f |
| 5587 | path.quadTo(SkBits2Float(0x42d5e3c8), SkBits2Float(0x42d12140), SkBits2Float(0x42e20ee8), SkBits2Float(0x42cdc937)); // 106.945f, 104.565f, 113.029f, 102.893f |
| 5588 | path.lineTo(SkBits2Float(0x42e256e3), SkBits2Float(0x42cdbc92)); // 113.17f, 102.868f |
| 5589 | path.lineTo(SkBits2Float(0x42f5eadb), SkBits2Float(0x42cc2cb3)); // 122.959f, 102.087f |
| 5590 | path.lineTo(SkBits2Float(0x42f746a6), SkBits2Float(0x42cccf85)); // 123.638f, 102.405f |
| 5591 | path.quadTo(SkBits2Float(0x42fa586c), SkBits2Float(0x42d126c4), SkBits2Float(0x42f6c657), SkBits2Float(0x42d5d315)); // 125.173f, 104.576f, 123.387f, 106.912f |
| 5592 | path.lineTo(SkBits2Float(0x42f591eb), SkBits2Float(0x42d4e76d)); // 122.785f, 106.452f |
| 5593 | path.lineTo(SkBits2Float(0x42f6c6e0), SkBits2Float(0x42d5d261)); // 123.388f, 106.911f |
| 5594 | path.quadTo(SkBits2Float(0x42f6bb33), SkBits2Float(0x42d5e1bb), SkBits2Float(0x42f6a3d8), SkBits2Float(0x42d6007c)); // 123.366f, 106.941f, 123.32f, 107.001f |
| 5595 | path.quadTo(SkBits2Float(0x42ea3850), SkBits2Float(0x42e65af0), SkBits2Float(0x42d97a6e), SkBits2Float(0x42ed841c)); // 117.11f, 115.178f, 108.739f, 118.758f |
| 5596 | path.lineTo(SkBits2Float(0x42d91d92), SkBits2Float(0x42ed9ec0)); // 108.558f, 118.81f |
| 5597 | path.lineTo(SkBits2Float(0x42c1a959), SkBits2Float(0x42f146b0)); // 96.8308f, 120.638f |
| 5598 | path.lineTo(SkBits2Float(0x42bfefd4), SkBits2Float(0x42ef80f0)); // 95.9684f, 119.752f |
| 5599 | path.lineTo(SkBits2Float(0x42bfefd4), SkBits2Float(0x42ef80ef)); // 95.9684f, 119.752f |
| 5600 | path.close(); |
| 5601 | path.moveTo(SkBits2Float(0x42c2eb4e), SkBits2Float(0x42f00d68)); // 97.4596f, 120.026f |
| 5602 | path.lineTo(SkBits2Float(0x42c16d91), SkBits2Float(0x42efc72c)); // 96.714f, 119.889f |
| 5603 | path.lineTo(SkBits2Float(0x42c131c9), SkBits2Float(0x42ee47a8)); // 96.5972f, 119.14f |
| 5604 | path.lineTo(SkBits2Float(0x42d8a602), SkBits2Float(0x42ea9fb8)); // 108.324f, 117.312f |
| 5605 | path.lineTo(SkBits2Float(0x42d8e1ca), SkBits2Float(0x42ec1f3c)); // 108.441f, 118.061f |
| 5606 | path.lineTo(SkBits2Float(0x42d84926), SkBits2Float(0x42eaba5c)); // 108.143f, 117.364f |
| 5607 | path.quadTo(SkBits2Float(0x42e84a40), SkBits2Float(0x42e3e1f0), SkBits2Float(0x42f439a2), SkBits2Float(0x42d42af8)); // 116.145f, 113.941f, 122.113f, 106.084f |
| 5608 | path.quadTo(SkBits2Float(0x42f45121), SkBits2Float(0x42d40c08), SkBits2Float(0x42f45cf6), SkBits2Float(0x42d3fc79)); // 122.158f, 106.023f, 122.182f, 105.993f |
| 5609 | path.lineTo(SkBits2Float(0x42f45d7f), SkBits2Float(0x42d3fbc5)); // 122.183f, 105.992f |
| 5610 | path.quadTo(SkBits2Float(0x42f69510), SkBits2Float(0x42d114f4), SkBits2Float(0x42f4ccce), SkBits2Float(0x42ce8fb7)); // 123.291f, 104.541f, 122.4f, 103.281f |
| 5611 | path.lineTo(SkBits2Float(0x42f609ba), SkBits2Float(0x42cdaf9e)); // 123.019f, 102.843f |
| 5612 | path.lineTo(SkBits2Float(0x42f62899), SkBits2Float(0x42cf3289)); // 123.079f, 103.599f |
| 5613 | path.lineTo(SkBits2Float(0x42e294a1), SkBits2Float(0x42d0c268)); // 113.29f, 104.38f |
| 5614 | path.lineTo(SkBits2Float(0x42e275c2), SkBits2Float(0x42cf3f7d)); // 113.23f, 103.624f |
| 5615 | path.lineTo(SkBits2Float(0x42e2dc9c), SkBits2Float(0x42d0b5c3)); // 113.431f, 104.355f |
| 5616 | path.quadTo(SkBits2Float(0x42d75bb8), SkBits2Float(0x42d3df08), SkBits2Float(0x42cfc853), SkBits2Float(0x42da7457)); // 107.679f, 105.936f, 103.891f, 109.227f |
| 5617 | path.lineTo(SkBits2Float(0x42cec9ba), SkBits2Float(0x42d94f5c)); // 103.394f, 108.655f |
| 5618 | path.lineTo(SkBits2Float(0x42cfc89f), SkBits2Float(0x42da7416)); // 103.892f, 109.227f |
| 5619 | path.quadTo(SkBits2Float(0x42c53268), SkBits2Float(0x42e3ac00), SkBits2Float(0x42c2eb4e), SkBits2Float(0x42f00d67)); // 98.5984f, 113.836f, 97.4596f, 120.026f |
| 5620 | path.lineTo(SkBits2Float(0x42c2eb4e), SkBits2Float(0x42f00d68)); // 97.4596f, 120.026f |
| 5621 | path.close(); |
| 5622 | |
| 5623 | testSimplify(reporter, path, filename); |
| 5624 | } |
| 5625 | |
caryclark | 5435929 | 2015-03-26 07:52:43 -0700 | [diff] [blame] | 5626 | static void (*skipTest)(skiatest::Reporter* , const char* filename) = 0; |
caryclark | 34efb70 | 2016-10-24 08:19:06 -0700 | [diff] [blame] | 5627 | static void (*firstTest)(skiatest::Reporter* , const char* filename) = testQuads69; |
caryclark | 5435929 | 2015-03-26 07:52:43 -0700 | [diff] [blame] | 5628 | static void (*stopTest)(skiatest::Reporter* , const char* filename) = 0; |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 5629 | |
| 5630 | static TestDesc tests[] = { |
caryclark | 34efb70 | 2016-10-24 08:19:06 -0700 | [diff] [blame] | 5631 | TEST(simplifyTest_1), |
caryclark | 78a37a5 | 2016-10-20 12:36:16 -0700 | [diff] [blame] | 5632 | TEST(carsvg_1), |
caryclark | b36a3cd | 2016-10-18 07:59:44 -0700 | [diff] [blame] | 5633 | TEST(tiger8_393), |
caryclark | e3a4e99 | 2016-09-28 09:22:17 -0700 | [diff] [blame] | 5634 | TEST(bug5169), |
caryclark | 27c015d | 2016-09-23 05:47:20 -0700 | [diff] [blame] | 5635 | TEST(testQuads73), |
caryclark | 55888e4 | 2016-07-18 10:01:36 -0700 | [diff] [blame] | 5636 | TEST(testQuads72), |
| 5637 | TEST(testQuads71), |
| 5638 | TEST(testQuads70), |
| 5639 | TEST(testQuads69), |
| 5640 | TEST(testQuads68), |
| 5641 | TEST(testQuads67), |
| 5642 | TEST(testQuads66), |
| 5643 | TEST(dean4), |
caryclark | 2bec26a | 2016-05-26 09:01:47 -0700 | [diff] [blame] | 5644 | TEST(fuzz763_4713_b), |
caryclark | 1c9ce61 | 2015-11-20 14:06:28 -0800 | [diff] [blame] | 5645 | TEST(fuzz_twister2), |
caryclark | 26ad22a | 2015-10-16 09:03:38 -0700 | [diff] [blame] | 5646 | TEST(fuzz_twister), |
caryclark | ef2e4ac | 2015-09-23 18:07:51 -0700 | [diff] [blame] | 5647 | TEST(fuzz994s_3414), |
| 5648 | TEST(fuzz994s_11), |
caryclark | bb13433 | 2015-07-28 05:12:19 -0700 | [diff] [blame] | 5649 | TEST(cr514118), |
caryclark | d434972 | 2015-07-23 12:40:22 -0700 | [diff] [blame] | 5650 | TEST(fuzz864a), |
caryclark | 27c8eb8 | 2015-07-06 11:38:33 -0700 | [diff] [blame] | 5651 | TEST(testQuads65), |
caryclark | 4e1a4c9 | 2015-05-18 12:56:57 -0700 | [diff] [blame] | 5652 | TEST(testIssue3838_3), |
caryclark | fba9da7 | 2015-05-14 14:18:13 -0700 | [diff] [blame] | 5653 | TEST(testIssue3838), |
caryclark | bca19f7 | 2015-05-13 08:23:48 -0700 | [diff] [blame] | 5654 | TEST(testArc), |
caryclark | 624637c | 2015-05-11 07:21:27 -0700 | [diff] [blame] | 5655 | TEST(testTriangle2), |
| 5656 | TEST(testTriangle1), |
caryclark | 1049f12 | 2015-04-20 08:31:59 -0700 | [diff] [blame] | 5657 | TEST(testQuads64), |
| 5658 | TEST(testQuads63), |
| 5659 | TEST(testQuads62), |
| 5660 | TEST(testRect4), |
caryclark | 19eb3b2 | 2014-07-18 05:08:14 -0700 | [diff] [blame] | 5661 | TEST(testRect3), |
caryclark | dac1d17 | 2014-06-17 05:15:38 -0700 | [diff] [blame] | 5662 | TEST(testQuadralateral10), |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 5663 | TEST(testQuads61), |
| 5664 | TEST(testQuads60), |
| 5665 | TEST(testQuads59), |
| 5666 | TEST(testQuads58), |
| 5667 | TEST(testQuads57), |
| 5668 | TEST(testQuads56), |
| 5669 | TEST(testQuads54), |
| 5670 | TEST(testQuads53), |
| 5671 | TEST(testQuads52), |
| 5672 | TEST(testQuads51), |
| 5673 | TEST(testQuads50), |
| 5674 | TEST(testQuads49), |
| 5675 | TEST(testQuads48), |
| 5676 | TEST(testQuads47), |
| 5677 | TEST(testQuads46x), |
| 5678 | TEST(testQuads45), |
| 5679 | TEST(testQuads44), |
| 5680 | TEST(testQuads43), |
| 5681 | TEST(testQuads42), |
| 5682 | TEST(testQuads41), |
| 5683 | TEST(testQuads36), |
| 5684 | TEST(testQuads37), |
| 5685 | TEST(testQuads38), |
| 5686 | TEST(testQuads39), |
| 5687 | TEST(testQuads40), |
| 5688 | TEST(testQuads16), |
| 5689 | TEST(testQuads17), |
| 5690 | TEST(testQuads18), |
| 5691 | TEST(testQuads19), |
| 5692 | TEST(testQuads20), |
| 5693 | TEST(testQuads21), |
| 5694 | TEST(testQuads22), |
| 5695 | TEST(testQuads23), |
| 5696 | TEST(testQuads24), |
| 5697 | TEST(testQuads25), |
| 5698 | TEST(testQuads26), |
| 5699 | TEST(testQuads27), |
| 5700 | TEST(testQuads28), |
| 5701 | TEST(testQuads29), |
| 5702 | TEST(testQuads30), |
| 5703 | TEST(testQuads31), |
| 5704 | TEST(testQuads32), |
| 5705 | TEST(testQuads33), |
| 5706 | TEST(testQuads34), |
| 5707 | TEST(testQuads35), |
| 5708 | TEST(testDegenerates1), |
| 5709 | TEST(testQuad13), |
| 5710 | TEST(testQuad14), |
| 5711 | TEST(testQuad15), |
| 5712 | TEST(testQuadratic56), |
| 5713 | TEST(testQuadralateral4), |
| 5714 | TEST(testQuadralateral3), |
| 5715 | TEST(testDegenerate5), |
| 5716 | TEST(testQuad12), |
caryclark | 5435929 | 2015-03-26 07:52:43 -0700 | [diff] [blame] | 5717 | TEST(testQuadratic51), |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 5718 | TEST(testQuad8), |
caryclark@google.com | 28d219c | 2013-11-25 13:39:12 +0000 | [diff] [blame] | 5719 | TEST(testQuad11), |
commit-bot@chromium.org | 866f4e3 | 2013-11-21 17:04:29 +0000 | [diff] [blame] | 5720 | TEST(testQuad10), |
| 5721 | TEST(testQuad9), |
caryclark@google.com | 7eaa53d | 2013-10-02 14:49:34 +0000 | [diff] [blame] | 5722 | TEST(testTriangles4x), |
caryclark@google.com | 570863f | 2013-09-16 15:55:01 +0000 | [diff] [blame] | 5723 | TEST(testTriangles3x), |
| 5724 | TEST(testRect2), |
| 5725 | TEST(testRect1), |
| 5726 | TEST(tooCloseTest), |
caryclark@google.com | 07e97fc | 2013-07-08 17:17:02 +0000 | [diff] [blame] | 5727 | TEST(skphealth_com76), |
caryclark@google.com | cffbcc3 | 2013-06-04 17:59:42 +0000 | [diff] [blame] | 5728 | TEST(testQuadLineIntersect1), |
| 5729 | TEST(testQuadLineIntersect2), |
| 5730 | TEST(testQuadLineIntersect3), |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 5731 | TEST(testQuad7), |
| 5732 | TEST(testQuad6), |
| 5733 | TEST(testQuad5), |
| 5734 | TEST(testQuad4), |
| 5735 | TEST(testQuad3), |
| 5736 | TEST(testQuad2), |
caryclark@google.com | 66560ca | 2013-04-26 19:51:16 +0000 | [diff] [blame] | 5737 | TEST(testAddTCoincident2), |
| 5738 | TEST(testAddTCoincident1), |
caryclark@google.com | 0361032 | 2013-04-18 15:58:21 +0000 | [diff] [blame] | 5739 | TEST(testTriangles2), |
| 5740 | TEST(testTriangles1), |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 5741 | TEST(testQuadratic97), |
| 5742 | TEST(testQuadratic96), |
| 5743 | TEST(testQuadratic95), |
| 5744 | TEST(testQuadratic94), |
caryclark@google.com | e942bc3 | 2013-04-10 18:53:01 +0000 | [diff] [blame] | 5745 | TEST(testQuadralateral2), |
caryclark@google.com | a5e5592 | 2013-05-07 18:51:31 +0000 | [diff] [blame] | 5746 | TEST(testQuad1), |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 5747 | TEST(testCubic2), |
| 5748 | TEST(testCubic1), |
| 5749 | TEST(testQuadralateral1), |
| 5750 | TEST(testLine85), |
| 5751 | TEST(testLine84), |
| 5752 | TEST(testLine84x), |
| 5753 | TEST(testLine83), |
| 5754 | TEST(testLine82h), |
| 5755 | TEST(testLine82g), |
| 5756 | TEST(testLine82f), |
| 5757 | TEST(testLine82e), |
| 5758 | TEST(testLine82d), |
| 5759 | TEST(testLine82c), |
| 5760 | TEST(testLine82b), |
| 5761 | TEST(testLine82a), |
| 5762 | TEST(testLine82), |
| 5763 | TEST(testQuadratic93), |
| 5764 | TEST(testQuadratic92x), |
| 5765 | TEST(testQuadratic91), |
| 5766 | TEST(testQuadratic90x), |
| 5767 | TEST(testQuadratic89x), |
| 5768 | TEST(testQuadratic88), |
| 5769 | TEST(testQuadratic87), |
| 5770 | TEST(testQuadratic86), |
| 5771 | TEST(testQuadratic85), |
| 5772 | TEST(testQuadratic84), |
| 5773 | TEST(testQuadratic83), |
| 5774 | TEST(testQuadratic82), |
| 5775 | TEST(testQuadratic81), |
| 5776 | TEST(testQuadratic80), |
| 5777 | TEST(testEight1), |
| 5778 | TEST(testEight2), |
| 5779 | TEST(testEight3), |
| 5780 | TEST(testEight4), |
| 5781 | TEST(testEight5), |
| 5782 | TEST(testEight6), |
| 5783 | TEST(testEight7), |
| 5784 | TEST(testEight8), |
| 5785 | TEST(testEight9), |
| 5786 | TEST(testEight10), |
| 5787 | TEST(testQuadratic79), |
| 5788 | TEST(testQuadratic78), |
| 5789 | TEST(testQuadratic77), |
| 5790 | TEST(testQuadratic76), |
| 5791 | TEST(testQuadratic75), |
| 5792 | TEST(testQuadratic74), |
| 5793 | TEST(testQuadratic73), |
| 5794 | TEST(testQuadratic72), |
| 5795 | TEST(testQuadratic71), |
| 5796 | TEST(testQuadratic70x), |
| 5797 | TEST(testQuadratic69), |
| 5798 | TEST(testQuadratic68), |
| 5799 | TEST(testQuadratic67x), |
| 5800 | TEST(testQuadratic65), |
| 5801 | TEST(testQuadratic64), |
| 5802 | TEST(testQuadratic63), |
| 5803 | TEST(testLine1a), |
| 5804 | TEST(testLine1ax), |
| 5805 | TEST(testQuadratic59), |
| 5806 | TEST(testQuadratic59x), |
| 5807 | TEST(testQuadratic58), |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 5808 | TEST(testQuadratic55), |
| 5809 | TEST(testQuadratic53), |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 5810 | TEST(testQuadratic38), |
| 5811 | TEST(testQuadratic37), |
| 5812 | TEST(testQuadratic36), |
| 5813 | TEST(testQuadratic35), |
| 5814 | TEST(testQuadratic34), |
| 5815 | TEST(testQuadratic33), |
| 5816 | TEST(testQuadratic32), |
| 5817 | TEST(testQuadratic31), |
| 5818 | TEST(testQuadratic30), |
| 5819 | TEST(testQuadratic29), |
| 5820 | TEST(testQuadratic28), |
| 5821 | TEST(testQuadratic27), |
| 5822 | TEST(testQuadratic26), |
| 5823 | TEST(testQuadratic25), |
| 5824 | TEST(testQuadratic24), |
| 5825 | TEST(testQuadratic23), |
| 5826 | TEST(testQuadratic22), |
| 5827 | TEST(testQuadratic21), |
| 5828 | TEST(testQuadratic20), |
| 5829 | TEST(testQuadratic19), |
| 5830 | TEST(testQuadratic18), |
| 5831 | TEST(testQuadratic17x), |
| 5832 | TEST(testQuadratic15), |
| 5833 | TEST(testQuadratic14), |
| 5834 | TEST(testQuadratic9), |
| 5835 | TEST(testQuadratic8), |
| 5836 | TEST(testQuadratic7), |
| 5837 | TEST(testQuadratic6), |
| 5838 | TEST(testQuadratic5), |
| 5839 | TEST(testQuadratic4x), |
| 5840 | TEST(testQuadratic3x), |
| 5841 | TEST(testQuadratic2x), |
| 5842 | TEST(testQuadratic1x), |
| 5843 | TEST(testQuadratic4), |
| 5844 | TEST(testQuadratic3), |
| 5845 | TEST(testQuadratic2), |
| 5846 | TEST(testQuadratic1), |
| 5847 | TEST(testLine4ax), |
| 5848 | TEST(testLine3aax), |
| 5849 | TEST(testLine2ax), |
| 5850 | TEST(testLine1ax), |
| 5851 | TEST(testQuadralateral9x), |
| 5852 | TEST(testQuadralateral8x), |
| 5853 | TEST(testQuadralateral7x), |
| 5854 | TEST(testQuadralateral6x), |
| 5855 | TEST(testQuadralateral6ax), |
| 5856 | TEST(testQuadralateral9), |
| 5857 | TEST(testQuadralateral8), |
| 5858 | TEST(testQuadralateral7), |
| 5859 | TEST(testQuadralateral6), |
| 5860 | TEST(testQuadralateral6a), |
| 5861 | TEST(testFauxQuadralateral6dx), |
| 5862 | TEST(testFauxQuadralateral6cx), |
| 5863 | TEST(testFauxQuadralateral6bx), |
| 5864 | TEST(testFauxQuadralateral6ax), |
| 5865 | TEST(testFauxQuadralateral6x), |
| 5866 | TEST(testFauxQuadralateral6d), |
| 5867 | TEST(testFauxQuadralateral6c), |
| 5868 | TEST(testFauxQuadralateral6b), |
| 5869 | TEST(testFauxQuadralateral6a), |
| 5870 | TEST(testFauxQuadralateral6), |
| 5871 | TEST(testQuadralateral5x), |
| 5872 | TEST(testQuadralateral5), |
| 5873 | TEST(testNondegenerate4x), |
| 5874 | TEST(testNondegenerate3x), |
| 5875 | TEST(testNondegenerate2x), |
| 5876 | TEST(testNondegenerate1x), |
| 5877 | TEST(testNondegenerate4), |
| 5878 | TEST(testNondegenerate3), |
| 5879 | TEST(testNondegenerate2), |
| 5880 | TEST(testNondegenerate1), |
| 5881 | TEST(testDegenerate4x), |
| 5882 | TEST(testDegenerate3x), |
| 5883 | TEST(testDegenerate2x), |
| 5884 | TEST(testDegenerate1x), |
| 5885 | TEST(testDegenerate4), |
| 5886 | TEST(testDegenerate3), |
| 5887 | TEST(testDegenerate2), |
| 5888 | TEST(testDegenerate1), |
| 5889 | TEST(testLine79x), |
| 5890 | TEST(testLine78x), |
| 5891 | TEST(testLine77x), |
| 5892 | TEST(testLine76x), |
| 5893 | TEST(testLine75x), |
| 5894 | TEST(testLine74x), |
| 5895 | TEST(testLine73x), |
| 5896 | TEST(testLine72x), |
| 5897 | TEST(testLine71x), |
| 5898 | TEST(testLine70x), |
| 5899 | TEST(testLine69x), |
| 5900 | TEST(testLine68hx), |
| 5901 | TEST(testLine68gx), |
| 5902 | TEST(testLine68fx), |
| 5903 | TEST(testLine68ex), |
| 5904 | TEST(testLine68dx), |
| 5905 | TEST(testLine68cx), |
| 5906 | TEST(testLine68bx), |
| 5907 | TEST(testLine68ax), |
| 5908 | TEST(testLine67x), |
| 5909 | TEST(testLine66x), |
| 5910 | TEST(testLine65x), |
| 5911 | TEST(testLine64x), |
| 5912 | TEST(testLine63x), |
| 5913 | TEST(testLine62x), |
| 5914 | TEST(testLine61x), |
| 5915 | TEST(testLine60x), |
| 5916 | TEST(testLine59x), |
| 5917 | TEST(testLine58x), |
| 5918 | TEST(testLine57x), |
| 5919 | TEST(testLine56x), |
| 5920 | TEST(testLine55x), |
| 5921 | TEST(testLine54x), |
| 5922 | TEST(testLine53x), |
| 5923 | TEST(testLine52x), |
| 5924 | TEST(testLine51x), |
| 5925 | TEST(testLine50x), |
| 5926 | TEST(testLine49x), |
| 5927 | TEST(testLine48x), |
| 5928 | TEST(testLine47x), |
| 5929 | TEST(testLine46x), |
| 5930 | TEST(testLine45x), |
| 5931 | TEST(testLine44x), |
| 5932 | TEST(testLine43x), |
| 5933 | TEST(testLine42x), |
| 5934 | TEST(testLine41x), |
| 5935 | TEST(testLine40x), |
| 5936 | TEST(testLine38x), |
| 5937 | TEST(testLine37x), |
| 5938 | TEST(testLine36x), |
| 5939 | TEST(testLine35x), |
| 5940 | TEST(testLine34x), |
| 5941 | TEST(testLine33x), |
| 5942 | TEST(testLine32x), |
| 5943 | TEST(testLine31x), |
| 5944 | TEST(testLine30x), |
| 5945 | TEST(testLine29x), |
| 5946 | TEST(testLine28x), |
| 5947 | TEST(testLine27x), |
| 5948 | TEST(testLine26x), |
| 5949 | TEST(testLine25x), |
| 5950 | TEST(testLine24ax), |
| 5951 | TEST(testLine24x), |
| 5952 | TEST(testLine23x), |
| 5953 | TEST(testLine22x), |
| 5954 | TEST(testLine21x), |
| 5955 | TEST(testLine20x), |
| 5956 | TEST(testLine19x), |
| 5957 | TEST(testLine18x), |
| 5958 | TEST(testLine17x), |
| 5959 | TEST(testLine16x), |
| 5960 | TEST(testLine15x), |
| 5961 | TEST(testLine14x), |
| 5962 | TEST(testLine13x), |
| 5963 | TEST(testLine12x), |
| 5964 | TEST(testLine11x), |
| 5965 | TEST(testLine10ax), |
| 5966 | TEST(testLine10x), |
| 5967 | TEST(testLine9x), |
| 5968 | TEST(testLine8x), |
| 5969 | TEST(testLine7bx), |
| 5970 | TEST(testLine7ax), |
| 5971 | TEST(testLine7x), |
| 5972 | TEST(testLine6x), |
| 5973 | TEST(testLine5x), |
| 5974 | TEST(testLine4x), |
| 5975 | TEST(testLine3bx), |
| 5976 | TEST(testLine3ax), |
| 5977 | TEST(testLine3x), |
| 5978 | TEST(testLine2x), |
| 5979 | TEST(testLine1x), |
| 5980 | TEST(testLine81), |
| 5981 | TEST(testLine80), |
| 5982 | TEST(testLine79), |
| 5983 | TEST(testLine78), |
| 5984 | TEST(testLine77), |
| 5985 | TEST(testLine76), |
| 5986 | TEST(testLine75), |
| 5987 | TEST(testLine74), |
| 5988 | TEST(testLine73), |
| 5989 | TEST(testLine72), |
| 5990 | TEST(testLine71), |
| 5991 | TEST(testLine70), |
| 5992 | TEST(testLine69), |
| 5993 | TEST(testLine68h), |
| 5994 | TEST(testLine68g), |
| 5995 | TEST(testLine68f), |
| 5996 | TEST(testLine68e), |
| 5997 | TEST(testLine68d), |
| 5998 | TEST(testLine68c), |
| 5999 | TEST(testLine68b), |
| 6000 | TEST(testLine68a), |
| 6001 | TEST(testLine67), |
| 6002 | TEST(testLine66), |
| 6003 | TEST(testLine65), |
| 6004 | TEST(testLine64), |
| 6005 | TEST(testLine63), |
| 6006 | TEST(testLine62), |
| 6007 | TEST(testLine61), |
| 6008 | TEST(testLine60), |
| 6009 | TEST(testLine59), |
| 6010 | TEST(testLine58), |
| 6011 | TEST(testLine57), |
| 6012 | TEST(testLine56), |
| 6013 | TEST(testLine55), |
| 6014 | TEST(testLine54), |
| 6015 | TEST(testLine53), |
| 6016 | TEST(testLine52), |
| 6017 | TEST(testLine51), |
| 6018 | TEST(testLine50), |
| 6019 | TEST(testLine49), |
| 6020 | TEST(testLine48), |
| 6021 | TEST(testLine47), |
| 6022 | TEST(testLine46), |
| 6023 | TEST(testLine45), |
| 6024 | TEST(testLine44), |
| 6025 | TEST(testLine43), |
| 6026 | TEST(testLine42), |
| 6027 | TEST(testLine41), |
| 6028 | TEST(testLine40), |
| 6029 | TEST(testLine38), |
| 6030 | TEST(testLine37), |
| 6031 | TEST(testLine36), |
| 6032 | TEST(testLine35), |
| 6033 | TEST(testLine34), |
| 6034 | TEST(testLine33), |
| 6035 | TEST(testLine32), |
| 6036 | TEST(testLine31), |
| 6037 | TEST(testLine30), |
| 6038 | TEST(testLine29), |
| 6039 | TEST(testLine28), |
| 6040 | TEST(testLine27), |
| 6041 | TEST(testLine26), |
| 6042 | TEST(testLine25), |
| 6043 | TEST(testLine24a), |
| 6044 | TEST(testLine24), |
| 6045 | TEST(testLine23), |
| 6046 | TEST(testLine22), |
| 6047 | TEST(testLine21), |
| 6048 | TEST(testLine20), |
| 6049 | TEST(testLine19), |
| 6050 | TEST(testLine18), |
| 6051 | TEST(testLine17), |
| 6052 | TEST(testLine16), |
| 6053 | TEST(testLine15), |
| 6054 | TEST(testLine14), |
| 6055 | TEST(testLine13), |
| 6056 | TEST(testLine12), |
| 6057 | TEST(testLine11), |
| 6058 | TEST(testLine10a), |
| 6059 | TEST(testLine10), |
| 6060 | TEST(testLine9), |
| 6061 | TEST(testLine8), |
| 6062 | TEST(testLine7b), |
| 6063 | TEST(testLine7a), |
| 6064 | TEST(testLine7), |
| 6065 | TEST(testLine6), |
| 6066 | TEST(testLine5), |
| 6067 | TEST(testLine4), |
| 6068 | TEST(testLine3b), |
| 6069 | TEST(testLine3a), |
| 6070 | TEST(testLine3), |
| 6071 | TEST(testLine2), |
| 6072 | TEST(testLine1), |
| 6073 | }; |
| 6074 | |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 6075 | static const size_t testCount = SK_ARRAY_COUNT(tests); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6076 | |
| 6077 | static TestDesc subTests[] = { |
caryclark | ef2e4ac | 2015-09-23 18:07:51 -0700 | [diff] [blame] | 6078 | TEST(fuzz994s_3414), |
| 6079 | TEST(fuzz994s_11), |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6080 | }; |
| 6081 | |
caryclark@google.com | ad65a3e | 2013-04-15 19:13:59 +0000 | [diff] [blame] | 6082 | static const size_t subTestCount = SK_ARRAY_COUNT(subTests); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6083 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 6084 | static void (*firstSubTest)(skiatest::Reporter* , const char* filename) = 0; |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6085 | |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 6086 | static bool runSubTests = false; |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6087 | static bool runSubTestsFirst = false; |
caryclark@google.com | 4fdbb22 | 2013-07-23 15:27:41 +0000 | [diff] [blame] | 6088 | static bool runReverse = false; |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6089 | |
tfarina@chromium.org | 78e7b4e | 2014-01-02 21:45:03 +0000 | [diff] [blame] | 6090 | DEF_TEST(PathOpsSimplify, reporter) { |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 6091 | if (runSubTests && runSubTestsFirst) { |
halcanary | 96fcdcc | 2015-08-27 07:41:13 -0700 | [diff] [blame] | 6092 | RunTestSet(reporter, subTests, subTestCount, firstSubTest, nullptr, stopTest, runReverse); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6093 | } |
caryclark | 5435929 | 2015-03-26 07:52:43 -0700 | [diff] [blame] | 6094 | RunTestSet(reporter, tests, testCount, firstTest, skipTest, stopTest, runReverse); |
commit-bot@chromium.org | 4431e77 | 2014-04-14 17:08:59 +0000 | [diff] [blame] | 6095 | if (runSubTests && !runSubTestsFirst) { |
halcanary | 96fcdcc | 2015-08-27 07:41:13 -0700 | [diff] [blame] | 6096 | RunTestSet(reporter, subTests, subTestCount, firstSubTest, nullptr, stopTest, runReverse); |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6097 | } |
caryclark@google.com | 818b0cc | 2013-04-08 11:50:46 +0000 | [diff] [blame] | 6098 | } |