caryclark@google.com | 32546db | 2012-08-31 20:55:07 +0000 | [diff] [blame] | 1 | <!-- path visualizer --> |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2 | <html> |
| 3 | <head> |
| 4 | <div style="height:0"> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 5 | |
| 6 | <div id="testSimplifyQuadratic1"> |
| 7 | SkPath path, out; |
| 8 | path.moveTo(0, 0); |
| 9 | path.quadTo(1, 0, 1, 1); |
| 10 | path.close(); |
| 11 | path.moveTo(1, 0); |
| 12 | path.quadTo(0, 0, 0, 1); |
| 13 | path.close(); |
| 14 | testSimplify(path, true, out, bitmap); |
| 15 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 16 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 17 | |
| 18 | <div id="testSimplifyQuadratic2"> |
| 19 | SkPath path, out; |
| 20 | path.moveTo(0, 0); |
| 21 | path.quadTo(20, 0, 20, 20); |
| 22 | path.close(); |
| 23 | path.moveTo(20, 0); |
| 24 | path.quadTo(0, 0, 0, 20); |
| 25 | path.close(); |
| 26 | testSimplify(path, true, out, bitmap); |
| 27 | } |
caryclark@google.com | d88e089 | 2012-03-27 13:23:51 +0000 | [diff] [blame] | 28 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 29 | |
| 30 | <div id="testSimplifyQuadratic3"> |
| 31 | SkPath path, out; |
| 32 | path.moveTo(0, 0); |
| 33 | path.quadTo(20, 0, 20, 20); |
| 34 | path.close(); |
| 35 | path.moveTo(0, 20); |
| 36 | path.quadTo(0, 0, 20, 0); |
| 37 | path.close(); |
| 38 | testSimplify(path, true, out, bitmap); |
| 39 | } |
caryclark@google.com | d88e089 | 2012-03-27 13:23:51 +0000 | [diff] [blame] | 40 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 41 | |
| 42 | <div id="testSimplifyQuadratic4"> |
| 43 | SkPath path, out; |
| 44 | path.moveTo(0, 20); |
| 45 | path.quadTo(20, 0, 40, 20); |
| 46 | path.close(); |
| 47 | path.moveTo(40, 10); |
| 48 | path.quadTo(20, 30, 0, 10); |
| 49 | path.close(); |
| 50 | testSimplify(path, true, out, bitmap); |
| 51 | drawAsciiPaths(path, out, true); |
| 52 | } |
caryclark@google.com | d88e089 | 2012-03-27 13:23:51 +0000 | [diff] [blame] | 53 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 54 | |
| 55 | <div id="testSimplifyQuadratic5"> |
| 56 | SkPath path, out; |
| 57 | path.moveTo(0, 0); |
| 58 | path.quadTo(0, 0, 0, 0); |
| 59 | path.lineTo(0, 0); |
| 60 | path.close(); |
| 61 | path.moveTo(0, 0); |
| 62 | path.lineTo(0, 0); |
| 63 | path.quadTo(0, 0, 0, 1); |
| 64 | path.close(); |
| 65 | testSimplify(path, true, out, bitmap); |
| 66 | drawAsciiPaths(path, out, true); |
| 67 | } |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 68 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 69 | |
| 70 | <div id="testSimplifyQuadratic6"> |
| 71 | SkPath path, out; |
| 72 | path.moveTo(0, 0); |
| 73 | path.quadTo(0, 0, 0, 0); |
| 74 | path.lineTo(1, 0); |
| 75 | path.close(); |
| 76 | path.moveTo(0, 0); |
| 77 | path.lineTo(0, 0); |
| 78 | path.quadTo(1, 0, 0, 1); |
| 79 | path.close(); |
| 80 | testSimplify(path, true, out, bitmap); |
| 81 | drawAsciiPaths(path, out, true); |
| 82 | } |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 83 | </div> |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 84 | |
| 85 | <div id="testSimplifyQuadratic7"> |
| 86 | SkPath path, out; |
| 87 | path.moveTo(0, 0); |
| 88 | path.quadTo(0, 0, 0, 0); |
| 89 | path.lineTo(0, 1); |
| 90 | path.close(); |
| 91 | path.moveTo(0, 0); |
| 92 | path.lineTo(0, 0); |
| 93 | path.quadTo(1, 0, 0, 2); |
| 94 | path.close(); |
| 95 | testSimplify(path, true, out, bitmap); |
| 96 | drawAsciiPaths(path, out, true); |
| 97 | } |
| 98 | </div> |
| 99 | |
| 100 | <div id="testSimplifyQuadratic8"> |
| 101 | SkPath path, out; |
| 102 | path.moveTo(0, 0); |
| 103 | path.quadTo(0, 0, 0, 0); |
| 104 | path.lineTo(0, 0); |
| 105 | path.close(); |
| 106 | path.moveTo(0, 0); |
| 107 | path.lineTo(0, 0); |
| 108 | path.quadTo(1, 0, 0, 2); |
| 109 | path.close(); |
| 110 | testSimplify(path, true, out, bitmap); |
| 111 | drawAsciiPaths(path, out, true); |
| 112 | } |
| 113 | </div> |
| 114 | |
| 115 | <div id="testSimplifyQuadratic9"> |
| 116 | SkPath path, out; |
| 117 | path.moveTo(0, 0); |
| 118 | path.quadTo(0, 0, 0, 0); |
| 119 | path.lineTo(1, 1); |
| 120 | path.close(); |
| 121 | path.moveTo(0, 0); |
| 122 | path.lineTo(0, 0); |
| 123 | path.quadTo(1, 0, 2, 2); |
| 124 | path.close(); |
| 125 | testSimplify(path, true, out, bitmap); |
| 126 | drawAsciiPaths(path, out, true); |
| 127 | } |
| 128 | </div> |
| 129 | |
| 130 | <div id="testSimplifyQuadratic10"> |
| 131 | SkPath path, out; |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 132 | path.moveTo(0, 0); |
| 133 | path.quadTo(0, 0, 0, 0); |
| 134 | path.lineTo(0, 0); |
| 135 | path.close(); |
| 136 | path.moveTo(0, 0); |
| 137 | path.lineTo(0, 1); |
| 138 | path.quadTo(1, 1, 1, 2); |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 139 | path.close(); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 140 | testSimplify(path, true, out, bitmap); |
| 141 | drawAsciiPaths(path, out, true); |
| 142 | } |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 143 | </div> |
| 144 | |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 145 | <div id="testSimplifyQuadratic11"> |
| 146 | SkPath path, out; |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 147 | path.moveTo(0, 0); |
| 148 | path.quadTo(0, 0, 0, 0); |
| 149 | path.lineTo(0, 2); |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 150 | path.close(); |
| 151 | path.moveTo(0, 0); |
| 152 | path.lineTo(2, 1); |
| 153 | path.quadTo(2, 2, 3, 3); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 154 | path.close(); |
| 155 | testSimplify(path, true, out, bitmap); |
| 156 | drawAsciiPaths(path, out, true); |
| 157 | } |
| 158 | </div> |
| 159 | |
| 160 | <div id="testSimplifyQuadratic12"> |
| 161 | SkPath path, out; |
| 162 | path.moveTo(0, 0); |
| 163 | path.lineTo(0, 2); |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 164 | path.lineTo(0, 0); |
| 165 | path.close(); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 166 | path.moveTo(3, 0); |
| 167 | path.quadTo(1, 1, 0, 2); |
| 168 | path.lineTo(3, 0); |
| 169 | path.close(); |
| 170 | testSimplify(path, true, out, bitmap); |
| 171 | drawAsciiPaths(path, out, true); |
| 172 | } |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 173 | </div> |
| 174 | |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 175 | <div id="testSimplifyQuadratic13"> |
| 176 | SkPath path, out; |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 177 | path.moveTo(0, 0); |
| 178 | path.quadTo(0, 0, 1, 0); |
| 179 | path.lineTo(1, 1); |
| 180 | path.lineTo(0, 0); |
| 181 | path.close(); |
| 182 | path.moveTo(0, 0); |
| 183 | path.quadTo(3, 0, 1, 1); |
| 184 | path.lineTo(0, 0); |
| 185 | path.close(); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 186 | testSimplify(path, true, out, bitmap); |
| 187 | drawAsciiPaths(path, out, true); |
| 188 | } |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 189 | </div> |
| 190 | |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 191 | <div id="testSimplifyQuadratic14"> |
| 192 | SkPath path, out; |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 193 | path.moveTo(0, 0); |
| 194 | path.quadTo(0, 0, 0, 0); |
| 195 | path.lineTo(1, 1); |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 196 | path.close(); |
| 197 | path.moveTo(0, 0); |
| 198 | path.lineTo(0, 0); |
| 199 | path.quadTo(0, 1, 2, 1); |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 200 | path.close(); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 201 | testSimplify(path, true, out, bitmap); |
| 202 | drawAsciiPaths(path, out, true); |
| 203 | } |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 204 | </div> |
| 205 | |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 206 | <div id="testSimplifyQuadratic15"> |
| 207 | SkPath path, out; |
| 208 | path.moveTo(0, 0); |
| 209 | path.quadTo(0, 0, 1, 3); |
| 210 | path.lineTo(3, 3); |
| 211 | path.close(); |
| 212 | path.moveTo(0, 1); |
| 213 | path.lineTo(1, 1); |
| 214 | path.quadTo(0, 3, 3, 3); |
| 215 | path.close(); |
| 216 | testSimplify(path, true, out, bitmap); |
| 217 | drawAsciiPaths(path, out, true); |
| 218 | } |
| 219 | </div> |
| 220 | |
| 221 | <div id="testSimplifyQuadratic16"> |
| 222 | SkPath path, out; |
| 223 | path.moveTo(0, 0); |
| 224 | path.quadTo(0, 0, 0, 0); |
| 225 | path.lineTo(0, 1); |
| 226 | path.close(); |
| 227 | path.moveTo(0, 0); |
| 228 | path.lineTo(0, 0); |
| 229 | path.quadTo(1, 0, 0, 1); |
| 230 | path.close(); |
| 231 | testSimplify(path, true, out, bitmap); |
| 232 | drawAsciiPaths(path, out, true); |
| 233 | } |
| 234 | </div> |
| 235 | |
| 236 | <div id="testSimplifyQuadratic17"> |
| 237 | SkPath path, out; |
caryclark@google.com | b45a1b4 | 2012-05-18 20:50:33 +0000 | [diff] [blame] | 238 | path.moveTo(8, 8); |
| 239 | path.quadTo(10, 10, 8, -10); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 240 | path.close(); |
caryclark@google.com | b45a1b4 | 2012-05-18 20:50:33 +0000 | [diff] [blame] | 241 | path.moveTo(8, 8); |
| 242 | path.quadTo(12, 12, 14, 4); |
| 243 | path.close(); |
| 244 | path.moveTo(8, 8); |
| 245 | path.quadTo(9, 9, 10, 8); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 246 | path.close(); |
| 247 | testSimplify(path, true, out, bitmap); |
| 248 | drawAsciiPaths(path, out, true); |
| 249 | } |
caryclark@google.com | 78e1713 | 2012-04-17 11:40:34 +0000 | [diff] [blame] | 250 | </div> |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 251 | |
caryclark@google.com | b45a1b4 | 2012-05-18 20:50:33 +0000 | [diff] [blame] | 252 | <div id="testSimplifyQuadratic18"> |
| 253 | SkPath path, out; |
| 254 | path.moveTo(8.0000000000000071, 8.0000000000000071); |
| 255 | path.quadTo(8.7289570079366854, 8.7289570079366889, 9.3914917259458743, 9.0593802763083691); |
| 256 | path.close(); |
| 257 | path.moveTo(8.0000000000000142, 8.0000000000000142); |
| 258 | path.quadTo(8.1250000000000107, 8.1250000000000071, 8.2500000000000071, 8.2187500000000053); |
| 259 | path.close(); |
| 260 | testSimplify(path, true, out, bitmap); |
| 261 | drawAsciiPaths(path, out, true); |
| 262 | </div> |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 263 | |
| 264 | <div id="testSimplifyQuadratic19"> |
| 265 | SkPath path, simple; |
| 266 | path.moveTo(0,4); |
| 267 | path.lineTo(6,4); |
| 268 | path.lineTo(3,1); |
| 269 | path.close(); |
| 270 | path.moveTo(2,3); |
| 271 | path.lineTo(3,2); |
| 272 | path.lineTo(4,3); |
| 273 | path.close(); |
| 274 | testSimplifyx(path); |
| 275 | </div> |
| 276 | |
| 277 | <div id="testSimplifyQuadratic20"> |
| 278 | SkPath path, simple; |
| 279 | path.moveTo(0,4); |
| 280 | path.lineTo(6,4); |
| 281 | path.lineTo(3,1); |
| 282 | path.close(); |
| 283 | path.moveTo(2,3); |
| 284 | path.lineTo(4,3); |
| 285 | path.lineTo(3,2); |
| 286 | path.close(); |
| 287 | testSimplifyx(path); |
| 288 | </div> |
| 289 | |
| 290 | <div id="testSimplifyQuadratic21"> |
| 291 | SkPath path, simple; |
| 292 | path.moveTo(0,4); |
| 293 | path.lineTo(8,4); |
| 294 | path.lineTo(4,0); |
| 295 | path.close(); |
| 296 | path.moveTo(2,2); |
| 297 | path.lineTo(3,3); |
| 298 | path.lineTo(4,2); |
| 299 | path.close(); |
| 300 | testSimplifyx(path); |
| 301 | </div> |
| 302 | |
| 303 | <div id="testLine6"> |
| 304 | SkPath path, simple; |
| 305 | path.moveTo(0,0); |
| 306 | path.lineTo(4,0); |
| 307 | path.lineTo(2,2); |
| 308 | path.close(); |
| 309 | path.moveTo(2,0); |
| 310 | path.lineTo(6,0); |
| 311 | path.lineTo(4,2); |
| 312 | path.close(); |
| 313 | testSimplifyx(path); |
| 314 | </div> |
| 315 | |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 316 | <div id="testLine7"> |
| 317 | SkPath path, simple; |
| 318 | path.moveTo(0,0); |
| 319 | path.lineTo(4,0); |
| 320 | path.lineTo(2,2); |
| 321 | path.close(); |
| 322 | path.moveTo(6,0); |
| 323 | path.lineTo(2,0); |
| 324 | path.lineTo(4,2); |
| 325 | path.close(); |
| 326 | testSimplifyx(path); |
| 327 | </div> |
| 328 | |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 329 | <div id="testLine7b"> |
| 330 | path.moveTo(0,0); |
| 331 | path.lineTo(4,0); |
| 332 | path.close(); |
| 333 | path.moveTo(6,0); |
| 334 | path.lineTo(2,0); |
| 335 | path.lineTo(4,2); |
| 336 | path.close(); |
| 337 | </div> |
| 338 | |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 339 | <div id="testLine9"> |
| 340 | SkPath path, simple; |
| 341 | path.moveTo(0,4); |
| 342 | path.lineTo(4,4); |
| 343 | path.lineTo(2,2); |
| 344 | path.close(); |
| 345 | path.moveTo(6,4); |
| 346 | path.lineTo(2,4); |
| 347 | path.lineTo(4,2); |
| 348 | path.close(); |
| 349 | testSimplifyx(path); |
| 350 | </div> |
| 351 | |
caryclark@google.com | e21cb18 | 2012-07-23 21:26:31 +0000 | [diff] [blame] | 352 | <div id="testLine12"> |
| 353 | path.moveTo(0,4); |
| 354 | path.lineTo(6,4); |
| 355 | path.lineTo(3,1); |
| 356 | path.close(); |
| 357 | path.moveTo(2,3); |
| 358 | path.lineTo(3,2); |
| 359 | path.lineTo(4,3); |
| 360 | path.close(); |
| 361 | </div> |
| 362 | |
| 363 | <div id="testLine13"> |
| 364 | path.moveTo(6,4); |
| 365 | path.lineTo(0,4); |
| 366 | path.lineTo(3,1); |
| 367 | path.close(); |
| 368 | path.moveTo(3,2); |
| 369 | path.lineTo(2,3); |
| 370 | path.lineTo(4,3); |
| 371 | path.close(); |
| 372 | </div> |
| 373 | |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 374 | <div id="testLine17"> |
| 375 | SkPath path, simple; |
| 376 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 377 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 0); |
| 378 | testSimplifyx(path); |
| 379 | </div> |
| 380 | |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 381 | <div id="testLine19"> |
| 382 | SkPath path, simple; |
| 383 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 384 | path.addRect(12, 16, 21, 21, (SkPath::Direction) 0); |
| 385 | testSimplifyx(path); |
| 386 | </div> |
| 387 | |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 388 | <div id="testLine22"> |
| 389 | path.addRect(0, 12, 12, 12, (SkPath::Direction) 0); |
| 390 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 0); |
| 391 | </div> |
| 392 | |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 393 | <div id="testLine24"> |
| 394 | path.addRect(0, 18, 12, 12, (SkPath::Direction) 0); |
| 395 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 0); |
| 396 | </div> |
| 397 | |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 398 | <div id="testLine28"> |
| 399 | SkPath path, simple; |
| 400 | path.addRect(0, 6, 12, 12, (SkPath::Direction) 0); |
| 401 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 0); |
| 402 | testSimplifyx(path); |
| 403 | </div> |
| 404 | |
| 405 | <div id="testLine29"> |
| 406 | SkPath path, simple; |
| 407 | path.addRect(0, 18, 12, 12, (SkPath::Direction) 0); |
| 408 | path.addRect(12, 12, 21, 21, (SkPath::Direction) 0); |
| 409 | testSimplifyx(path); |
| 410 | </div> |
| 411 | |
| 412 | <div id="testLine30"> |
| 413 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 414 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 415 | path.addRect(4, 4, 13, 13, (SkPath::Direction) 0); |
| 416 | </div> |
| 417 | |
| 418 | <div id="testLine31"> |
| 419 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 420 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 421 | path.addRect(0, 4, 9, 9, (SkPath::Direction) 0); |
| 422 | </div> |
| 423 | |
| 424 | <div id="testLine32"> |
| 425 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 426 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 427 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 0); |
| 428 | </div> |
| 429 | |
caryclark@google.com | 9764cc6 | 2012-07-12 19:29:45 +0000 | [diff] [blame] | 430 | <div id="testLine33"> |
| 431 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 432 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 433 | path.addRect(4, 16, 13, 13, (SkPath::Direction) 0); |
| 434 | </div> |
| 435 | |
caryclark@google.com | 210acaf | 2012-07-12 21:05:13 +0000 | [diff] [blame] | 436 | <div id="testLine34"> |
| 437 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 438 | path.addRect(0, 6, 12, 12, (SkPath::Direction) 0); |
| 439 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 0); |
| 440 | </div> |
| 441 | |
| 442 | <div id="testLine35"> |
| 443 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 444 | path.addRect(6, 0, 18, 18, (SkPath::Direction) 0); |
| 445 | path.addRect(4, 16, 13, 13, (SkPath::Direction) 0); |
| 446 | </div> |
| 447 | |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 448 | <div id="testLine36"> |
| 449 | path.addRect(0, 10, 20, 20, (SkPath::Direction) 0); |
| 450 | path.addRect(6, 12, 18, 18, (SkPath::Direction) 0); |
| 451 | path.addRect(4, 16, 13, 13, (SkPath::Direction) 0); |
| 452 | </div> |
| 453 | |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 454 | <div id="testLine37"> |
| 455 | path.addRect(0, 20, 20, 20, (SkPath::Direction) 0); |
| 456 | path.addRect(18, 24, 30, 30, (SkPath::Direction) 0); |
| 457 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 0); |
| 458 | </div> |
| 459 | |
| 460 | <div id="testLine38"> |
| 461 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 0); |
| 462 | path.addRect(6, 12, 18, 18, (SkPath::Direction) 0); |
| 463 | path.addRect(12, 12, 21, 21, (SkPath::Direction) 0); |
| 464 | </div> |
| 465 | |
| 466 | <div id="testLine39"> |
| 467 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 0); |
| 468 | path.addRect(12, 6, 24, 24, (SkPath::Direction) 0); |
| 469 | path.addRect(12, 4, 21, 21, (SkPath::Direction) 0); |
| 470 | </div> |
| 471 | |
| 472 | <div id="testLine40"> |
| 473 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 0); |
| 474 | path.addRect(12, 18, 24, 24, (SkPath::Direction) 0); |
| 475 | path.addRect(4, 16, 13, 13, (SkPath::Direction) 0); |
| 476 | </div> |
| 477 | |
| 478 | <div id="testLine41"> |
| 479 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 480 | path.addRect(18, 24, 30, 30, (SkPath::Direction) 0); |
| 481 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 0); |
| 482 | </div> |
| 483 | |
| 484 | <div id="testLine42"> |
| 485 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 486 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 487 | path.addRect(8, 16, 17, 17, (SkPath::Direction) 0); |
| 488 | </div> |
| 489 | |
| 490 | <div id="testLine43"> |
| 491 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 492 | path.addRect(6, 24, 18, 18, (SkPath::Direction) 0); |
| 493 | path.addRect(0, 32, 9, 36, (SkPath::Direction) 1); |
| 494 | </div> |
| 495 | |
| 496 | <div id="testLine44"> |
| 497 | path.addRect(10, 40, 30, 30, (SkPath::Direction) 0); |
| 498 | path.addRect(18, 0, 30, 30, (SkPath::Direction) 0); |
| 499 | path.addRect(18, 32, 27, 36, (SkPath::Direction) 1); |
| 500 | </div> |
| 501 | |
| 502 | <div id="testLine45"> |
| 503 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 0); |
| 504 | path.addRect(18, 0, 30, 30, (SkPath::Direction) 0); |
| 505 | path.addRect(24, 32, 33, 36, (SkPath::Direction) 0); |
| 506 | </div> |
| 507 | |
| 508 | <div id="testLine46"> |
| 509 | path.addRect(10, 40, 30, 30, (SkPath::Direction) 0); |
| 510 | path.addRect(24, 0, 36, 36, (SkPath::Direction) 0); |
| 511 | path.addRect(24, 32, 33, 36, (SkPath::Direction) 0); |
| 512 | </div> |
| 513 | |
| 514 | <div id="testLine47"> |
| 515 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 516 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 517 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 1); |
| 518 | </div> |
| 519 | |
| 520 | <div id="testLine48"> |
| 521 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 522 | path.addRect(0, 6, 12, 12, (SkPath::Direction) 0); |
| 523 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 1); |
| 524 | </div> |
| 525 | |
| 526 | <div id="testLine49"> |
| 527 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 528 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 529 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 0); |
| 530 | </div> |
| 531 | |
| 532 | <div id="testLine50"> |
| 533 | path.addRect(10, 30, 30, 30, (SkPath::Direction) 0); |
| 534 | path.addRect(24, 20, 36, 30, (SkPath::Direction) 0); |
| 535 | </div> |
| 536 | |
| 537 | <div id="testLine51"> |
| 538 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 539 | path.addRect(0, 12, 12, 12, (SkPath::Direction) 0); |
| 540 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 1); |
| 541 | </div> |
| 542 | |
caryclark@google.com | e21cb18 | 2012-07-23 21:26:31 +0000 | [diff] [blame] | 543 | <div id="testLine52"> |
| 544 | path.addRect(0, 30, 20, 20, (SkPath::Direction) 0); |
| 545 | path.addRect(6, 20, 18, 30, (SkPath::Direction) 0); |
| 546 | path.addRect(32, 0, 36, 41, (SkPath::Direction) 0); |
| 547 | </div> |
| 548 | |
| 549 | <div id="testLine53"> |
| 550 | path.addRect(10, 30, 30, 30, (SkPath::Direction) 0); |
| 551 | path.addRect(12, 20, 24, 30, (SkPath::Direction) 0); |
| 552 | path.addRect(12, 32, 21, 36, (SkPath::Direction) 1); |
| 553 | </div> |
| 554 | |
| 555 | <div id="testLine54"> |
| 556 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 557 | path.addRect(6, 0, 18, 18, (SkPath::Direction) 0); |
| 558 | path.addRect(8, 4, 17, 17, (SkPath::Direction) 1); |
| 559 | </div> |
| 560 | |
| 561 | <div id="testLine55"> |
| 562 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 563 | path.addRect(6, 6, 18, 18, (SkPath::Direction) 0); |
| 564 | path.addRect(4, 4, 13, 13, (SkPath::Direction) 1); |
| 565 | </div> |
| 566 | |
caryclark@google.com | 1806344 | 2012-07-25 12:05:18 +0000 | [diff] [blame] | 567 | <div id="testLine56"> |
| 568 | path.addRect(0, 20, 20, 20, (SkPath::Direction) 0); |
| 569 | path.addRect(18, 20, 30, 30, (SkPath::Direction) 0); |
| 570 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 1); |
| 571 | </div> |
| 572 | |
| 573 | <div id="testLine57"> |
| 574 | path.addRect(20, 0, 40, 40, (SkPath::Direction) 0); |
| 575 | path.addRect(20, 0, 30, 40, (SkPath::Direction) 0); |
| 576 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 1); |
| 577 | </div> |
| 578 | |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 579 | <div id="testLine58"> |
| 580 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 581 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 1); |
| 582 | path.addRect(0, 12, 9, 9, (SkPath::Direction) 1); |
| 583 | </div> |
| 584 | |
| 585 | <div id="testLine59"> |
| 586 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 587 | path.addRect(6, 6, 18, 18, (SkPath::Direction) 1); |
| 588 | path.addRect(4, 4, 13, 13, (SkPath::Direction) 1); |
| 589 | </div> |
| 590 | |
caryclark@google.com | 27c449a | 2012-07-27 18:26:38 +0000 | [diff] [blame] | 591 | <div id="testLine60"> |
| 592 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 593 | path.addRect(6, 12, 18, 18, (SkPath::Direction) 1); |
| 594 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 1); |
| 595 | </div> |
| 596 | |
| 597 | <div id="testLine61"> |
| 598 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 599 | path.addRect(12, 0, 24, 24, (SkPath::Direction) 1); |
| 600 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 1); |
| 601 | </div> |
| 602 | |
| 603 | <div id="testLine62"> |
| 604 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 605 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 606 | path.addRect(0, 12, 12, 12, (SkPath::Direction) 0); |
| 607 | path.addRect(4, 12, 13, 13, (SkPath::Direction) 1); |
| 608 | </div> |
| 609 | |
| 610 | <div id="testLine63"> |
| 611 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 612 | path.addRect(0, 10, 20, 20, (SkPath::Direction) 0); |
| 613 | path.addRect(0, 6, 12, 12, (SkPath::Direction) 1); |
| 614 | path.addRect(0, 32, 9, 36, (SkPath::Direction) 1); |
| 615 | </div> |
| 616 | |
| 617 | <div id="testLine64"> |
| 618 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 619 | path.addRect(10, 40, 30, 30, (SkPath::Direction) 0); |
| 620 | path.addRect(18, 6, 30, 30, (SkPath::Direction) 0); |
| 621 | </div> |
| 622 | |
| 623 | <div id="testLine65"> |
| 624 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 625 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 0); |
| 626 | path.addRect(24, 0, 36, 36, (SkPath::Direction) 0); |
| 627 | path.addRect(32, 6, 36, 41, (SkPath::Direction) 1); |
| 628 | </div> |
| 629 | |
| 630 | <div id="testLine66"> |
| 631 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 632 | path.addRect(0, 30, 20, 20, (SkPath::Direction) 0); |
| 633 | path.addRect(12, 20, 24, 30, (SkPath::Direction) 0); |
| 634 | </div> |
| 635 | |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 636 | <div id="testLine67"> |
| 637 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 638 | path.addRect(10, 40, 30, 30, (SkPath::Direction) 0); |
| 639 | path.addRect(24, 20, 36, 30, (SkPath::Direction) 0); |
| 640 | path.addRect(32, 0, 36, 41, (SkPath::Direction) 0); |
| 641 | </div> |
| 642 | |
| 643 | <div id="testLine68a"> |
| 644 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 0); |
| 645 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 0); |
| 646 | path.addRect(1, 2, 4, 2, (SkPath::Direction) 0); |
| 647 | </div> |
| 648 | |
| 649 | <div id="testLine68b"> |
| 650 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 0); |
| 651 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 1); |
| 652 | path.addRect(1, 2, 4, 2, (SkPath::Direction) 0); |
| 653 | </div> |
| 654 | |
| 655 | <div id="testLine68c"> |
| 656 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 1); |
| 657 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 0); |
| 658 | path.addRect(1, 2, 4, 2, (SkPath::Direction) 0); |
| 659 | </div> |
| 660 | |
| 661 | <div id="testLine68d"> |
| 662 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 1); |
| 663 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 1); |
| 664 | path.addRect(1, 2, 4, 2, (SkPath::Direction) 0); |
| 665 | </div> |
| 666 | |
| 667 | <div id="testLine68e"> |
| 668 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 0); |
| 669 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 0); |
| 670 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 1); |
| 671 | path.addRect(1, 2, 2, 2, (SkPath::Direction) 0); |
| 672 | </div> |
| 673 | |
| 674 | <div id="testLine68f"> |
| 675 | path.addRect(0, 0, 8, 8, (SkPath::Direction) 0); |
| 676 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 1); |
| 677 | path.addRect(2, 2, 6, 6, (SkPath::Direction) 1); |
| 678 | path.addRect(1, 2, 2, 2, (SkPath::Direction) 0); |
| 679 | </div> |
| 680 | |
| 681 | <div id="testLine69"> |
| 682 | path.addRect(0, 20, 20, 20, (SkPath::Direction) 0); |
| 683 | path.addRect(0, 20, 12, 30, (SkPath::Direction) 0); |
| 684 | path.addRect(12, 32, 21, 36, (SkPath::Direction) 0); |
| 685 | </div> |
| 686 | |
| 687 | <div id="testLine70"> |
| 688 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 689 | path.addRect(0, 24, 12, 12, (SkPath::Direction) 0); |
| 690 | path.addRect(12, 32, 21, 36, (SkPath::Direction) 1); |
| 691 | </div> |
| 692 | |
| 693 | <div id="testLine71"> |
| 694 | path.addRect(0, 0, 20, 20, (SkPath::Direction) 0); |
| 695 | path.addRect(12, 0, 24, 24, (SkPath::Direction) 0); |
| 696 | path.addRect(12, 32, 21, 36, (SkPath::Direction) 0); |
| 697 | </div> |
| 698 | |
caryclark@google.com | 200c211 | 2012-08-03 15:05:04 +0000 | [diff] [blame] | 699 | <div id="testLine72"> |
| 700 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 701 | path.addRect(10, 40, 30, 30, (SkPath::Direction) 0); |
| 702 | path.addRect(6, 20, 18, 30, (SkPath::Direction) 0); |
| 703 | </div> |
| 704 | |
| 705 | <div id="testLine73"> |
| 706 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 707 | path.addRect(0, 40, 20, 20, (SkPath::Direction) 0); |
| 708 | path.addRect(0, 20, 12, 30, (SkPath::Direction) 0); |
| 709 | path.addRect(0, 0, 9, 9, (SkPath::Direction) 1); |
| 710 | </div> |
| 711 | |
caryclark@google.com | 0c803d0 | 2012-08-06 11:15:47 +0000 | [diff] [blame] | 712 | <div id="testLine74"> |
| 713 | path.addRect(20, 30, 40, 40, (SkPath::Direction) 0); |
| 714 | path.addRect(24, 20, 36, 30, (SkPath::Direction) 1); |
| 715 | path.addRect(32, 24, 36, 41, (SkPath::Direction) 1); |
| 716 | </div> |
| 717 | |
caryclark@google.com | 2ddff93 | 2012-08-07 21:25:27 +0000 | [diff] [blame] | 718 | <div id="testLine75"> |
| 719 | path.addRect(0, 0, 60, 60, (SkPath::Direction) 0); |
| 720 | path.addRect(10, 0, 30, 30, (SkPath::Direction) 1); |
| 721 | path.addRect(18, 0, 30, 30, (SkPath::Direction) 1); |
| 722 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 1); |
| 723 | </div> |
| 724 | |
| 725 | <div id="testLine76"> |
| 726 | path.addRect(36, 0, 66, 60, (SkPath::Direction) 0); |
| 727 | path.addRect(10, 20, 40, 30, (SkPath::Direction) 0); |
| 728 | path.addRect(24, 20, 36, 30, (SkPath::Direction) 1); |
| 729 | path.addRect(32, 6, 36, 41, (SkPath::Direction) 1); |
| 730 | </div> |
| 731 | |
| 732 | <div id="testLine77"> |
| 733 | path.addRect(20, 0, 40, 40, (SkPath::Direction) 0); |
| 734 | path.addRect(24, 6, 36, 36, (SkPath::Direction) 1); |
| 735 | path.addRect(24, 32, 33, 36, (SkPath::Direction) 1); |
| 736 | </div> |
| 737 | |
| 738 | <div id="testLine78"> |
| 739 | path.addRect(0, 0, 30, 60, (SkPath::Direction) 0); |
| 740 | path.addRect(10, 20, 30, 30, (SkPath::Direction) 1); |
| 741 | path.addRect(18, 20, 30, 30, (SkPath::Direction) 1); |
| 742 | path.addRect(32, 0, 36, 41, (SkPath::Direction) 1); |
| 743 | </div> |
| 744 | |
| 745 | <div id="testLine79"> |
| 746 | path.addRect(0, 36, 60, 30, (SkPath::Direction) 0); |
| 747 | path.addRect(10, 30, 40, 30, (SkPath::Direction) 0); |
| 748 | path.addRect(0, 20, 12, 30, (SkPath::Direction) 1); |
| 749 | path.addRect(0, 32, 9, 36, (SkPath::Direction) 1); |
| 750 | </div> |
| 751 | |
caryclark@google.com | 59823f7 | 2012-08-09 18:17:47 +0000 | [diff] [blame] | 752 | <div id="testDegenerate1"> |
| 753 | path.moveTo(0, 0); |
| 754 | path.lineTo(0, 0); |
| 755 | path.lineTo(2, 0); |
| 756 | path.close(); |
| 757 | path.moveTo(0, 0); |
| 758 | path.lineTo(1, 0); |
| 759 | path.lineTo(2, 0); |
| 760 | path.close(); |
| 761 | </div> |
| 762 | |
| 763 | <div id="testDegenerate2"> |
| 764 | path.moveTo(0, 0); |
| 765 | path.lineTo(0, 0); |
| 766 | path.lineTo(0, 0); |
| 767 | path.close(); |
| 768 | path.moveTo(0, 0); |
| 769 | path.lineTo(1, 0); |
| 770 | path.lineTo(0, 1); |
| 771 | path.close(); |
| 772 | </div> |
| 773 | |
| 774 | <div id="testDegenerate3"> |
| 775 | path.moveTo(0, 0); |
| 776 | path.lineTo(2, 0); |
| 777 | path.lineTo(1, 0); |
| 778 | path.close(); |
| 779 | path.moveTo(0, 0); |
| 780 | path.lineTo(0, 0); |
| 781 | path.lineTo(3, 0); |
| 782 | path.close(); |
| 783 | </div> |
| 784 | |
| 785 | <div id="testDegenerate4"> |
| 786 | path.moveTo(0, 0); |
| 787 | path.lineTo(1, 0); |
| 788 | path.lineTo(1, 3); |
| 789 | path.close(); |
| 790 | path.moveTo(1, 0); |
| 791 | path.lineTo(1, 1); |
| 792 | path.lineTo(1, 2); |
| 793 | path.close(); |
| 794 | </div> |
| 795 | |
| 796 | <div id="testNondegenerate1"> |
| 797 | path.moveTo(0, 0); |
| 798 | path.lineTo(3, 0); |
| 799 | path.lineTo(1, 3); |
| 800 | path.close(); |
| 801 | path.moveTo(1, 1); |
| 802 | path.lineTo(2, 1); |
| 803 | path.lineTo(1, 2); |
| 804 | path.close(); |
| 805 | </div> |
| 806 | |
| 807 | <div id="testNondegenerate2"> |
| 808 | path.moveTo(1, 0); |
| 809 | path.lineTo(0, 1); |
| 810 | path.lineTo(1, 1); |
| 811 | path.close(); |
| 812 | path.moveTo(0, 2); |
| 813 | path.lineTo(0, 3); |
| 814 | path.lineTo(1, 2); |
| 815 | path.close(); |
| 816 | </div> |
| 817 | |
| 818 | <div id="testNondegenerate3"> |
| 819 | path.moveTo(0, 0); |
| 820 | path.lineTo(1, 0); |
| 821 | path.lineTo(2, 1); |
| 822 | path.close(); |
| 823 | path.moveTo(0, 1); |
| 824 | path.lineTo(1, 1); |
| 825 | path.lineTo(0, 2); |
| 826 | path.close(); |
| 827 | </div> |
| 828 | |
| 829 | <div id="testNondegenerate4"> |
| 830 | path.moveTo(1, 0); |
| 831 | path.lineTo(0, 1); |
| 832 | path.lineTo(1, 2); |
| 833 | path.close(); |
| 834 | path.moveTo(0, 2); |
| 835 | path.lineTo(0, 3); |
| 836 | path.lineTo(1, 3); |
| 837 | path.close(); |
| 838 | </div> |
| 839 | |
| 840 | <div id="testQuadralateral5"> |
| 841 | path.moveTo(0, 0); |
| 842 | path.lineTo(0, 0); |
| 843 | path.lineTo(1, 0); |
| 844 | path.lineTo(1, 1); |
| 845 | path.close(); |
| 846 | path.moveTo(0, 0); |
| 847 | path.lineTo(2, 2); |
| 848 | path.lineTo(3, 2); |
| 849 | path.lineTo(3, 3); |
| 850 | path.close(); |
| 851 | </div> |
| 852 | |
| 853 | <div id="testQuadralateral6"> |
| 854 | path.moveTo(0, 0); |
| 855 | path.lineTo(0, 0); |
| 856 | path.lineTo(1, 0); |
| 857 | path.lineTo(1, 1); |
| 858 | path.close(); |
| 859 | path.moveTo(1, 0); |
| 860 | path.lineTo(2, 0); |
| 861 | path.lineTo(0, 2); |
| 862 | path.lineTo(2, 2); |
| 863 | path.close(); |
| 864 | </div> |
| 865 | |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 866 | <div id="testFauxQuadralateral6"> |
| 867 | path.moveTo(0, 0); |
| 868 | path.lineTo(1, 0); |
| 869 | path.lineTo(1, 1); |
| 870 | path.close(); |
| 871 | path.moveTo(1, 0); |
| 872 | path.lineTo(2, 0); |
| 873 | path.lineTo(1.333, 0.667); |
| 874 | path.close(); |
| 875 | path.moveTo(1.333, 0.667); |
| 876 | path.lineTo(0, 2); |
| 877 | path.lineTo(2, 2); |
| 878 | path.close(); |
| 879 | </div> |
| 880 | |
| 881 | <div id="testFauxQuadralateral6a"> |
| 882 | path.moveTo(0, 0); |
| 883 | path.lineTo(3, 0); |
| 884 | path.lineTo(3, 3); |
| 885 | path.close(); |
| 886 | path.moveTo(3, 0); |
| 887 | path.lineTo(6, 0); |
| 888 | path.lineTo(4, 2); |
| 889 | path.close(); |
| 890 | path.moveTo(4, 2); |
| 891 | path.lineTo(0, 6); |
| 892 | path.lineTo(6, 6); |
| 893 | path.close(); |
| 894 | </div> |
| 895 | |
| 896 | <div id="testFauxQuadralateral6b"> |
| 897 | path.moveTo(0, 0); |
| 898 | path.lineTo(3, 0); |
| 899 | path.lineTo(3, 3); |
| 900 | path.close(); |
| 901 | path.moveTo(3, 0); |
| 902 | path.lineTo(6, 0); |
| 903 | path.lineTo(4, 2); |
| 904 | path.close(); |
| 905 | path.moveTo(4, 2); |
| 906 | path.lineTo(6, 6); |
| 907 | path.lineTo(0, 6); |
| 908 | path.close(); |
| 909 | </div> |
| 910 | |
| 911 | <div id="testFauxQuadralateral6c"> |
| 912 | path.moveTo(0, 0); |
| 913 | path.lineTo(3, 3); |
| 914 | path.lineTo(3, 0); |
| 915 | path.close(); |
| 916 | path.moveTo(3, 0); |
| 917 | path.lineTo(6, 0); |
| 918 | path.lineTo(4, 2); |
| 919 | path.close(); |
| 920 | path.moveTo(4, 2); |
| 921 | path.lineTo(0, 6); |
| 922 | path.lineTo(6, 6); |
| 923 | path.close(); |
| 924 | </div> |
| 925 | |
| 926 | <div id="testFauxQuadralateral6d"> |
| 927 | path.moveTo(0, 0); |
| 928 | path.lineTo(3, 3); |
| 929 | path.lineTo(3, 0); |
| 930 | path.close(); |
| 931 | path.moveTo(3, 0); |
| 932 | path.lineTo(6, 0); |
| 933 | path.lineTo(4, 2); |
| 934 | path.close(); |
| 935 | path.moveTo(4, 2); |
| 936 | path.lineTo(6, 6); |
| 937 | path.lineTo(0, 6); |
| 938 | </div> |
| 939 | |
| 940 | <div id="testQuadralateral6a"> |
| 941 | path.moveTo(0, 0); |
| 942 | path.lineTo(0, 0); |
| 943 | path.lineTo(3, 0); |
| 944 | path.lineTo(3, 3); |
| 945 | path.close(); |
| 946 | path.moveTo(3, 0); |
| 947 | path.lineTo(6, 0); |
| 948 | path.lineTo(0, 6); |
| 949 | path.lineTo(6, 6); |
| 950 | </div> |
| 951 | |
| 952 | <div id="testQuadralateral7"> |
| 953 | path.moveTo(0, 0); |
| 954 | path.lineTo(0, 0); |
| 955 | path.lineTo(1, 0); |
| 956 | path.lineTo(2, 1); |
| 957 | path.close(); |
| 958 | path.moveTo(1, 0); |
| 959 | path.lineTo(1, 1); |
| 960 | path.lineTo(2, 2); |
| 961 | path.lineTo(1, 3); |
| 962 | path.close(); |
| 963 | </div> |
| 964 | |
| 965 | <div id="testQuadralateral8"> |
| 966 | path.moveTo(0, 0); |
| 967 | path.lineTo(3, 1); |
| 968 | path.lineTo(1, 3); |
| 969 | path.lineTo(3, 3); |
| 970 | path.close(); |
| 971 | path.moveTo(2, 1); |
| 972 | path.lineTo(0, 2); |
| 973 | path.lineTo(3, 2); |
| 974 | path.lineTo(2, 3); |
| 975 | path.close(); |
| 976 | </div> |
| 977 | |
| 978 | <div id="testQuadralateral9"> |
| 979 | path.moveTo(0, 0); |
| 980 | path.lineTo(1, 0); |
| 981 | path.lineTo(1, 2); |
| 982 | path.lineTo(2, 2); |
| 983 | path.close(); |
| 984 | path.moveTo(1, 1); |
| 985 | path.lineTo(2, 1); |
| 986 | path.lineTo(1, 3); |
| 987 | path.lineTo(2, 3); |
| 988 | path.close(); |
| 989 | </div> |
| 990 | |
| 991 | <div id="testLine1x"> |
| 992 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 993 | path.addRect(0, 0, 12, 12, (SkPath::Direction) 0); |
| 994 | path.addRect(4, 0, 13, 13, (SkPath::Direction) 0); |
| 995 | </div> |
| 996 | |
| 997 | <div id="testLine2x"> |
| 998 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 999 | path.addRect(0, 20, 20, 20, (SkPath::Direction) 0); |
| 1000 | path.addRect(0, 20, 12, 30, (SkPath::Direction) 0); |
| 1001 | path.addRect(12, 0, 21, 21, (SkPath::Direction) 1); |
| 1002 | </div> |
| 1003 | |
| 1004 | <div id="testLine3x"> |
| 1005 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1006 | path.addRect(10, 30, 30, 30, (SkPath::Direction) 0); |
| 1007 | path.addRect(18, 20, 30, 30, (SkPath::Direction) 1); |
| 1008 | path.addRect(0, 32, 9, 36, (SkPath::Direction) 1); |
| 1009 | </div> |
| 1010 | |
| 1011 | <div id="testLine4x"> |
| 1012 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1013 | path.addRect(10, 30, 30, 30, (SkPath::Direction) 0); |
| 1014 | path.addRect(24, 20, 36, 30, (SkPath::Direction) 1); |
| 1015 | path.addRect(0, 32, 9, 36, (SkPath::Direction) 1); |
| 1016 | </div> |
| 1017 | |
| 1018 | <div id="testQuadratic1"> |
| 1019 | path.moveTo(0, 0); |
| 1020 | path.quadTo(0, 0, 0, 0); |
| 1021 | path.lineTo(1, 0); |
| 1022 | path.close(); |
| 1023 | path.moveTo(0, 0); |
| 1024 | path.lineTo(0, 0); |
| 1025 | path.quadTo(0, 0, 0, 0); |
| 1026 | path.close(); |
| 1027 | </div> |
| 1028 | |
| 1029 | <div id="testQuadratic2"> |
| 1030 | path.moveTo(0, 0); |
| 1031 | path.quadTo(0, 0, 0, 0); |
| 1032 | path.lineTo(3, 0); |
| 1033 | path.close(); |
| 1034 | path.moveTo(0, 0); |
| 1035 | path.lineTo(0, 0); |
| 1036 | path.quadTo(1, 0, 0, 1); |
| 1037 | path.close(); |
| 1038 | </div> |
| 1039 | |
caryclark@google.com | 03f9706 | 2012-08-21 13:13:52 +0000 | [diff] [blame] | 1040 | <div id="testQuadratic3"> |
| 1041 | path.moveTo(0, 0); |
| 1042 | path.quadTo(0, 0, 1, 0); |
| 1043 | path.lineTo(0, 2); |
| 1044 | path.close(); |
| 1045 | path.moveTo(0, 0); |
| 1046 | path.lineTo(0, 0); |
| 1047 | path.quadTo(1, 0, 0, 1); |
| 1048 | path.close(); |
| 1049 | </div> |
| 1050 | |
caryclark@google.com | c899ad9 | 2012-08-23 15:24:42 +0000 | [diff] [blame] | 1051 | <div id="testQuadratic4x"> |
| 1052 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1053 | path.moveTo(0, 0); |
| 1054 | path.quadTo(0, 0, 1, 0); |
| 1055 | path.lineTo(0, 2); |
| 1056 | path.close(); |
| 1057 | path.moveTo(0, 0); |
| 1058 | path.lineTo(0, 0); |
| 1059 | path.quadTo(1, 0, 0, 2); |
| 1060 | path.close(); |
| 1061 | </div> |
| 1062 | |
| 1063 | <div id="testQuadratic5"> |
| 1064 | path.moveTo(0, 0); |
| 1065 | path.quadTo(0, 0, 0, 0); |
| 1066 | path.lineTo(0, 1); |
| 1067 | path.close(); |
| 1068 | path.moveTo(0, 0); |
| 1069 | path.lineTo(1, 0); |
| 1070 | path.quadTo(0, 1, 0, 2); |
| 1071 | path.close(); |
| 1072 | </div> |
| 1073 | |
| 1074 | <div id="testQuadratic6"> |
| 1075 | path.moveTo(0, 0); |
| 1076 | path.quadTo(0, 0, 1, 0); |
| 1077 | path.lineTo(2, 1); |
| 1078 | path.close(); |
| 1079 | path.moveTo(0, 0); |
| 1080 | path.lineTo(0, 0); |
| 1081 | path.quadTo(2, 0, 0, 1); |
| 1082 | path.close(); |
| 1083 | </div> |
| 1084 | |
| 1085 | <div id="testQuadratic7"> |
| 1086 | path.moveTo(0, 0); |
| 1087 | path.quadTo(0, 0, 1, 0); |
| 1088 | path.lineTo(3, 1); |
| 1089 | path.close(); |
| 1090 | path.moveTo(0, 0); |
| 1091 | path.lineTo(0, 0); |
| 1092 | path.quadTo(3, 0, 1, 2); |
| 1093 | path.close(); |
| 1094 | </div> |
| 1095 | |
| 1096 | <div id="testQuadratic8"> |
| 1097 | path.moveTo(0, 0); |
| 1098 | path.quadTo(0, 0, 1, 0); |
| 1099 | path.lineTo(0, 2); |
| 1100 | path.close(); |
| 1101 | path.moveTo(0, 0); |
| 1102 | path.lineTo(1, 0); |
| 1103 | path.quadTo(0, 1, 1, 2); |
| 1104 | path.close(); |
| 1105 | </div> |
| 1106 | |
| 1107 | <div id="testQuadratic9"> |
| 1108 | path.moveTo(0, 0); |
| 1109 | path.quadTo(0, 0, 1, 0); |
| 1110 | path.lineTo(3, 1); |
| 1111 | path.close(); |
| 1112 | path.moveTo(0, 0); |
| 1113 | path.lineTo(1, 0); |
| 1114 | path.quadTo(1, 2, 3, 2); |
| 1115 | path.close(); |
| 1116 | </div> |
| 1117 | |
| 1118 | <div id="testQuadratic9a"> |
| 1119 | path.moveTo(1.08000004, 0.720000029); |
| 1120 | path.lineTo(0, 0); |
| 1121 | path.lineTo(1, 0); |
| 1122 | path.lineTo(3, 1); |
| 1123 | path.lineTo(1.01568651, 0.338562161); |
| 1124 | path.quadTo(1.03542483, 0.541699469, 1.08000004, 0.720000029); |
| 1125 | path.close(); |
| 1126 | path.moveTo(1.08000004, 0.720000029); |
| 1127 | path.lineTo(3, 2); |
| 1128 | path.quadTo(1.39999998, 2, 1.08000004, 0.720000029); |
| 1129 | path.close(); |
| 1130 | |
| 1131 | </div> |
| 1132 | |
| 1133 | <div id="testQuadratic10a"> |
| 1134 | path.moveTo(15.5, 15.5); |
| 1135 | path.lineTo(46.5, 15.5); |
| 1136 | path.quadTo(0, 31, 0, 46.5); |
| 1137 | path.lineTo(15.5, 15.5); |
| 1138 | path.close(); |
| 1139 | </div> |
| 1140 | |
| 1141 | <div id="testQuadratic10b"> |
| 1142 | path.moveTo(5.16666698, 36.1666641); |
| 1143 | path.lineTo(15.5, 15.5); |
| 1144 | path.lineTo(46.5, 15.5); |
| 1145 | path.quadTo(15.5, 25.8333321, 5.16666698, 36.1666641); |
| 1146 | path.close(); |
| 1147 | path.moveTo(5.16666698, 36.1666641); |
| 1148 | path.lineTo(0, 46.5); |
| 1149 | path.quadTo(0, 41.3333359, 5.16666698, 36.1666641); |
| 1150 | path.close(); |
| 1151 | </div> |
| 1152 | |
| 1153 | <div id="testQuadratic11a"> |
| 1154 | path.moveTo(0, 0); |
| 1155 | path.lineTo(15.5, 31); |
| 1156 | path.lineTo(0, 0); |
| 1157 | path.close(); |
| 1158 | path.moveTo(0, 15.5); |
| 1159 | path.lineTo(15.5, 15.5); |
| 1160 | path.quadTo(15.5, 15.5, 46.5, 31); |
| 1161 | path.lineTo(0, 15.5); |
| 1162 | path.close(); |
| 1163 | </div> |
| 1164 | |
| 1165 | <div id="testQuadratic11b"> |
| 1166 | path.moveTo(9.30000019, 18.6000004); |
| 1167 | path.lineTo(0, 15.5); |
| 1168 | path.lineTo(7.75, 15.5); |
| 1169 | path.lineTo(15.5, 15.5); |
| 1170 | path.lineTo(46.5, 31); |
| 1171 | path.lineTo(9.30000019, 18.6000004); |
| 1172 | path.close(); |
| 1173 | </div> |
| 1174 | |
| 1175 | <div id="testQuadratic12"> |
| 1176 | path.moveTo(0, 0); |
| 1177 | path.quadTo(0, 0, 0, 0); |
| 1178 | path.lineTo(1, 3); |
| 1179 | path.close(); |
| 1180 | path.moveTo(1, 0); |
| 1181 | path.lineTo(0, 1); |
| 1182 | path.quadTo(1, 1, 0, 3); |
| 1183 | path.close(); |
| 1184 | </div> |
| 1185 | |
| 1186 | <div id="testQuadratic13a"> |
| 1187 | path.moveTo(0, 0); |
| 1188 | path.quadTo(0, 0, 15.5, 0); |
| 1189 | path.lineTo(15.5, 31); |
| 1190 | path.lineTo(0, 0); |
| 1191 | path.close(); |
| 1192 | path.moveTo(0, 0); |
| 1193 | path.quadTo(15.5, 46.5, 46.5, 46.5); |
| 1194 | path.lineTo(0, 0); |
| 1195 | path.close(); |
| 1196 | </div> |
| 1197 | |
| 1198 | <div id="testQuadratic13b"> |
| 1199 | path.moveTo(14.8800001, 29.7600002); |
| 1200 | path.quadTo(6.20000029, 18.6000004, 0, 0); |
| 1201 | path.lineTo(14.8800001, 29.7600002); |
| 1202 | path.close(); |
| 1203 | path.moveTo(15.5, 30.5437222); |
| 1204 | path.lineTo(15.5, 31); |
| 1205 | path.lineTo(14.8800001, 29.7600002); |
| 1206 | path.quadTo(15.1884346, 30.156559, 15.5, 30.5437222); |
| 1207 | path.close(); |
| 1208 | path.moveTo(15.5, 15.5); |
| 1209 | path.lineTo(0, 0); |
| 1210 | path.lineTo(15.5, 0); |
| 1211 | path.lineTo(15.5, 15.5); |
| 1212 | path.close(); |
| 1213 | path.moveTo(15.5, 30.5437222); |
| 1214 | path.lineTo(15.5, 15.5); |
| 1215 | path.lineTo(46.5, 46.5); |
| 1216 | path.quadTo(28.34062, 46.5, 15.5, 30.5437222); |
| 1217 | path.close(); |
| 1218 | </div> |
| 1219 | |
| 1220 | <div id="testQuadratic14"> |
| 1221 | path.moveTo(0, 0); |
| 1222 | path.quadTo(0, 0, 1, 0); |
| 1223 | path.lineTo(3, 2); |
| 1224 | path.close(); |
| 1225 | path.moveTo(0, 0); |
| 1226 | path.lineTo(1, 0); |
| 1227 | path.quadTo(3, 2, 3, 3); |
| 1228 | path.close(); |
| 1229 | </div> |
| 1230 | |
caryclark@google.com | 3350c3c | 2012-08-24 15:24:36 +0000 | [diff] [blame] | 1231 | <div id="testQuadratic15"> |
| 1232 | path.moveTo(0, 0); |
| 1233 | path.quadTo(0, 0, 1, 0); |
| 1234 | path.lineTo(1, 3); |
| 1235 | path.close(); |
| 1236 | path.moveTo(1, 0); |
| 1237 | path.lineTo(0, 1); |
| 1238 | path.quadTo(1, 1, 0, 3); |
| 1239 | path.close(); |
| 1240 | </div> |
| 1241 | |
| 1242 | <div id="testQuadratic16a"> |
| 1243 | path.moveTo(0, 0); |
| 1244 | path.quadTo(0, 0, 31, 0); |
| 1245 | path.lineTo(46.5, 31); |
| 1246 | path.lineTo(0, 0); |
| 1247 | path.close(); |
| 1248 | path.moveTo(46.5, 15.5); |
| 1249 | path.lineTo(0, 31); |
| 1250 | path.quadTo(0, 31, 15.5, 31); |
| 1251 | path.lineTo(46.5, 15.5); |
| 1252 | path.close(); |
| 1253 | </div> |
| 1254 | |
| 1255 | <div id="testQuadratic16b"> |
| 1256 | path.moveTo(31, 20.6666679); |
| 1257 | path.lineTo(0, 0); |
| 1258 | path.lineTo(31, 0); |
| 1259 | path.lineTo(39.8571434, 17.7142868); |
| 1260 | path.lineTo(31, 20.6666679); |
| 1261 | path.close(); |
| 1262 | path.moveTo(33.214283, 22.1428585); |
| 1263 | path.lineTo(15.5, 31); |
| 1264 | path.lineTo(0, 31); |
| 1265 | path.lineTo(31, 20.6666679); |
| 1266 | path.lineTo(33.214283, 22.1428585); |
| 1267 | path.close(); |
| 1268 | path.moveTo(40.2999992, 18.6000004); |
| 1269 | path.lineTo(46.5, 31); |
| 1270 | path.lineTo(33.214283, 22.1428585); |
| 1271 | path.lineTo(40.2999992, 18.6000004); |
| 1272 | path.close(); |
| 1273 | path.moveTo(39.8571434, 17.7142868); |
| 1274 | path.lineTo(46.5, 15.5); |
| 1275 | path.lineTo(40.2999992, 18.6000004); |
| 1276 | path.lineTo(39.8571434, 17.7142868); |
| 1277 | path.close(); |
| 1278 | </div> |
| 1279 | |
| 1280 | <div id="testQuadratic17x"> |
| 1281 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1282 | path.moveTo(0, 0); |
| 1283 | path.quadTo(0, 0, 3, 1); |
| 1284 | path.lineTo(0, 2); |
| 1285 | path.close(); |
| 1286 | path.moveTo(0, 0); |
| 1287 | path.lineTo(1, 0); |
| 1288 | path.quadTo(3, 1, 0, 2); |
| 1289 | path.close(); |
| 1290 | </div> |
| 1291 | |
| 1292 | <div id="testQuadratic18"> |
| 1293 | path.moveTo(0, 0); |
| 1294 | path.quadTo(1, 0, 0, 1); |
| 1295 | path.lineTo(0, 1); |
| 1296 | path.close(); |
| 1297 | path.moveTo(0, 0); |
| 1298 | path.lineTo(0, 0); |
| 1299 | path.quadTo(1, 0, 1, 1); |
| 1300 | path.close(); |
| 1301 | </div> |
| 1302 | |
caryclark@google.com | a7e483d | 2012-08-28 20:44:43 +0000 | [diff] [blame] | 1303 | <div id="testQuadratic19"> |
| 1304 | path.moveTo(0, 0); |
| 1305 | path.quadTo(1, 0, 0, 1); |
| 1306 | path.lineTo(0, 1); |
| 1307 | path.close(); |
| 1308 | path.moveTo(0, 0); |
| 1309 | path.lineTo(0, 0); |
| 1310 | path.quadTo(2, 0, 0, 1); |
| 1311 | path.close(); |
| 1312 | </div> |
| 1313 | |
caryclark@google.com | 32546db | 2012-08-31 20:55:07 +0000 | [diff] [blame] | 1314 | <div id="testQuadratic20"> |
| 1315 | path.moveTo(0, 0); |
| 1316 | path.quadTo(1, 0, 0, 1); |
| 1317 | path.lineTo(0, 1); |
| 1318 | path.close(); |
| 1319 | path.moveTo(0, 0); |
| 1320 | path.lineTo(0, 0); |
| 1321 | path.quadTo(1, 0, 0, 1); |
| 1322 | path.close(); |
| 1323 | </div> |
| 1324 | |
caryclark@google.com | 235f56a | 2012-09-14 14:19:30 +0000 | [diff] [blame] | 1325 | <div id="testQuadratic21"> |
| 1326 | path.moveTo(0, 0); |
| 1327 | path.quadTo(1, 0, 0, 1); |
| 1328 | path.lineTo(0, 1); |
| 1329 | path.close(); |
| 1330 | path.moveTo(0, 0); |
| 1331 | path.lineTo(0, 0); |
| 1332 | path.quadTo(1, 0, 0, 2); |
| 1333 | path.close(); |
| 1334 | </div> |
| 1335 | |
| 1336 | <div id="testQuadratic22"> |
| 1337 | path.moveTo(0, 0); |
| 1338 | path.quadTo(1, 0, 0, 1); |
| 1339 | path.lineTo(0, 1); |
| 1340 | path.close(); |
| 1341 | path.moveTo(0, 0); |
| 1342 | path.lineTo(0, 0); |
| 1343 | path.quadTo(0, 1, 2, 1); |
| 1344 | path.close(); |
| 1345 | </div> |
| 1346 | |
| 1347 | <div id="testQuadratic23"> |
| 1348 | path.moveTo(0, 0); |
| 1349 | path.quadTo(1, 0, 0, 1); |
| 1350 | path.lineTo(0, 1); |
| 1351 | path.close(); |
| 1352 | path.moveTo(0, 0); |
| 1353 | path.lineTo(0, 0); |
| 1354 | path.quadTo(0, 2, 1, 2); |
| 1355 | path.close(); |
| 1356 | </div> |
| 1357 | |
| 1358 | <div id="testQuadratic24"> |
| 1359 | path.moveTo(0, 0); |
| 1360 | path.quadTo(1, 0, 0, 1); |
| 1361 | path.lineTo(0, 1); |
| 1362 | path.close(); |
| 1363 | path.moveTo(0, 0); |
| 1364 | path.lineTo(1, 0); |
| 1365 | path.quadTo(2, 0, 0, 1); |
| 1366 | path.close(); |
| 1367 | </div> |
| 1368 | |
| 1369 | <div id="testQuadratic25"> |
| 1370 | path.moveTo(0, 0); |
| 1371 | path.quadTo(1, 0, 1, 1); |
| 1372 | path.lineTo(1, 1); |
| 1373 | path.close(); |
| 1374 | path.moveTo(0, 0); |
| 1375 | path.lineTo(0, 0); |
| 1376 | path.quadTo(2, 1, 0, 2); |
| 1377 | path.close(); |
| 1378 | </div> |
| 1379 | |
| 1380 | <div id="testQuadratic26"> |
| 1381 | path.moveTo(0, 0); |
| 1382 | path.quadTo(1, 0, 1, 1); |
| 1383 | path.lineTo(0, 2); |
| 1384 | path.close(); |
| 1385 | path.moveTo(0, 0); |
| 1386 | path.lineTo(0, 0); |
| 1387 | path.quadTo(1, 0, 0, 1); |
| 1388 | path.close(); |
| 1389 | </div> |
| 1390 | |
| 1391 | <div id="testQuadratic27"> |
| 1392 | path.moveTo(0, 0); |
| 1393 | path.quadTo(1, 0, 1, 1); |
| 1394 | path.lineTo(2, 1); |
| 1395 | path.close(); |
| 1396 | path.moveTo(0, 0); |
| 1397 | path.lineTo(0, 0); |
| 1398 | path.quadTo(2, 1, 0, 2); |
| 1399 | path.close(); |
| 1400 | </div> |
| 1401 | |
| 1402 | <div id="testQuadratic28"> |
| 1403 | path.moveTo(0, 0); |
| 1404 | path.quadTo(1, 0, 0, 1); |
| 1405 | path.lineTo(0, 1); |
| 1406 | path.close(); |
| 1407 | path.moveTo(0, 0); |
| 1408 | path.lineTo(0, 2); |
| 1409 | path.quadTo(1, 2, 0, 3); |
| 1410 | path.close(); |
| 1411 | </div> |
| 1412 | |
caryclark@google.com | d168874 | 2012-09-18 20:08:37 +0000 | [diff] [blame] | 1413 | <div id="testQuadratic29"> |
| 1414 | path.moveTo(0, 0); |
| 1415 | path.quadTo(1, 0, 2, 1); |
| 1416 | path.lineTo(0, 2); |
| 1417 | path.close(); |
| 1418 | path.moveTo(0, 0); |
| 1419 | path.lineTo(0, 0); |
| 1420 | path.quadTo(1, 0, 0, 1); |
| 1421 | path.close(); |
| 1422 | </div> |
| 1423 | |
| 1424 | <div id="testQuadratic30"> |
| 1425 | path.moveTo(0, 0); |
| 1426 | path.quadTo(1, 0, 1, 2); |
| 1427 | path.lineTo(1, 2); |
| 1428 | path.close(); |
| 1429 | path.moveTo(0, 0); |
| 1430 | path.lineTo(1, 0); |
| 1431 | path.quadTo(0, 1, 1, 2); |
| 1432 | path.close(); |
| 1433 | </div> |
| 1434 | |
| 1435 | <div id="testQuadratic31"> |
| 1436 | path.moveTo(0, 0); |
| 1437 | path.quadTo(1, 0, 1, 2); |
| 1438 | path.lineTo(1, 2); |
| 1439 | path.close(); |
| 1440 | path.moveTo(0, 0); |
| 1441 | path.lineTo(1, 0); |
| 1442 | path.quadTo(0, 1, 1, 3); |
| 1443 | path.close(); |
| 1444 | </div> |
| 1445 | |
| 1446 | <div id="testQuadratic32"> |
| 1447 | path.moveTo(0, 0); |
| 1448 | path.quadTo(1, 0, 2, 3); |
| 1449 | path.lineTo(2, 3); |
| 1450 | path.close(); |
| 1451 | path.moveTo(0, 0); |
| 1452 | path.lineTo(0, 0); |
| 1453 | path.quadTo(3, 1, 0, 2); |
| 1454 | path.close(); |
| 1455 | </div> |
| 1456 | |
| 1457 | <div id="testQuadratic33"> |
| 1458 | path.moveTo(0, 0); |
| 1459 | path.quadTo(2, 0, 0, 1); |
| 1460 | path.lineTo(0, 1); |
| 1461 | path.close(); |
| 1462 | path.moveTo(0, 0); |
| 1463 | path.lineTo(1, 1); |
| 1464 | path.quadTo(2, 1, 2, 2); |
| 1465 | path.close(); |
| 1466 | </div> |
| 1467 | |
| 1468 | <div id="testQuadratic34"> |
| 1469 | path.moveTo(0, 0); |
| 1470 | path.quadTo(2, 0, 0, 1); |
| 1471 | path.lineTo(0, 1); |
| 1472 | path.close(); |
| 1473 | path.moveTo(1, 0); |
| 1474 | path.lineTo(1, 1); |
| 1475 | path.quadTo(2, 1, 1, 2); |
| 1476 | path.close(); |
| 1477 | </div> |
| 1478 | |
| 1479 | <div id="testQuadratic35"> |
| 1480 | path.moveTo(0, 0); |
| 1481 | path.quadTo(0, 1, 1, 1); |
| 1482 | path.lineTo(1, 3); |
| 1483 | path.close(); |
| 1484 | path.moveTo(2, 0); |
| 1485 | path.lineTo(3, 0); |
| 1486 | path.quadTo(0, 1, 1, 1); |
| 1487 | path.close(); |
| 1488 | </div> |
| 1489 | |
| 1490 | <div id="testQuadratic36"> |
| 1491 | path.moveTo(0, 0); |
| 1492 | path.quadTo(2, 1, 2, 3); |
| 1493 | path.lineTo(2, 3); |
| 1494 | path.close(); |
| 1495 | path.moveTo(3, 1); |
| 1496 | path.lineTo(1, 2); |
| 1497 | path.quadTo(3, 2, 1, 3); |
| 1498 | path.close(); |
| 1499 | </div> |
| 1500 | |
| 1501 | <div id="testQuadratic37"> |
| 1502 | path.moveTo(0, 0); |
| 1503 | path.quadTo(0, 2, 1, 2); |
| 1504 | path.lineTo(1, 2); |
| 1505 | path.close(); |
| 1506 | path.moveTo(0, 0); |
| 1507 | path.lineTo(3, 1); |
| 1508 | path.quadTo(0, 2, 1, 2); |
| 1509 | path.close(); |
| 1510 | </div> |
| 1511 | |
| 1512 | <div id="testQuadratic38"> |
| 1513 | path.moveTo(1, 0); |
| 1514 | path.quadTo(0, 1, 1, 1); |
| 1515 | path.lineTo(1, 1); |
| 1516 | path.close(); |
| 1517 | path.moveTo(1, 0); |
| 1518 | path.lineTo(1, 2); |
| 1519 | path.quadTo(2, 2, 1, 3); |
| 1520 | path.close(); |
| 1521 | </div> |
| 1522 | |
| 1523 | <div id="testQuadratic39"> |
| 1524 | path.moveTo(15.5, 0); |
| 1525 | path.quadTo(46.5, 15.5, 46.5, 31); |
| 1526 | path.lineTo(15.5, 0); |
| 1527 | path.close(); |
| 1528 | path.moveTo(46.5, 15.5); |
| 1529 | path.lineTo(0, 31); |
| 1530 | path.quadTo(0, 31, 15.5, 31); |
| 1531 | path.lineTo(46.5, 15.5); |
| 1532 | path.close(); |
| 1533 | </div> |
| 1534 | |
| 1535 | <div id="testQuadratic39a"> |
| 1536 | path.moveTo(34.875, 19.375); |
| 1537 | path.lineTo(15.5, 0); |
| 1538 | path.quadTo(32.9687576, 8.73437881, 40.5937271, 17.4687576); |
| 1539 | path.lineTo(34.875, 19.375); |
| 1540 | path.close(); |
| 1541 | path.moveTo(36.1666641, 20.6666679); |
| 1542 | path.lineTo(15.5, 31); |
| 1543 | path.lineTo(0, 31); |
| 1544 | path.lineTo(34.875, 19.375); |
| 1545 | path.lineTo(36.1666641, 20.6666679); |
| 1546 | path.close(); |
| 1547 | path.moveTo(41.1812401, 18.15938); |
| 1548 | path.quadTo(46.5, 24.5796909, 46.5, 31); |
| 1549 | path.lineTo(36.1666641, 20.6666679); |
| 1550 | path.lineTo(41.1812401, 18.15938); |
| 1551 | path.close(); |
| 1552 | path.moveTo(40.5937271, 17.4687576); |
| 1553 | path.lineTo(46.5, 15.5); |
| 1554 | path.lineTo(41.1812401, 18.15938); |
| 1555 | path.quadTo(40.8951759, 17.8140678, 40.5937271, 17.4687576); |
| 1556 | path.close(); |
| 1557 | </div> |
| 1558 | |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 1559 | <div id="testQuadratic40x"> |
| 1560 | path.setFillType(SkPath::kEvenOdd_FillType); |
| 1561 | path.moveTo(2, 0); |
| 1562 | path.quadTo(3, 0, 2, 2); |
| 1563 | path.lineTo(3, 2); |
| 1564 | path.close(); |
| 1565 | path.moveTo(3, 1); |
| 1566 | path.lineTo(0, 2); |
| 1567 | path.quadTo(0, 2, 1, 2); |
| 1568 | path.close(); |
| 1569 | </div> |
| 1570 | |
| 1571 | <div id="testQuadratic40xa"> |
| 1572 | path.moveTo(31, 0); |
| 1573 | path.quadTo(41.3333359, 0, 37.8888893, 13.7777777); |
| 1574 | path.lineTo(31, 0); |
| 1575 | path.close(); |
| 1576 | path.moveTo(37.8888893, 13.7777777); |
| 1577 | path.quadTo(37.2993202, 16.1360455, 36.3061028, 18.8979664); |
| 1578 | path.lineTo(0, 31); |
| 1579 | path.lineTo(15.5, 31); |
| 1580 | path.lineTo(35.5182915, 20.9908543); |
| 1581 | path.quadTo(33.7454262, 25.5091457, 31, 31); |
| 1582 | path.lineTo(46.5, 31); |
| 1583 | path.lineTo(40.2999992, 18.6000004); |
| 1584 | path.lineTo(46.5, 15.5); |
| 1585 | path.lineTo(39.8571434, 17.7142868); |
| 1586 | path.lineTo(37.8888893, 13.7777777); |
| 1587 | path.close(); |
| 1588 | path.moveTo(36.3061028, 18.8979664); |
| 1589 | path.quadTo(35.9396667, 19.9169388, 35.5182915, 20.9908543); |
| 1590 | path.lineTo(40.2999992, 18.6000004); |
| 1591 | path.lineTo(39.8571434, 17.7142868); |
| 1592 | path.lineTo(36.3061028, 18.8979664); |
| 1593 | </div> |
| 1594 | |
| 1595 | <div id="testQuadratic40xb"> |
| 1596 | path.moveTo(31, 0); |
| 1597 | path.quadTo(46.5, 0, 31, 31); |
| 1598 | path.lineTo(46.5, 31); |
| 1599 | path.lineTo(31, 0); |
| 1600 | path.close(); |
| 1601 | path.moveTo(46.5, 15.5); |
| 1602 | path.lineTo(0, 31); |
| 1603 | path.quadTo(0, 31, 15.5, 31); |
| 1604 | path.lineTo(46.5, 15.5); |
| 1605 | path.close(); |
| 1606 | </div> |
| 1607 | |
| 1608 | <div id="testQuadratic41o"> |
| 1609 | path.moveTo(419.33905, 236.377808); |
| 1610 | path.quadTo(398.847778, 242.58728, 384.255524, 242.58728); |
| 1611 | path.quadTo(359.417633, 242.58728, 343.738708, 226.080429); |
| 1612 | path.quadTo(328.059784, 209.573578, 328.059784, 183.286819); |
| 1613 | path.quadTo(328.059784, 157.724487, 341.875854, 141.372879); |
| 1614 | path.quadTo(355.691956, 125.021263, 377.218109, 125.021263); |
| 1615 | path.quadTo(397.605896, 125.021263, 408.731201, 139.51004); |
| 1616 | path.quadTo(419.856506, 153.99881, 419.856506, 180.699539); |
| 1617 | path.lineTo(419.752991, 187.012497); |
| 1618 | path.lineTo(348.861511, 187.012497); |
| 1619 | path.quadTo(353.311646, 227.063599, 388.084686, 227.063599); |
| 1620 | path.quadTo(400.814117, 227.063599, 419.33905, 220.233185); |
| 1621 | path.lineTo(419.33905, 236.377808); |
| 1622 | path.close(); |
| 1623 | path.moveTo(349.792938, 171.695801); |
| 1624 | path.lineTo(399.365234, 171.695801); |
| 1625 | path.quadTo(399.365234, 140.337967, 375.976227, 140.337967); |
| 1626 | path.quadTo(352.483704, 140.337967, 349.792938, 171.695801); |
| 1627 | path.close(); |
| 1628 | path.moveTo(378.682587, 277.360321); |
| 1629 | path.lineTo(381.062897, 259.66333); |
| 1630 | path.quadTo(398.759888, 268.046112, 415.939423, 268.046112); |
| 1631 | path.quadTo(450.402008, 268.046112, 450.402008, 231.513718); |
| 1632 | path.lineTo(450.402008, 213.816727); |
| 1633 | path.quadTo(439.12146, 237.41272, 413.352142, 237.41272); |
| 1634 | path.quadTo(393.171356, 237.41272, 381.269867, 222.716965); |
| 1635 | path.quadTo(369.368378, 208.02121, 369.368378, 183.079834); |
| 1636 | path.quadTo(369.368378, 157.414017, 382.92572, 141.269379); |
| 1637 | path.quadTo(396.483093, 125.124756, 418.009247, 125.124756); |
| 1638 | path.quadTo(436.844666, 125.124756, 450.402008, 140.441467); |
| 1639 | path.lineTo(450.402008, 127.608543); |
| 1640 | path.lineTo(470.89325, 127.608543); |
| 1641 | path.lineTo(470.89325, 209.366608); |
| 1642 | path.quadTo(470.89325, 235.756866, 468.150757, 248.43454); |
| 1643 | path.quadTo(465.408234, 261.112213, 457.853363, 269.184509); |
| 1644 | path.quadTo(444.502991, 283.362823, 416.353394, 283.362823); |
| 1645 | path.quadTo(396.690063, 283.362823, 378.682587, 277.360321); |
| 1646 | path.close(); |
| 1647 | path.moveTo(450.402008, 201.087311); |
| 1648 | path.lineTo(450.402008, 154.412781); |
| 1649 | path.quadTo(436.948151, 140.441467, 421.113983, 140.441467); |
| 1650 | path.quadTo(407.039185, 140.441467, 399.070374, 151.722); |
| 1651 | path.quadTo(391.101532, 163.002533, 391.101532, 182.665863); |
| 1652 | path.quadTo(391.101532, 219.612228, 417.07782, 219.612228); |
| 1653 | path.quadTo(434.774841, 219.612228, 450.402008, 201.087311); |
| 1654 | path.close(); |
| 1655 | path.moveTo(482.9328, 236.377808); |
| 1656 | path.quadTo(462.441528, 242.58728, 447.849274, 242.58728); |
| 1657 | path.quadTo(423.011383, 242.58728, 407.332458, 226.080429); |
| 1658 | path.quadTo(391.653534, 209.573578, 391.653534, 183.286819); |
| 1659 | path.quadTo(391.653534, 157.724487, 405.469604, 141.372879); |
| 1660 | path.quadTo(419.285706, 125.021263, 440.811859, 125.021263); |
| 1661 | path.quadTo(461.199646, 125.021263, 472.324951, 139.51004); |
| 1662 | path.quadTo(483.450256, 153.99881, 483.450256, 180.699539); |
| 1663 | path.lineTo(483.346741, 187.012497); |
| 1664 | path.lineTo(412.455261, 187.012497); |
| 1665 | path.quadTo(416.905396, 227.063599, 451.678436, 227.063599); |
| 1666 | path.quadTo(464.407867, 227.063599, 482.9328, 220.233185); |
| 1667 | path.lineTo(482.9328, 236.377808); |
| 1668 | path.close(); |
| 1669 | path.moveTo(413.386688, 171.695801); |
| 1670 | path.lineTo(462.958984, 171.695801); |
| 1671 | path.quadTo(462.958984, 140.337967, 439.569977, 140.337967); |
| 1672 | path.quadTo(416.077454, 140.337967, 413.386688, 171.695801); |
| 1673 | path.close(); |
| 1674 | </div> |
| 1675 | |
| 1676 | <div id="testQuadratic41s"> |
| 1677 | path.moveTo(341.875854, 141.372879); |
| 1678 | path.quadTo(355.691956,125.021263, 377.218109,125.021263); |
| 1679 | path.quadTo(388.787811,125.021263, 397.374664,129.687164); |
| 1680 | path.quadTo(406.565979,125.124756, 418.009247,125.124756); |
| 1681 | path.quadTo(423.583374,125.124756, 428.695251,126.466187); |
| 1682 | path.quadTo(434.412903,125.021263, 440.811859,125.021263); |
| 1683 | path.quadTo(449.427277,125.021263, 456.388672,127.608543); |
| 1684 | path.lineTo(470.89325,127.608543); |
| 1685 | path.lineTo(470.89325,137.749908); |
| 1686 | path.quadTo(471.627319,138.601486, 472.324951,139.51004); |
| 1687 | path.quadTo(483.450256,153.99881, 483.450256,180.699539); |
| 1688 | path.lineTo(483.346741,187.012497); |
| 1689 | path.lineTo(470.89325,187.012497); |
| 1690 | path.lineTo(470.89325,209.366608); |
| 1691 | path.quadTo(470.89325,217.414856, 470.638184,224.187729); |
| 1692 | path.quadTo(476.428223,222.631516, 482.9328,220.233185); |
| 1693 | path.lineTo(482.9328,236.377808); |
| 1694 | path.quadTo(475.87207,238.517426, 469.511749,239.919785); |
| 1695 | path.quadTo(468.946777,244.754791, 468.150757,248.43454); |
| 1696 | path.quadTo(465.408234,261.112213, 457.853363,269.184509); |
| 1697 | path.quadTo(444.502991,283.362823, 416.353394,283.362823); |
| 1698 | path.quadTo(396.690063,283.362823, 378.682587,277.360321); |
| 1699 | path.lineTo(381.062897,259.66333); |
| 1700 | path.quadTo(398.759888,268.046112, 415.939423,268.046112); |
| 1701 | path.quadTo(444.719147,268.046112, 449.464905,242.568665); |
| 1702 | path.quadTo(448.648254,242.58728, 447.849274,242.58728); |
| 1703 | path.quadTo(433.084625,242.58728, 421.556366,236.754425); |
| 1704 | path.quadTo(418.89566,237.203537, 416.046783,237.346252); |
| 1705 | path.quadTo(397.661652,242.58728, 384.255524,242.58728); |
| 1706 | path.quadTo(359.417633,242.58728, 343.738708,226.080429); |
| 1707 | path.quadTo(328.059784,209.573578, 328.059784,183.286819); |
| 1708 | path.quadTo(328.059784,157.724487, 341.875854,141.372879); |
| 1709 | path.close(); |
| 1710 | path.moveTo(442.014923, 226.179474); |
| 1711 | path.quadTo(445.951935,226.953491, 450.402008,227.049881); |
| 1712 | path.lineTo(450.402008,213.816727); |
| 1713 | path.quadTo(446.904755,221.132065, 442.014923,226.179474); |
| 1714 | path.close(); |
| 1715 | path.moveTo(395.347717, 206.501785); |
| 1716 | path.quadTo(392.200165,197.593536, 391.734406,187.012497); |
| 1717 | path.lineTo(391.197113,187.012497); |
| 1718 | path.quadTo(391.738647,198.938644, 395.347717,206.501785); |
| 1719 | path.close(); |
| 1720 | path.moveTo(391.808533, 171.695801); |
| 1721 | path.lineTo(392.428436,171.695801); |
| 1722 | path.quadTo(393.693451,162.656265, 397.02359,154.9935); |
| 1723 | path.quadTo(397.023804,154.992996, 397.024048,154.992493); |
| 1724 | path.quadTo(393.175995,143.845093, 383.003235,141.177292); |
| 1725 | path.quadTo(382.964447,141.223267, 382.92572,141.269379); |
| 1726 | </div> |
| 1727 | |
| 1728 | <div id="testQuadratic42o"> |
| 1729 | path.moveTo(421.962158, 236.285355); |
| 1730 | path.quadTo(400.947845, 242.65332, 385.983124, 242.65332); |
| 1731 | path.quadTo(360.511261, 242.65332, 344.432129, 225.725143); |
| 1732 | path.quadTo(328.352997, 208.796951, 328.352997, 181.839218); |
| 1733 | path.quadTo(328.352997, 155.62442, 342.521729, 138.855438); |
| 1734 | path.quadTo(356.69046, 122.086449, 378.766083, 122.086449); |
| 1735 | path.quadTo(399.674255, 122.086449, 411.083527, 136.945038); |
| 1736 | path.quadTo(422.492798, 151.803635, 422.492798, 179.185898); |
| 1737 | path.lineTo(422.386688, 185.660004); |
| 1738 | path.lineTo(349.685699, 185.660004); |
| 1739 | path.quadTo(354.24942, 226.733398, 389.910034, 226.733398); |
| 1740 | path.quadTo(402.964386, 226.733398, 421.962158, 219.728638); |
| 1741 | path.lineTo(421.962158, 236.285355); |
| 1742 | path.close(); |
| 1743 | path.moveTo(350.6409, 169.952347); |
| 1744 | path.lineTo(401.478516, 169.952347); |
| 1745 | path.quadTo(401.478516, 137.794098, 377.492493, 137.794098); |
| 1746 | path.quadTo(353.40036, 137.794098, 350.6409, 169.952347); |
| 1747 | path.close(); |
| 1748 | path.moveTo(379.213562, 278.313934); |
| 1749 | path.lineTo(381.654602, 260.165222); |
| 1750 | path.quadTo(399.803314, 268.761993, 417.421356, 268.761993); |
| 1751 | path.quadTo(452.763611, 268.761993, 452.763611, 231.297104); |
| 1752 | path.lineTo(452.763611, 213.148392); |
| 1753 | path.quadTo(441.195129, 237.34668, 414.768036, 237.34668); |
| 1754 | path.quadTo(394.072144, 237.34668, 381.866882, 222.275818); |
| 1755 | path.quadTo(369.661591, 207.204956, 369.661591, 181.626953); |
| 1756 | path.quadTo(369.661591, 155.306015, 383.565002, 138.749298); |
| 1757 | path.quadTo(397.468384, 122.192581, 419.544037, 122.192581); |
| 1758 | path.quadTo(438.860199, 122.192581, 452.763611, 137.900238); |
| 1759 | path.lineTo(452.763611, 124.739769); |
| 1760 | path.lineTo(473.777893, 124.739769); |
| 1761 | path.lineTo(473.777893, 208.584686); |
| 1762 | path.quadTo(473.777893, 235.64856, 470.965363, 248.649826); |
| 1763 | path.quadTo(468.152863, 261.651093, 460.405151, 269.929443); |
| 1764 | path.quadTo(446.71402, 284.469666, 417.845886, 284.469666); |
| 1765 | path.quadTo(397.680664, 284.469666, 379.213562, 278.313934); |
| 1766 | path.close(); |
| 1767 | path.moveTo(452.763611, 200.094055); |
| 1768 | path.lineTo(452.763611, 152.228165); |
| 1769 | path.quadTo(438.966339, 137.900238, 422.727997, 137.900238); |
| 1770 | path.quadTo(408.293945, 137.900238, 400.121704, 149.468719); |
| 1771 | path.quadTo(391.949493, 161.037186, 391.949493, 181.202423); |
| 1772 | path.quadTo(391.949493, 219.091827, 418.588837, 219.091827); |
| 1773 | path.quadTo(436.737549, 219.091827, 452.763611, 200.094055); |
| 1774 | path.close(); |
| 1775 | path.moveTo(485.555908, 236.285355); |
| 1776 | path.quadTo(464.541595, 242.65332, 449.576874, 242.65332); |
| 1777 | path.quadTo(424.105011, 242.65332, 408.025879, 225.725143); |
| 1778 | path.quadTo(391.946747, 208.796951, 391.946747, 181.839218); |
| 1779 | path.quadTo(391.946747, 155.62442, 406.115479, 138.855438); |
| 1780 | path.quadTo(420.28421, 122.086449, 442.359833, 122.086449); |
| 1781 | path.quadTo(463.268005, 122.086449, 474.677277, 136.945038); |
| 1782 | path.quadTo(486.086548, 151.803635, 486.086548, 179.185898); |
| 1783 | path.lineTo(485.980438, 185.660004); |
| 1784 | path.lineTo(413.279449, 185.660004); |
| 1785 | path.quadTo(417.84317, 226.733398, 453.503784, 226.733398); |
| 1786 | path.quadTo(466.558136, 226.733398, 485.555908, 219.728638); |
| 1787 | path.lineTo(485.555908, 236.285355); |
| 1788 | path.close(); |
| 1789 | path.moveTo(414.23465, 169.952347); |
| 1790 | path.lineTo(465.072266, 169.952347); |
| 1791 | path.quadTo(465.072266, 137.794098, 441.086243, 137.794098); |
| 1792 | path.quadTo(416.99411, 137.794098, 414.23465, 169.952347); |
| 1793 | path.close(); |
| 1794 | </div> |
| 1795 | |
| 1796 | <div id="testQuadratic42s"> |
| 1797 | path.moveTo(342.521729, 138.855438); |
| 1798 | path.quadTo(356.69046,122.086449, 378.766083,122.086449); |
| 1799 | path.quadTo(390.293488,122.086449, 398.933502,126.603004); |
| 1800 | path.quadTo(408.150299,122.192581, 419.544037,122.192581); |
| 1801 | path.quadTo(425.108429,122.192581, 430.223633,123.496056); |
| 1802 | path.quadTo(435.959412,122.086449, 442.359833,122.086449); |
| 1803 | path.quadTo(451.19516,122.086449, 458.334229,124.739769); |
| 1804 | path.lineTo(473.777893,124.739769); |
| 1805 | path.lineTo(473.777893,135.814713); |
| 1806 | path.quadTo(474.234741,136.368698, 474.677277,136.945038); |
| 1807 | path.quadTo(486.086548,151.803635, 486.086548,179.185898); |
| 1808 | path.lineTo(485.980438,185.660004); |
| 1809 | path.lineTo(473.777893,185.660004); |
| 1810 | path.lineTo(473.777893,208.584686); |
| 1811 | path.quadTo(473.777893,216.745773, 473.522156,223.628113); |
| 1812 | path.quadTo(479.207153,222.069519, 485.555908,219.728638); |
| 1813 | path.lineTo(485.555908,236.285355); |
| 1814 | path.quadTo(478.638306,238.381592, 472.376221,239.787796); |
| 1815 | path.quadTo(471.792389,244.826782, 470.965363,248.649826); |
| 1816 | path.quadTo(468.152863,261.651093, 460.405151,269.929443); |
| 1817 | path.quadTo(446.71402,284.469666, 417.845886,284.469666); |
| 1818 | path.quadTo(397.680664,284.469666, 379.213562,278.313934); |
| 1819 | path.lineTo(381.654602,260.165222); |
| 1820 | path.quadTo(399.803314,268.761993, 417.421356,268.761993); |
| 1821 | path.quadTo(446.944275,268.761993, 451.80542,242.619034); |
| 1822 | path.quadTo(450.674866,242.65332, 449.576874,242.65332); |
| 1823 | path.quadTo(434.524628,242.65332, 422.75238,236.741913); |
| 1824 | path.quadTo(420.864227,237.041901, 418.884674,237.193085); |
| 1825 | path.quadTo(399.840271,242.65332, 385.983124,242.65332); |
| 1826 | path.quadTo(360.511261,242.65332, 344.432129,225.725143); |
| 1827 | path.quadTo(328.352997,208.796951, 328.352997,181.839218); |
| 1828 | path.quadTo(328.352997,155.62442, 342.521729,138.855438); |
| 1829 | path.close(); |
| 1830 | path.moveTo(383.823944, 138.443222); |
| 1831 | path.quadTo(380.900299,137.794098, 377.492493,137.794098); |
| 1832 | path.quadTo(353.40036,137.794098, 350.6409,169.952347); |
| 1833 | path.lineTo(370.408203,169.952347); |
| 1834 | path.quadTo(372.883484,151.469254, 383.565002,138.749298); |
| 1835 | path.quadTo(383.694122,138.595551, 383.823944,138.443222); |
| 1836 | path.close(); |
| 1837 | path.moveTo(369.740021, 185.660004); |
| 1838 | path.lineTo(349.685699,185.660004); |
| 1839 | path.quadTo(353.983734,224.342361, 385.863525,226.594208); |
| 1840 | path.quadTo(383.762756,224.616837, 381.866882,222.275818); |
| 1841 | path.quadTo(370.639954,208.41301, 369.740021,185.660004); |
| 1842 | path.close(); |
| 1843 | path.moveTo(413.279449, 185.660004); |
| 1844 | path.quadTo(415.737305,207.780716, 427.214905,217.987976); |
| 1845 | path.quadTo(440.600586,214.512451, 452.763611,200.094055); |
| 1846 | path.lineTo(452.763611,185.660004); |
| 1847 | </div> |
| 1848 | |
| 1849 | <div id="testQuadratic43o"> |
| 1850 | path.moveTo(288.755981, 240); |
| 1851 | path.lineTo(288.755981, 102.232819); |
| 1852 | path.lineTo(315.843994, 102.232819); |
| 1853 | path.lineTo(354.009216, 208.816208); |
| 1854 | path.lineTo(393.291473, 102.232819); |
| 1855 | path.lineTo(417.493835, 102.232819); |
| 1856 | path.lineTo(417.493835, 240); |
| 1857 | path.lineTo(399.248962, 240); |
| 1858 | path.lineTo(399.248962, 127.92453); |
| 1859 | path.lineTo(361.269928, 230.784485); |
| 1860 | path.lineTo(342.373474, 230.784485); |
| 1861 | path.lineTo(305.511444, 127.645271); |
| 1862 | path.lineTo(305.511444, 240); |
| 1863 | path.lineTo(288.755981, 240); |
| 1864 | path.close(); |
| 1865 | path.moveTo(397.864014, 236.741989); |
| 1866 | path.quadTo(379.433014, 242.327148, 366.307892, 242.327148); |
| 1867 | path.quadTo(343.967255, 242.327148, 329.864746, 227.479935); |
| 1868 | path.quadTo(315.762238, 212.632736, 315.762238, 188.988907); |
| 1869 | path.quadTo(315.762238, 165.996674, 328.189209, 151.289093); |
| 1870 | path.quadTo(340.61618, 136.581512, 359.978058, 136.581512); |
| 1871 | path.quadTo(378.315979, 136.581512, 388.322723, 149.613556); |
| 1872 | path.quadTo(398.329468, 162.645584, 398.329468, 186.661758); |
| 1873 | path.lineTo(398.236359, 192.339996); |
| 1874 | path.lineTo(334.472504, 192.339996); |
| 1875 | path.quadTo(338.475189, 228.364258, 369.752075, 228.364258); |
| 1876 | path.quadTo(381.20163, 228.364258, 397.864014, 222.220581); |
| 1877 | path.lineTo(397.864014, 236.741989); |
| 1878 | path.close(); |
| 1879 | path.moveTo(335.310272, 178.563278); |
| 1880 | path.lineTo(379.898438, 178.563278); |
| 1881 | path.quadTo(379.898438, 150.358246, 358.861023, 150.358246); |
| 1882 | path.quadTo(337.730499, 150.358246, 335.310272, 178.563278); |
| 1883 | path.close(); |
| 1884 | path.moveTo(346.052765, 240); |
| 1885 | path.lineTo(346.052765, 138.908661); |
| 1886 | path.lineTo(364.390686, 138.908661); |
| 1887 | path.lineTo(364.390686, 157.898193); |
| 1888 | path.quadTo(375.281769, 136.674606, 396.039917, 136.674606); |
| 1889 | path.quadTo(398.832489, 136.674606, 401.904327, 137.140045); |
| 1890 | path.lineTo(401.904327, 154.267853); |
| 1891 | path.quadTo(397.156952, 152.685394, 393.526611, 152.685394); |
| 1892 | path.quadTo(376.119537, 152.685394, 364.390686, 173.350464); |
| 1893 | path.lineTo(364.390686, 240); |
| 1894 | path.lineTo(346.052765, 240); |
| 1895 | path.close(); |
| 1896 | path.moveTo(362.792297, 273.604034); |
| 1897 | path.lineTo(364.933289, 257.68634); |
| 1898 | path.quadTo(380.850983, 265.226288, 396.303253, 265.226288); |
| 1899 | path.quadTo(427.300842, 265.226288, 427.300842, 232.366959); |
| 1900 | path.lineTo(427.300842, 216.449265); |
| 1901 | path.quadTo(417.15448, 237.672852, 393.976105, 237.672852); |
| 1902 | path.quadTo(375.824341, 237.672852, 365.119446, 224.454651); |
| 1903 | path.quadTo(354.414581, 211.23645, 354.414581, 188.802734); |
| 1904 | path.quadTo(354.414581, 165.717422, 366.608826, 151.196014); |
| 1905 | path.quadTo(378.803101, 136.674606, 398.164948, 136.674606); |
| 1906 | path.quadTo(415.106598, 136.674606, 427.300842, 150.451324); |
| 1907 | path.lineTo(427.300842, 138.908661); |
| 1908 | path.lineTo(445.731873, 138.908661); |
| 1909 | path.lineTo(445.731873, 212.446564); |
| 1910 | path.quadTo(445.731873, 236.183472, 443.265106, 247.586502); |
| 1911 | path.quadTo(440.798309, 258.989532, 434.003052, 266.250244); |
| 1912 | path.quadTo(421.994965, 279.002991, 396.675598, 279.002991); |
| 1913 | path.quadTo(378.989258, 279.002991, 362.792297, 273.604034); |
| 1914 | path.close(); |
| 1915 | path.moveTo(427.300842, 204.999695); |
| 1916 | path.lineTo(427.300842, 163.017929); |
| 1917 | path.quadTo(415.199677, 150.451324, 400.95755, 150.451324); |
| 1918 | path.quadTo(388.297852, 150.451324, 381.130249, 160.597687); |
| 1919 | path.quadTo(373.962616, 170.744064, 373.962616, 188.430389); |
| 1920 | path.quadTo(373.962616, 221.662079, 397.327179, 221.662079); |
| 1921 | path.quadTo(413.244873, 221.662079, 427.300842, 204.999695); |
| 1922 | path.close(); |
| 1923 | path.moveTo(461.457764, 236.741989); |
| 1924 | path.quadTo(443.026764, 242.327148, 429.901642, 242.327148); |
| 1925 | path.quadTo(407.561005, 242.327148, 393.458496, 227.479935); |
| 1926 | path.quadTo(379.355988, 212.632736, 379.355988, 188.988907); |
| 1927 | path.quadTo(379.355988, 165.996674, 391.782959, 151.289093); |
| 1928 | path.quadTo(404.20993, 136.581512, 423.571808, 136.581512); |
| 1929 | path.quadTo(441.909729, 136.581512, 451.916473, 149.613556); |
| 1930 | path.quadTo(461.923218, 162.645584, 461.923218, 186.661758); |
| 1931 | path.lineTo(461.830109, 192.339996); |
| 1932 | path.lineTo(398.066254, 192.339996); |
| 1933 | path.quadTo(402.068939, 228.364258, 433.345825, 228.364258); |
| 1934 | path.quadTo(444.79538, 228.364258, 461.457764, 222.220581); |
| 1935 | path.lineTo(461.457764, 236.741989); |
| 1936 | path.close(); |
| 1937 | path.moveTo(398.904022, 178.563278); |
| 1938 | path.lineTo(443.492188, 178.563278); |
| 1939 | path.quadTo(443.492188, 150.358246, 422.454773, 150.358246); |
| 1940 | path.quadTo(401.324249, 150.358246, 398.904022, 178.563278); |
| 1941 | path.close(); |
| 1942 | </div> |
| 1943 | |
| 1944 | <div id="testQuadratic43s"> |
| 1945 | path.moveTo(288.755981, 240); |
| 1946 | path.lineTo(288.755981,102.232819); |
| 1947 | path.lineTo(315.843994,102.232819); |
| 1948 | path.lineTo(331.979736,147.294876); |
| 1949 | path.quadTo(343.453125,136.581512, 359.978058,136.581512); |
| 1950 | path.quadTo(370.869446,136.581512, 378.822021,141.178574); |
| 1951 | path.quadTo(378.893585,141.140915, 378.965302,141.103577); |
| 1952 | path.lineTo(393.291473,102.232819); |
| 1953 | path.lineTo(417.493835,102.232819); |
| 1954 | path.lineTo(417.493835,136.965759); |
| 1955 | path.quadTo(420.44223,136.581512, 423.571808,136.581512); |
| 1956 | path.quadTo(431.320984,136.581512, 437.582458,138.908661); |
| 1957 | path.lineTo(445.731873,138.908661); |
| 1958 | path.lineTo(445.731873,143.392502); |
| 1959 | path.quadTo(449.143951,146.002823, 451.916473,149.613556); |
| 1960 | path.quadTo(461.923218,162.645584, 461.923218,186.661758); |
| 1961 | path.lineTo(461.830109,192.339996); |
| 1962 | path.lineTo(445.731873,192.339996); |
| 1963 | path.lineTo(445.731873,212.446564); |
| 1964 | path.quadTo(445.731873,220.39856, 445.455017,226.966339); |
| 1965 | path.quadTo(452.7435,225.43367, 461.457764,222.220581); |
| 1966 | path.lineTo(461.457764,236.741989); |
| 1967 | path.quadTo(452.250824,239.531982, 444.367889,240.928268); |
| 1968 | path.quadTo(443.897583,244.662796, 443.265106,247.586502); |
| 1969 | path.quadTo(440.798309,258.989532, 434.003052,266.250244); |
| 1970 | path.quadTo(421.994965,279.002991, 396.675598,279.002991); |
| 1971 | path.quadTo(378.989258,279.002991, 362.792297,273.604034); |
| 1972 | path.lineTo(364.933289,257.68634); |
| 1973 | path.quadTo(380.850983,265.226288, 396.303253,265.226288); |
| 1974 | path.quadTo(422.230743,265.226288, 426.471558,242.237076); |
| 1975 | path.quadTo(419.570892,241.869324, 413.503387,240); |
| 1976 | path.lineTo(399.248962,240); |
| 1977 | path.lineTo(399.248962,237.37915); |
| 1978 | path.quadTo(397.047638,237.633072, 394.711517,237.667465); |
| 1979 | path.quadTo(378.296356,242.327148, 366.307892,242.327148); |
| 1980 | path.quadTo(357.463165,242.327148, 349.909637,240); |
| 1981 | path.lineTo(346.052765,240); |
| 1982 | path.lineTo(346.052765,238.625916); |
| 1983 | path.quadTo(336.926056,234.914124, 329.864746,227.479935); |
| 1984 | path.quadTo(315.762238,212.632736, 315.762238,188.988907); |
| 1985 | path.quadTo(315.762238,176.540054, 319.405273,166.519882); |
| 1986 | path.lineTo(305.511444,127.645271); |
| 1987 | path.lineTo(305.511444,240); |
| 1988 | path.lineTo(288.755981,240); |
| 1989 | path.close(); |
| 1990 | path.moveTo(375.464813, 192.339996); |
| 1991 | path.lineTo(374.267029,195.583939); |
| 1992 | path.quadTo(375.987579,214.575378, 387.432068,219.736267); |
| 1993 | path.quadTo(380.122528,208.101486, 379.428741,192.339996); |
| 1994 | path.lineTo(375.464813,192.339996); |
| 1995 | path.close(); |
| 1996 | path.moveTo(427.300842, 178.563278); |
| 1997 | path.lineTo(427.300842,163.017929); |
| 1998 | path.quadTo(422.561523,158.096329, 417.493835,155.102234); |
| 1999 | path.lineTo(417.493835,178.563278); |
| 2000 | path.lineTo(427.300842,178.563278); |
| 2001 | path.close(); |
| 2002 | path.moveTo(427.300842, 192.339996); |
| 2003 | path.lineTo(417.493835,192.339996); |
| 2004 | path.lineTo(417.493835,214.429169); |
| 2005 | path.quadTo(422.505676,210.684036, 427.300842,204.999695); |
| 2006 | path.lineTo(427.300842,192.339996); |
| 2007 | path.close(); |
| 2008 | path.moveTo(420.700134, 226.556015); |
| 2009 | path.quadTo(423.794342,227.54834, 427.300842,227.996094); |
| 2010 | path.lineTo(427.300842,216.449265); |
| 2011 | path.quadTo(424.497772,222.312531, 420.700134,226.556015); |
| 2012 | path.close(); |
| 2013 | path.moveTo(368.744965, 228.354782); |
| 2014 | path.quadTo(366.836426,226.574738, 365.119446,224.454651); |
| 2015 | path.quadTo(364.748657,223.996796, 364.390686,223.527878); |
| 2016 | path.lineTo(364.390686,228.077774); |
| 2017 | path.quadTo(366.495239,228.312164, 368.744965,228.354782); |
| 2018 | path.close(); |
| 2019 | path.moveTo(399.248962, 199.701065); |
| 2020 | path.lineTo(399.248962,192.339996); |
| 2021 | path.lineTo(398.236359,192.339996); |
| 2022 | path.lineTo(398.066254,192.339996); |
| 2023 | path.quadTo(398.498535,196.230621, 399.248962,199.701065); |
| 2024 | path.close(); |
| 2025 | path.moveTo(399.248962, 178.563278); |
| 2026 | path.lineTo(399.248962,175.376892); |
| 2027 | path.quadTo(399.04483,176.922348, 398.904022,178.563278); |
| 2028 | path.lineTo(399.248962,178.563278); |
| 2029 | path.close(); |
| 2030 | path.moveTo(399.248962, 136.688828); |
| 2031 | path.lineTo(399.248962,127.92453); |
| 2032 | path.lineTo(396.018158,136.674606); |
| 2033 | path.quadTo(396.029053,136.674606, 396.039917,136.674606); |
| 2034 | path.quadTo(396.513672,136.674606, 396.995453,136.688004); |
| 2035 | path.quadTo(397.576904,136.674606, 398.164948,136.674606); |
| 2036 | path.quadTo(398.709412,136.674606, 399.248962,136.688828); |
| 2037 | path.close(); |
| 2038 | path.moveTo(346.052765, 178.563278); |
| 2039 | path.lineTo(346.052765,154.02713); |
| 2040 | path.quadTo(340.97113,157.621338, 338.22525,164.736588); |
| 2041 | path.lineTo(343.1763,178.563278); |
| 2042 | path.lineTo(346.052765,178.563278); |
| 2043 | path.close(); |
| 2044 | path.moveTo(364.390686, 150.922379); |
| 2045 | path.lineTo(364.390686,154.048065); |
| 2046 | path.quadTo(365.340851,152.726639, 366.38147,151.468765); |
| 2047 | path.quadTo(365.420258,151.14975, 364.390686,150.922379); |
| 2048 | path.close(); |
| 2049 | path.moveTo(367.863586, 152.032623); |
| 2050 | path.quadTo(367.144043,151.721848, 366.38147,151.468765); |
| 2051 | </div> |
| 2052 | |
| 2053 | <div id="testQuadratic44o"> |
| 2054 | path.moveTo(354.009216, 208.816208); |
| 2055 | path.lineTo(393.291473, 102.232819); |
| 2056 | path.lineTo(399.248962, 127.92453); |
| 2057 | path.lineTo(361.269928, 230.784485); |
| 2058 | path.lineTo(354.009216, 208.816208); |
| 2059 | path.close(); |
| 2060 | path.moveTo(328.189209, 151.289093); |
| 2061 | path.quadTo(340.61618, 136.581512, 359.978058, 136.581512); |
| 2062 | path.quadTo(378.315979, 136.581512, 388.322723, 149.613556); |
| 2063 | path.lineTo(328.189209, 151.289093); |
| 2064 | path.close(); |
| 2065 | path.moveTo(346.052765, 138.908661); |
| 2066 | path.lineTo(364.390686, 138.908661); |
| 2067 | path.lineTo(364.390686, 157.898193); |
| 2068 | path.quadTo(375.281769, 136.674606, 396.039917, 136.674606); |
| 2069 | path.lineTo(346.052765, 138.908661); |
| 2070 | path.close(); |
| 2071 | </div> |
| 2072 | |
| 2073 | <div id="testQuadratic44s"> |
| 2074 | path.moveTo(380.33902, 137.376312); |
| 2075 | path.lineTo(393.291473,102.232819); |
| 2076 | path.lineTo(399.248962,127.92453); |
| 2077 | path.lineTo(396.018158,136.674606); |
| 2078 | path.quadTo(396.029053,136.674606, 396.039917,136.674606); |
| 2079 | path.lineTo(396.017792,136.675598); |
| 2080 | path.lineTo(361.269928,230.784485); |
| 2081 | path.lineTo(354.009216,208.816208); |
| 2082 | path.lineTo(375.699249,149.965286); |
| 2083 | path.lineTo(369.22699,150.14563); |
| 2084 | path.quadTo(373.524384,144.511566, 378.917297,141.233871); |
| 2085 | path.lineTo(380.33902,137.376312); |
| 2086 | path.close(); |
caryclark@google.com | a461ff0 | 2012-10-11 12:54:23 +0000 | [diff] [blame^] | 2087 | path.moveTo(380.33902, 137.376312); |
| 2088 | path.lineTo(378.917297,141.233856); |
| 2089 | path.quadTo(375.048248,138.978912, 370.480499,137.816925); |
| 2090 | path.lineTo(380.33902,137.376312); |
| 2091 | path.close(); |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2092 | path.moveTo(392.55661, 136.830276); |
caryclark@google.com | a461ff0 | 2012-10-11 12:54:23 +0000 | [diff] [blame^] | 2093 | path.lineTo(380.33902,137.376312); |
| 2094 | </div> |
| 2095 | |
| 2096 | <div id="testQuadratic45o"> |
| 2097 | path.moveTo(315.843994, 102.232819); |
| 2098 | path.lineTo(354.009216, 208.816208); |
| 2099 | path.lineTo(393.291473, 102.232819); |
| 2100 | path.lineTo(399.248962, 127.92453); |
| 2101 | path.lineTo(361.269928, 230.784485); |
| 2102 | path.lineTo(342.373474, 230.784485); |
| 2103 | path.lineTo(305.511444, 127.645271); |
| 2104 | path.lineTo(315.843994, 102.232819); |
| 2105 | path.close(); |
| 2106 | path.moveTo(366.307892, 242.327148); |
| 2107 | path.quadTo(343.967255, 242.327148, 329.864746, 227.479935); |
| 2108 | path.quadTo(315.762238, 212.632736, 315.762238, 188.988907); |
| 2109 | path.quadTo(315.762238, 165.996674, 328.189209, 151.289093); |
| 2110 | path.quadTo(340.61618, 136.581512, 359.978058, 136.581512); |
| 2111 | path.quadTo(378.315979, 136.581512, 388.322723, 149.613556); |
| 2112 | path.quadTo(398.329468, 162.645584, 398.329468, 186.661758); |
| 2113 | path.lineTo(398.236359, 192.339996); |
| 2114 | path.lineTo(334.472504, 192.339996); |
| 2115 | path.quadTo(338.475189, 228.364258, 369.752075, 228.364258); |
| 2116 | path.quadTo(381.20163, 228.364258, 397.864014, 222.220581); |
| 2117 | path.lineTo(366.307892, 242.327148); |
| 2118 | path.close(); |
| 2119 | path.moveTo(335.310272, 178.563278); |
| 2120 | path.lineTo(379.898438, 178.563278); |
| 2121 | path.quadTo(379.898438, 150.358246, 358.861023, 150.358246); |
| 2122 | path.quadTo(337.730499, 150.358246, 335.310272, 178.563278); |
| 2123 | path.close(); |
| 2124 | path.moveTo(346.052765, 240); |
| 2125 | path.lineTo(346.052765, 138.908661); |
| 2126 | path.lineTo(364.390686, 138.908661); |
| 2127 | path.lineTo(364.390686, 157.898193); |
| 2128 | path.quadTo(375.281769, 136.674606, 396.039917, 136.674606); |
| 2129 | path.lineTo(401.904327, 154.267853); |
| 2130 | path.quadTo(397.156952, 152.685394, 393.526611, 152.685394); |
| 2131 | path.quadTo(376.119537, 152.685394, 364.390686, 173.350464); |
| 2132 | path.lineTo(364.390686, 240); |
| 2133 | path.lineTo(346.052765, 240); |
| 2134 | path.close(); |
| 2135 | path.moveTo(396.303253, 265.226288); |
| 2136 | path.quadTo(427.300842, 265.226288, 427.300842, 232.366959); |
| 2137 | path.lineTo(427.300842, 216.449265); |
| 2138 | path.quadTo(417.15448, 237.672852, 393.976105, 237.672852); |
| 2139 | path.quadTo(375.824341, 237.672852, 365.119446, 224.454651); |
| 2140 | path.quadTo(354.414581, 211.23645, 354.414581, 188.802734); |
| 2141 | path.quadTo(354.414581, 165.717422, 366.608826, 151.196014); |
| 2142 | path.quadTo(378.803101, 136.674606, 398.164948, 136.674606); |
| 2143 | path.lineTo(396.303253, 265.226288); |
| 2144 | path.close(); |
| 2145 | path.moveTo(400.95755, 150.451324); |
| 2146 | path.quadTo(388.297852, 150.451324, 381.130249, 160.597687); |
| 2147 | path.quadTo(373.962616, 170.744064, 373.962616, 188.430389); |
| 2148 | path.quadTo(373.962616, 221.662079, 397.327179, 221.662079); |
| 2149 | path.lineTo(400.95755, 150.451324); |
| 2150 | path.close(); |
| 2151 | path.moveTo(429.901642, 242.327148); |
| 2152 | path.quadTo(407.561005, 242.327148, 393.458496, 227.479935); |
| 2153 | path.quadTo(379.355988, 212.632736, 379.355988, 188.988907); |
| 2154 | path.quadTo(379.355988, 165.996674, 391.782959, 151.289093); |
| 2155 | path.quadTo(404.20993, 136.581512, 423.571808, 136.581512); |
| 2156 | path.lineTo(429.901642, 242.327148); |
| 2157 | path.close(); |
| 2158 | </div> |
| 2159 | |
| 2160 | <div id="testQuadratic45s"> |
| 2161 | path.moveTo(305.511444, 127.645271); |
| 2162 | path.lineTo(315.843994,102.232819); |
| 2163 | path.lineTo(331.979736,147.294876); |
| 2164 | path.quadTo(343.453125,136.581512, 359.978058,136.581512); |
| 2165 | path.quadTo(370.869446,136.581512, 378.822021,141.178574); |
| 2166 | path.quadTo(378.893585,141.140915, 378.965302,141.103577); |
| 2167 | path.lineTo(393.291473,102.232819); |
| 2168 | path.lineTo(399.248962,127.92453); |
| 2169 | path.lineTo(396.018158,136.674606); |
| 2170 | path.quadTo(396.029053,136.674606, 396.039917,136.674606); |
| 2171 | path.lineTo(396.054596,136.718628); |
| 2172 | path.quadTo(397.098907,136.674606, 398.164948,136.674606); |
| 2173 | path.lineTo(398.076477,142.784256); |
| 2174 | path.lineTo(398.697632,144.647751); |
| 2175 | path.quadTo(409.233032,136.581512, 423.571808,136.581512); |
| 2176 | path.lineTo(429.901642,242.327148); |
| 2177 | path.quadTo(428.161621,242.327148, 426.471558,242.237076); |
| 2178 | path.quadTo(427.300842,237.741562, 427.300842,232.366959); |
| 2179 | path.lineTo(427.300842,216.449265); |
| 2180 | path.quadTo(419.710114,232.327133, 404.8255,236.326401); |
| 2181 | path.quadTo(400.557983,233.971252, 396.803375,230.691772); |
| 2182 | path.lineTo(396.7034,237.596863); |
| 2183 | path.quadTo(395.363068,237.672852, 393.976105,237.672852); |
| 2184 | path.quadTo(385.309937,237.672852, 378.341187,234.659912); |
| 2185 | path.lineTo(366.307892,242.327148); |
| 2186 | path.quadTo(357.463165,242.327148, 349.909637,240); |
| 2187 | path.lineTo(346.052765,240); |
| 2188 | path.lineTo(346.052765,238.625916); |
| 2189 | path.quadTo(336.926056,234.914124, 329.864746,227.479935); |
| 2190 | path.quadTo(315.762238,212.632736, 315.762238,188.988907); |
| 2191 | path.quadTo(315.762238,176.540054, 319.405273,166.519882); |
| 2192 | path.lineTo(305.511444,127.645271); |
| 2193 | path.close(); |
| 2194 | path.moveTo(375.464813, 192.339996); |
| 2195 | path.lineTo(374.267029,195.583939); |
| 2196 | path.quadTo(375.987579,214.575378, 387.432068,219.736267); |
| 2197 | path.quadTo(380.122528,208.101486, 379.428741,192.339996); |
| 2198 | path.lineTo(375.464813,192.339996); |
| 2199 | path.close(); |
| 2200 | path.moveTo(397.925934, 153.178131); |
| 2201 | path.lineTo(397.615479,174.615356); |
| 2202 | path.quadTo(398.329468,180.246704, 398.329468,186.661758); |
| 2203 | path.lineTo(398.236359,192.339996); |
| 2204 | path.lineTo(397.358795,192.339996); |
| 2205 | path.lineTo(396.934174,221.659714); |
| 2206 | path.quadTo(397.129852,221.662079, 397.327179,221.662079); |
| 2207 | path.lineTo(400.781189,153.910889); |
| 2208 | path.quadTo(399.295654,153.462463, 397.925934,153.178131); |
| 2209 | path.close(); |
| 2210 | path.moveTo(400.914398, 151.298019); |
| 2211 | path.lineTo(400.632721,150.453003); |
| 2212 | path.quadTo(400.794678,150.451324, 400.95755,150.451324); |
| 2213 | path.lineTo(400.914398,151.298019); |
| 2214 | path.close(); |
| 2215 | path.moveTo(368.744965, 228.354782); |
| 2216 | path.quadTo(366.836426,226.574738, 365.119446,224.454651); |
| 2217 | path.quadTo(364.748657,223.996796, 364.390686,223.527878); |
| 2218 | path.lineTo(364.390686,228.077774); |
| 2219 | path.quadTo(366.495239,228.312164, 368.744965,228.354782); |
| 2220 | path.close(); |
| 2221 | path.moveTo(346.052765, 178.563278); |
| 2222 | path.lineTo(346.052765,154.02713); |
| 2223 | path.quadTo(340.97113,157.621338, 338.22525,164.736588); |
| 2224 | path.lineTo(343.1763,178.563278); |
| 2225 | path.lineTo(346.052765,178.563278); |
| 2226 | path.close(); |
| 2227 | path.moveTo(364.390686, 150.922379); |
| 2228 | path.lineTo(364.390686,154.048065); |
| 2229 | path.quadTo(365.340851,152.726639, 366.38147,151.468765); |
| 2230 | path.quadTo(365.420258,151.14975, 364.390686,150.922379); |
| 2231 | path.close(); |
| 2232 | path.moveTo(367.863586, 152.032623); |
| 2233 | path.quadTo(367.144043,151.721848, 366.38147,151.468765); |
| 2234 | </div> |
| 2235 | |
| 2236 | <div id="testQuadratic46o"> |
| 2237 | path.moveTo(366.608826, 151.196014); |
| 2238 | path.quadTo(378.803101, 136.674606, 398.164948, 136.674606); |
| 2239 | path.lineTo(354.009216, 208.816208); |
| 2240 | path.lineTo(393.291473, 102.232819); |
| 2241 | path.lineTo(359.978058, 136.581512); |
| 2242 | path.quadTo(378.315979, 136.581512, 388.322723, 149.613556); |
| 2243 | path.lineTo(364.390686, 157.898193); |
| 2244 | path.quadTo(375.281769, 136.674606, 396.039917, 136.674606); |
| 2245 | path.lineTo(350, 120); |
| 2246 | path.lineTo(366.608826, 151.196014); |
| 2247 | path.close(); |
| 2248 | </div> |
| 2249 | |
| 2250 | <div id="testQuadratic46s"> |
| 2251 | path.moveTo(369.285553, 126.984779); |
| 2252 | path.lineTo(393.291473,102.232819); |
| 2253 | path.lineTo(382.416199,131.740402); |
| 2254 | path.lineTo(396.039917,136.674606); |
| 2255 | path.quadTo(387.290802,136.674606, 380.294495,140.44487); |
| 2256 | path.quadTo(379.623352,140.760971, 378.965302,141.103577); |
| 2257 | path.lineTo(378.917297,141.233856); |
| 2258 | path.quadTo(378.86972,141.206131, 378.822021,141.178574); |
| 2259 | path.quadTo(372.011871,144.761871, 366.608826,151.196014); |
| 2260 | path.lineTo(350,120); |
| 2261 | path.lineTo(369.285553,126.984779); |
| 2262 | path.close(); |
| 2263 | path.moveTo(374.00174, 154.571106); |
| 2264 | path.lineTo(378.917297,141.233871); |
| 2265 | path.quadTo(378.917297,141.233871, 378.917297,141.233856); |
| 2266 | path.quadTo(384.294891,144.368011, 388.322723,149.613556); |
| 2267 | path.lineTo(374.00174,154.571106); |
| 2268 | path.close(); |
| 2269 | path.moveTo(378.917297, 141.233871); |
| 2270 | path.quadTo(370.233887,146.511475, 364.390686,157.898193); |
| 2271 | path.lineTo(374.00174,154.571106); |
| 2272 | path.lineTo(354.009216,208.816208); |
| 2273 | path.lineTo(398.164948,136.674606); |
| 2274 | path.quadTo(388.299255,136.674606, 380.294495,140.44487); |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2275 | </div> |
| 2276 | |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2277 | </div> |
| 2278 | |
| 2279 | <script type="text/javascript"> |
| 2280 | |
| 2281 | var testDivs = [ |
caryclark@google.com | a461ff0 | 2012-10-11 12:54:23 +0000 | [diff] [blame^] | 2282 | testQuadratic46o, |
| 2283 | testQuadratic46s, |
| 2284 | testQuadratic45o, |
| 2285 | testQuadratic45s, |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2286 | testQuadratic44o, |
| 2287 | testQuadratic44s, |
| 2288 | testQuadratic43o, |
| 2289 | testQuadratic43s, |
| 2290 | testQuadratic42o, |
| 2291 | testQuadratic42s, |
| 2292 | testQuadratic41o, |
| 2293 | testQuadratic41s, |
| 2294 | testQuadratic40xb, |
| 2295 | testQuadratic40xa, |
| 2296 | testQuadratic40x, |
caryclark@google.com | d168874 | 2012-09-18 20:08:37 +0000 | [diff] [blame] | 2297 | testQuadratic39, |
| 2298 | testQuadratic39a, |
| 2299 | testQuadratic38, |
| 2300 | testQuadratic37, |
| 2301 | testQuadratic36, |
| 2302 | testQuadratic35, |
| 2303 | testQuadratic34, |
| 2304 | testQuadratic33, |
| 2305 | testQuadratic32, |
| 2306 | testQuadratic31, |
| 2307 | testQuadratic30, |
| 2308 | testQuadratic29, |
caryclark@google.com | 235f56a | 2012-09-14 14:19:30 +0000 | [diff] [blame] | 2309 | testQuadratic28, |
| 2310 | testQuadratic27, |
| 2311 | testQuadratic26, |
| 2312 | testQuadratic25, |
| 2313 | testQuadratic24, |
| 2314 | testQuadratic23, |
| 2315 | testQuadratic22, |
| 2316 | testQuadratic21, |
caryclark@google.com | 32546db | 2012-08-31 20:55:07 +0000 | [diff] [blame] | 2317 | testQuadratic20, |
caryclark@google.com | a7e483d | 2012-08-28 20:44:43 +0000 | [diff] [blame] | 2318 | testQuadratic19, |
caryclark@google.com | 3350c3c | 2012-08-24 15:24:36 +0000 | [diff] [blame] | 2319 | testQuadratic18, |
| 2320 | testQuadratic17x, |
| 2321 | testQuadratic16b, |
| 2322 | testQuadratic16a, |
| 2323 | testQuadratic15, |
caryclark@google.com | c899ad9 | 2012-08-23 15:24:42 +0000 | [diff] [blame] | 2324 | testQuadratic14, |
| 2325 | testQuadratic13b, |
| 2326 | testQuadratic13a, |
| 2327 | testQuadratic12, |
| 2328 | testQuadratic11b, |
| 2329 | testQuadratic11a, |
| 2330 | testQuadratic10b, |
| 2331 | testQuadratic10a, |
| 2332 | testQuadratic9a, |
| 2333 | testQuadratic9, |
| 2334 | testQuadratic8, |
| 2335 | testQuadratic7, |
| 2336 | testQuadratic6, |
| 2337 | testQuadratic5, |
| 2338 | testQuadratic4x, |
caryclark@google.com | 03f9706 | 2012-08-21 13:13:52 +0000 | [diff] [blame] | 2339 | testQuadratic3, |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 2340 | testQuadratic2, |
| 2341 | testQuadratic1, |
| 2342 | testLine4x, |
| 2343 | testLine3x, |
| 2344 | testLine2x, |
| 2345 | testLine1x, |
| 2346 | testQuadralateral9, |
| 2347 | testQuadralateral8, |
| 2348 | testQuadralateral7, |
| 2349 | testFauxQuadralateral6d, |
| 2350 | testFauxQuadralateral6c, |
| 2351 | testFauxQuadralateral6b, |
| 2352 | testFauxQuadralateral6a, |
| 2353 | testFauxQuadralateral6, |
| 2354 | testQuadralateral6a, |
caryclark@google.com | 59823f7 | 2012-08-09 18:17:47 +0000 | [diff] [blame] | 2355 | testQuadralateral6, |
| 2356 | testQuadralateral5, |
| 2357 | testNondegenerate4, |
| 2358 | testNondegenerate3, |
| 2359 | testNondegenerate2, |
| 2360 | testNondegenerate1, |
| 2361 | testDegenerate4, |
| 2362 | testDegenerate3, |
| 2363 | testDegenerate2, |
| 2364 | testDegenerate1, |
caryclark@google.com | 2ddff93 | 2012-08-07 21:25:27 +0000 | [diff] [blame] | 2365 | testLine79, |
| 2366 | testLine78, |
| 2367 | testLine77, |
| 2368 | testLine76, |
| 2369 | testLine75, |
caryclark@google.com | 0c803d0 | 2012-08-06 11:15:47 +0000 | [diff] [blame] | 2370 | testLine74, |
caryclark@google.com | 200c211 | 2012-08-03 15:05:04 +0000 | [diff] [blame] | 2371 | testLine73, |
| 2372 | testLine72, |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2373 | testLine71, |
| 2374 | testLine70, |
| 2375 | testLine69, |
| 2376 | testLine68f, |
| 2377 | testLine68e, |
| 2378 | testLine68d, |
| 2379 | testLine68c, |
| 2380 | testLine68b, |
| 2381 | testLine68a, |
| 2382 | testLine67, |
caryclark@google.com | 27c449a | 2012-07-27 18:26:38 +0000 | [diff] [blame] | 2383 | testLine66, |
| 2384 | testLine65, |
| 2385 | testLine64, |
| 2386 | testLine63, |
| 2387 | testLine62, |
| 2388 | testLine61, |
| 2389 | testLine60, |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 2390 | testLine59, |
| 2391 | testLine58, |
caryclark@google.com | 1806344 | 2012-07-25 12:05:18 +0000 | [diff] [blame] | 2392 | testLine57, |
| 2393 | testLine56, |
caryclark@google.com | e21cb18 | 2012-07-23 21:26:31 +0000 | [diff] [blame] | 2394 | testLine55, |
| 2395 | testLine54, |
| 2396 | testLine53, |
| 2397 | testLine52, |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 2398 | testLine51, |
| 2399 | testLine50, |
| 2400 | testLine49, |
| 2401 | testLine48, |
| 2402 | testLine47, |
| 2403 | testLine46, |
| 2404 | testLine45, |
| 2405 | testLine44, |
| 2406 | testLine43, |
| 2407 | testLine42, |
| 2408 | testLine41, |
| 2409 | testLine40, |
| 2410 | testLine39, |
| 2411 | testLine38, |
| 2412 | testLine37, |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2413 | testLine36, |
caryclark@google.com | 210acaf | 2012-07-12 21:05:13 +0000 | [diff] [blame] | 2414 | testLine35, |
| 2415 | testLine34, |
caryclark@google.com | 9764cc6 | 2012-07-12 19:29:45 +0000 | [diff] [blame] | 2416 | testLine33, |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2417 | testLine32, |
| 2418 | testLine31, |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2419 | testLine30, |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2420 | testLine29, |
| 2421 | testLine28, |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 2422 | testLine24, |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 2423 | testLine22, |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 2424 | testLine19, |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2425 | testLine17, |
caryclark@google.com | e21cb18 | 2012-07-23 21:26:31 +0000 | [diff] [blame] | 2426 | testLine13, |
| 2427 | testLine12, |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 2428 | testLine9, |
caryclark@google.com | cc90505 | 2012-07-25 20:59:42 +0000 | [diff] [blame] | 2429 | testLine7b, |
caryclark@google.com | 4758069 | 2012-07-23 12:14:49 +0000 | [diff] [blame] | 2430 | testLine7, |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 2431 | testSimplifyQuadratic21, |
| 2432 | testSimplifyQuadratic20, |
| 2433 | testSimplifyQuadratic19, |
caryclark@google.com | b45a1b4 | 2012-05-18 20:50:33 +0000 | [diff] [blame] | 2434 | testSimplifyQuadratic18, |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 2435 | testSimplifyQuadratic17, |
| 2436 | testSimplifyQuadratic16, |
| 2437 | testSimplifyQuadratic15, |
| 2438 | testSimplifyQuadratic14, |
| 2439 | testSimplifyQuadratic13, |
| 2440 | testSimplifyQuadratic12, |
| 2441 | testSimplifyQuadratic11, |
| 2442 | testSimplifyQuadratic10, |
| 2443 | testSimplifyQuadratic9, |
| 2444 | testSimplifyQuadratic8, |
| 2445 | testSimplifyQuadratic7, |
| 2446 | testSimplifyQuadratic6, |
| 2447 | testSimplifyQuadratic5, |
| 2448 | testSimplifyQuadratic4, |
| 2449 | testSimplifyQuadratic3, |
| 2450 | testSimplifyQuadratic2, |
| 2451 | testSimplifyQuadratic1, |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2452 | ]; |
| 2453 | |
| 2454 | var scale, columns, rows, xStart, yStart; |
| 2455 | |
| 2456 | var ticks = 0.1; |
| 2457 | var at_x = 13 + 0.5; |
| 2458 | var at_y = 13 + 0.5; |
caryclark@google.com | 2ddff93 | 2012-08-07 21:25:27 +0000 | [diff] [blame] | 2459 | var decimal_places = 0; // make this 3 to show more precision |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2460 | |
| 2461 | var tests = []; |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2462 | var testTitles = []; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2463 | var testIndex = 0; |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 2464 | var hasXor = false; |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2465 | var draw_labels = true; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2466 | |
| 2467 | var ctx; |
| 2468 | |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2469 | function parse(test, title) { |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2470 | var contours = []; |
| 2471 | var contourStrs = test.split("path.close();"); |
caryclark@google.com | d88e089 | 2012-03-27 13:23:51 +0000 | [diff] [blame] | 2472 | var pattern = /-?\d+\.*\d*/g; |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 2473 | hasXor = test.split("kEvenOdd_FillType").length > 1; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2474 | for (var c in contourStrs) { |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2475 | var contour = contourStrs[c]; |
| 2476 | var verbStrs = contour.split("path"); |
| 2477 | var verbs = []; |
| 2478 | for (var v in verbStrs) { |
| 2479 | var verbStr = verbStrs[v]; |
| 2480 | var points = verbStr.match(pattern); |
| 2481 | var pts = []; |
| 2482 | for (var wd in points) { |
| 2483 | var num = parseFloat(points[wd]); |
| 2484 | if (isNaN(num)) continue; |
| 2485 | pts.push(num); |
| 2486 | } |
| 2487 | if (pts.length > 0) |
| 2488 | verbs.push(pts); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2489 | } |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 2490 | if (verbs.length > 0) { |
| 2491 | var lastIndex = verbs.length - 1; |
| 2492 | var lastVerb = verbs[lastIndex]; |
| 2493 | var lastLen = lastVerb.length; |
| 2494 | if (verbs[0][0] != lastVerb[lastLen - 2] && verbs[0][1] != lastVerb[lastLen - 1]) { |
| 2495 | var lastPts = []; |
| 2496 | lastPts.push(verbs[0][0]); |
| 2497 | lastPts.push(verbs[0][1]); |
| 2498 | verbs.push(lastPts); |
| 2499 | } |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2500 | contours.push(verbs); |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 2501 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2502 | } |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2503 | if (contours.length > 0) { |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2504 | tests.push(contours); |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2505 | testTitles.push(title); |
| 2506 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2507 | } |
| 2508 | |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2509 | function parseRect(test, title) { |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2510 | var contours = []; |
| 2511 | var rectStrs = test.split("path.addRect"); |
| 2512 | var pattern = /-?\d+\.*\d*/g; |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 2513 | hasXor = test.split("kEvenOdd_FillType").length > 1; |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2514 | for (var r in rectStrs) { |
| 2515 | var rect = rectStrs[r]; |
| 2516 | var sideStrs = rect.match(pattern); |
| 2517 | var sides = []; |
| 2518 | for (var wd in sideStrs) { |
| 2519 | var num = parseFloat(sideStrs[wd]); |
| 2520 | if (isNaN(num)) continue; |
| 2521 | sides.push(num); |
| 2522 | } |
| 2523 | if (sides.length == 0) |
| 2524 | continue; |
| 2525 | var verbs = []; |
| 2526 | var topLeft = []; |
| 2527 | topLeft.push(sides[0]); topLeft.push(sides[1]); |
| 2528 | var topRight = []; |
| 2529 | topRight.push(sides[2]); topRight.push(sides[1]); |
| 2530 | var botLeft = []; |
| 2531 | botLeft.push(sides[0]); botLeft.push(sides[3]); |
| 2532 | var botRight = []; |
| 2533 | botRight.push(sides[2]); botRight.push(sides[3]); |
| 2534 | verbs.push(topLeft); |
| 2535 | if (sides[4] == 0) { |
| 2536 | verbs.push(topRight); |
| 2537 | verbs.push(botRight); |
| 2538 | verbs.push(botLeft); |
| 2539 | } else { |
| 2540 | verbs.push(botLeft); |
| 2541 | verbs.push(botRight); |
| 2542 | verbs.push(topRight); |
| 2543 | } |
| 2544 | verbs.push(topLeft); |
| 2545 | contours.push(verbs); |
| 2546 | } |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2547 | if (contours.length > 0) { |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2548 | tests.push(contours); |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2549 | testTitles.push(title); |
| 2550 | } |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2551 | } |
| 2552 | |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2553 | function init(test) { |
| 2554 | var canvas = document.getElementById('canvas'); |
| 2555 | if (!canvas.getContext) return; |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2556 | canvas.width = window.innerWidth - at_x; |
| 2557 | canvas.height = window.innerHeight - at_y; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2558 | ctx = canvas.getContext('2d'); |
| 2559 | var xmin = Infinity; |
| 2560 | var xmax = -Infinity; |
| 2561 | var ymin = Infinity; |
| 2562 | var ymax = -Infinity; |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2563 | for (var contours in test) { |
| 2564 | var contour = test[contours]; |
| 2565 | for (var verbs in contour) { |
| 2566 | var verb = contour[verbs]; |
| 2567 | var last = verb.length; |
caryclark@google.com | b45a1b4 | 2012-05-18 20:50:33 +0000 | [diff] [blame] | 2568 | for (var idx = 0; idx < last; idx += 2) { |
| 2569 | xmin = Math.min(xmin, verb[idx]); |
| 2570 | xmax = Math.max(xmax, verb[idx]); |
| 2571 | ymin = Math.min(ymin, verb[idx + 1]); |
| 2572 | ymax = Math.max(ymax, verb[idx + 1]); |
| 2573 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2574 | } |
| 2575 | } |
| 2576 | var subscale = 1; |
| 2577 | while ((xmax - xmin) * subscale < 0.1 && (ymax - ymin) * subscale < 0.1) { |
| 2578 | subscale *= 10; |
| 2579 | } |
| 2580 | columns = Math.ceil(xmax) - Math.floor(xmin) + 1; |
| 2581 | rows = Math.ceil(ymax) - Math.floor(ymin) + 1; |
| 2582 | xStart = Math.floor(xmin); |
| 2583 | yStart = Math.floor(ymin); |
| 2584 | var hscale = ctx.canvas.width / columns / ticks; |
| 2585 | var vscale = ctx.canvas.height / rows / ticks; |
| 2586 | scale = Math.floor(Math.min(hscale, vscale)) * subscale; |
| 2587 | } |
| 2588 | |
| 2589 | function drawPoint(px, py, xoffset, yoffset, unit) { |
caryclark@google.com | 2ddff93 | 2012-08-07 21:25:27 +0000 | [diff] [blame] | 2590 | var label = px.toFixed(decimal_places) + ", " + py.toFixed(decimal_places); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2591 | var _px = px * unit + xoffset; |
| 2592 | var _py = py * unit + yoffset; |
| 2593 | ctx.beginPath(); |
| 2594 | ctx.arc(_px, _py, 3, 0, Math.PI*2, true); |
| 2595 | ctx.closePath(); |
| 2596 | ctx.fill(); |
| 2597 | ctx.fillText(label, _px + 5, _py); |
| 2598 | } |
| 2599 | |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2600 | function draw(test, title, _at_x, _at_y, scale) { |
| 2601 | ctx.fillStyle = "rgba(0,0,0, 0.1)"; |
| 2602 | ctx.font = "normal 50px Arial"; |
| 2603 | ctx.fillText(title, 50, 50); |
| 2604 | ctx.font = "normal 10px Arial"; |
| 2605 | |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2606 | var unit = scale * ticks; |
| 2607 | ctx.lineWidth = 1; |
| 2608 | var i; |
| 2609 | for (i = 0; i <= rows * ticks; ++i) { |
| 2610 | ctx.strokeStyle = (i % ticks) != 0 ? "rgb(160,160,160)" : "black"; |
| 2611 | ctx.beginPath(); |
| 2612 | ctx.moveTo(_at_x + 0, _at_y + i * scale); |
| 2613 | ctx.lineTo(_at_x + unit * columns, _at_y + i * scale); |
| 2614 | ctx.stroke(); |
| 2615 | } |
| 2616 | for (i = 0; i <= columns * ticks; ++i) { |
| 2617 | ctx.strokeStyle = (i % ticks) != 0 ? "rgb(160,160,160)" : "black"; |
| 2618 | ctx.beginPath(); |
| 2619 | ctx.moveTo(_at_x + i * scale, _at_y + 0); |
| 2620 | ctx.lineTo(_at_x + i * scale, _at_y + unit * rows); |
| 2621 | ctx.stroke(); |
| 2622 | } |
| 2623 | |
| 2624 | var xoffset = xStart * -unit + _at_x; |
| 2625 | var yoffset = yStart * -unit + _at_y; |
| 2626 | |
| 2627 | ctx.fillStyle = "rgb(40,80,60)" |
| 2628 | for (i = 0; i <= columns; i += (1 / ticks)) |
| 2629 | { |
| 2630 | num = (xoffset - _at_x) / -unit + i; |
| 2631 | ctx.fillText(num.toFixed(0), i * unit + _at_y - 5, 10); |
| 2632 | } |
| 2633 | for (i = 0; i <= rows; i += (1 / ticks)) |
| 2634 | { |
| 2635 | num = (yoffset - _at_x) / -unit + i; |
| 2636 | ctx.fillText(num.toFixed(0), 0, i * unit + _at_y + 0); |
| 2637 | } |
caryclark@google.com | 32546db | 2012-08-31 20:55:07 +0000 | [diff] [blame] | 2638 | |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2639 | ctx.strokeStyle = "red"; |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2640 | var contours, verbs, pts; |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 2641 | ctx.beginPath(); |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2642 | for (contours in test) { |
| 2643 | var contour = test[contours]; |
| 2644 | if (contours == 2) ctx.strokeStyle = "blue"; |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2645 | var first = true; |
| 2646 | for (verbs in contour) { |
| 2647 | var verb = contour[verbs]; |
| 2648 | switch (verb.length) { |
| 2649 | case 2: |
| 2650 | if (first) { |
| 2651 | ctx.moveTo(xoffset + verb[0] * unit, yoffset + verb[1] * unit); |
| 2652 | first = false; |
| 2653 | } else |
| 2654 | ctx.lineTo(xoffset + verb[0] * unit, yoffset + verb[1] * unit); |
| 2655 | break; |
| 2656 | case 4: |
| 2657 | ctx.quadraticCurveTo(xoffset + verb[0] * unit, yoffset + verb[1] * unit, |
| 2658 | xoffset + verb[2] * unit, yoffset + verb[3] * unit); |
| 2659 | break; |
| 2660 | case 6: |
| 2661 | ctx.bezierCurveTo(xoffset + verb[0] * unit, yoffset + verb[1] * unit, |
| 2662 | xoffset + verb[2] * unit, yoffset + verb[3] * unit, |
| 2663 | xoffset + verb[4] * unit, yoffset + verb[5] * unit); |
| 2664 | break; |
| 2665 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2666 | } |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 2667 | ctx.closePath(); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2668 | } |
caryclark@google.com | 24bec79 | 2012-08-20 12:43:57 +0000 | [diff] [blame] | 2669 | if (hasXor) { |
| 2670 | ctx.fillType=xor; // how is this done? |
| 2671 | } |
caryclark@google.com | 8dcf114 | 2012-07-02 20:27:02 +0000 | [diff] [blame] | 2672 | ctx.stroke(); |
| 2673 | ctx.fillStyle="rgba(192,192,255, 0.3)"; |
| 2674 | ctx.fill(); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2675 | |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2676 | if (!draw_labels) { |
| 2677 | return; |
| 2678 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2679 | ctx.fillStyle="blue"; |
caryclark@google.com | fb17342 | 2012-04-10 18:28:55 +0000 | [diff] [blame] | 2680 | for (contours in test) { |
| 2681 | var contour = test[contours]; |
| 2682 | for (verbs in contour) { |
| 2683 | var verb = contour[verbs]; |
| 2684 | for (i = 0; i < verb.length; i += 2) { |
| 2685 | x = verb[i]; |
| 2686 | y = verb[i + 1]; |
| 2687 | drawPoint(x, y, xoffset, yoffset, unit); |
| 2688 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2689 | } |
| 2690 | } |
| 2691 | } |
| 2692 | |
| 2693 | var mouseX = Infinity, mouseY; |
| 2694 | |
| 2695 | function calcXY() { |
| 2696 | var e = window.event; |
| 2697 | var tgt = e.target || e.srcElement; |
| 2698 | var left = tgt.offsetLeft; |
| 2699 | var top = tgt.offsetTop; |
| 2700 | var unit = scale * ticks; |
| 2701 | mouseX = (e.clientX - left - Math.ceil(at_x) + 1) / unit + xStart; |
| 2702 | mouseY = (e.clientY - top - Math.ceil(at_y)) / unit + yStart; |
| 2703 | } |
| 2704 | |
| 2705 | function handleMouseOver() { |
| 2706 | calcXY(); |
| 2707 | var num = mouseX.toFixed(3) + ", " + mouseY.toFixed(3); |
| 2708 | ctx.beginPath(); |
| 2709 | ctx.rect(300,100,200,10); |
| 2710 | ctx.fillStyle="white"; |
| 2711 | ctx.fill(); |
| 2712 | ctx.fillStyle="black"; |
| 2713 | ctx.fillText(num, 300, 108); |
| 2714 | } |
| 2715 | |
| 2716 | function handleMouseClick() { |
| 2717 | calcXY(); |
| 2718 | // drawInset(); |
| 2719 | } |
| 2720 | |
| 2721 | function drawTop() { |
| 2722 | init(tests[testIndex]); |
| 2723 | redraw(); |
| 2724 | } |
| 2725 | |
| 2726 | function redraw() { |
| 2727 | ctx.beginPath(); |
| 2728 | ctx.rect(0, 0, ctx.canvas.width, ctx.canvas.height); |
| 2729 | ctx.fillStyle="white"; |
| 2730 | ctx.fill(); |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2731 | draw(tests[testIndex], testTitles[testIndex], at_x, at_y, scale); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2732 | // if (insetScale != scale && mouseX != Infinity) |
| 2733 | // drawInset(); |
| 2734 | } |
| 2735 | |
| 2736 | function doKeyPress(evt) { |
| 2737 | var char = String.fromCharCode(evt.charCode); |
| 2738 | switch (char) { |
| 2739 | case 'N': |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2740 | testIndex += 9; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2741 | case 'n': |
| 2742 | if (++testIndex >= tests.length) |
| 2743 | testIndex = 0; |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 2744 | mouseX = Infinity; |
| 2745 | drawTop(); |
| 2746 | break; |
| 2747 | case 'P': |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2748 | testIndex -= 9; |
caryclark@google.com | fa0588f | 2012-04-26 21:01:06 +0000 | [diff] [blame] | 2749 | case 'p': |
| 2750 | if (--testIndex < 0) |
| 2751 | testIndex = tests.length - 1; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2752 | mouseX = Infinity; |
| 2753 | drawTop(); |
| 2754 | break; |
| 2755 | case 'T': |
| 2756 | case 't': |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2757 | break; |
| 2758 | case '-': |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2759 | drawTop(); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2760 | break; |
| 2761 | case '=': |
| 2762 | case '+': |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2763 | drawTop(); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2764 | break; |
caryclark@google.com | 6aea33f | 2012-10-09 14:11:58 +0000 | [diff] [blame] | 2765 | case 'x': |
| 2766 | draw_labels ^= true; |
| 2767 | drawTop(); |
| 2768 | break; |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2769 | } |
| 2770 | } |
| 2771 | |
| 2772 | function start() { |
| 2773 | for (i = 0; i < testDivs.length; ++i) { |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2774 | var title = testDivs[i].id.toString(); |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2775 | var str = testDivs[i].firstChild.data; |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2776 | if (str.split("addRect").length > 1) { |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2777 | parseRect(str, title); |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2778 | } else { |
caryclark@google.com | 0e08a19 | 2012-07-13 21:07:52 +0000 | [diff] [blame] | 2779 | parse(str, title); |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2780 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2781 | } |
| 2782 | drawTop(); |
| 2783 | window.addEventListener('keypress', doKeyPress, true); |
caryclark@google.com | 534aa5b | 2012-08-02 20:08:21 +0000 | [diff] [blame] | 2784 | window.onresize = function() { |
| 2785 | drawTop(); |
| 2786 | } |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2787 | } |
| 2788 | |
| 2789 | </script> |
| 2790 | </head> |
| 2791 | |
| 2792 | <body onLoad="start();"> |
caryclark@google.com | fa4a6e9 | 2012-07-11 17:52:32 +0000 | [diff] [blame] | 2793 | <canvas id="canvas" width="750" height="500" |
caryclark@google.com | 752b60e | 2012-03-22 21:11:17 +0000 | [diff] [blame] | 2794 | onmousemove="handleMouseOver()" |
| 2795 | onclick="handleMouseClick()" |
| 2796 | ></canvas > |
| 2797 | </body> |
| 2798 | </html> |