diff options
author | Cary Clark <caryclark@google.com> | 2017-12-20 16:52:53 +0000 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-12-20 16:53:05 +0000 |
commit | 16a127fa6000e2715e2d2ad4d0c9110c7fbd4cac (patch) | |
tree | 2e80b97ff3b7aaf7f8d62e00315c326052dda530 /gm | |
parent | d5f447367cd5e775ca8ce6cc49a8414e17b223f2 (diff) |
Revert "long rect dash with guards"
This reverts commit 4ad0c592ce830f17ff07052f20392caa700e9a53.
Reason for revert: test fails in tiled case
Original change's description:
> long rect dash with guards
>
> check dash fix back in with
> guards against changing
> chrome layout test results
>
> original CL: skia-review.googlesource.com/c/skia/+/84862
>
> efficiently dash very large rectangles and very long lines
> Speed up dashing when lines and rects are absurdly large.
>
> Prior to this CL, only horizontal lines were detected.
>
> Also folded in a change to handle dashing of zero length lines.
>
> TBR=egdaniel@google.com
> Bug: skia:7311
> Change-Id: I139b10f676e7ae06ad83aaf2a35d49cf06280a67
> Reviewed-on: https://skia-review.googlesource.com/87760
> Commit-Queue: Cary Clark <caryclark@skia.org>
> Reviewed-by: Cary Clark <caryclark@skia.org>
TBR=egdaniel@google.com,caryclark@skia.org
Change-Id: Ifd35ddf395826a55c72e650470527d01740b6438
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:7311
Reviewed-on: https://skia-review.googlesource.com/87841
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
Diffstat (limited to 'gm')
-rw-r--r-- | gm/strokes.cpp | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/gm/strokes.cpp b/gm/strokes.cpp index df632dc269..ed13d090ff 100644 --- a/gm/strokes.cpp +++ b/gm/strokes.cpp @@ -533,34 +533,3 @@ DEF_SIMPLE_GM(zerolinedash, canvas, 256, 256) { canvas->drawLine(100, 100, 100, 100, paint); } - -#define PDF_IS_FIXED_SO_THIS_DOESNT_BREAK_IT -#ifdef PDF_IS_FIXED_SO_THIS_DOESNT_BREAK_IT -DEF_SIMPLE_GM(longrect_dash, canvas, 250, 250) { - canvas->clear(SK_ColorWHITE); - - SkPaint paint; - paint.setColor(SkColorSetARGB(255, 0, 0, 0)); - paint.setStrokeWidth(5); - paint.setStrokeCap(SkPaint::kRound_Cap); - paint.setStrokeJoin(SkPaint::kBevel_Join); - paint.setStyle(SkPaint::kStroke_Style); - SkScalar dash_pattern[] = {1, 5}; - paint.setPathEffect(SkDashPathEffect::Make(dash_pattern, 2, 0)); - // try all combinations of stretching bounds - for (auto left : { 20.f, -100001.f } ) { - for (auto top : { 20.f, -100001.f } ) { - for (auto right : { 40.f, 100001.f } ) { - for (auto bottom : { 40.f, 100001.f } ) { - canvas->save(); - canvas->clipRect({10, 10, 50, 50}); - canvas->drawRect({left, top, right, bottom}, paint); - canvas->restore(); - canvas->translate(60, 0); - } - } - canvas->translate(-60 * 4, 60); - } - } -} -#endif |