OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "PathOpsExtendedTest.h" | 8 #include "PathOpsExtendedTest.h" |
9 #include "PathOpsTestCommon.h" | 9 #include "PathOpsTestCommon.h" |
10 #include "SkBitmap.h" | 10 #include "SkBitmap.h" |
(...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 path2.cubicTo(5182.22900390625f, 4948.328125f, 5160, 4992.78662109375f, 5160
, 5040.00048828125f); | 294 path2.cubicTo(5182.22900390625f, 4948.328125f, 5160, 4992.78662109375f, 5160
, 5040.00048828125f); |
295 path2.lineTo(5940, 2790); | 295 path2.lineTo(5940, 2790); |
296 path2.close(); | 296 path2.close(); |
297 | 297 |
298 SkOpBuilder builder; | 298 SkOpBuilder builder; |
299 builder.add(path1, kUnion_SkPathOp); | 299 builder.add(path1, kUnion_SkPathOp); |
300 builder.add(path2, kUnion_SkPathOp); | 300 builder.add(path2, kUnion_SkPathOp); |
301 SkPath result; | 301 SkPath result; |
302 builder.resolve(&result); | 302 builder.resolve(&result); |
303 } | 303 } |
| 304 |
| 305 DEF_TEST(SkOpBuilder618991, reporter) { |
| 306 SkPath path0; |
| 307 path0.moveTo(140, 40); |
| 308 path0.lineTo(200, 210); |
| 309 path0.lineTo(40, 100); |
| 310 path0.lineTo(2.22223e+07f, 2.22222e+14f); |
| 311 path0.lineTo(2.22223e+07f, 2.22222e+14f); |
| 312 |
| 313 SkPath path1; |
| 314 path1.moveTo(160, 60); |
| 315 path1.lineTo(220, 230); |
| 316 path1.lineTo(60, 120); |
| 317 path1.lineTo(2.22223e+07f, 2.22222e+14f); |
| 318 path1.lineTo(2.22223e+07f, 2.22222e+14f); |
| 319 |
| 320 SkOpBuilder builder; |
| 321 builder.add(path0, SkPathOp::kUnion_SkPathOp); |
| 322 builder.add(path1, SkPathOp::kUnion_SkPathOp); |
| 323 builder.resolve(&path0); |
| 324 } |
OLD | NEW |