8751512aaa
This reverts commit 37575bf3ca
.
Change-Id: Ia31abbd4906ddeed406f3da1128bc4d4177abf24
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/201603
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
20 lines
643 B
C++
20 lines
643 B
C++
// Copyright 2019 Google LLC.
|
|
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
|
|
#include "fiddle/examples.h"
|
|
// HASH=2aa939b90d96aff436b145a96305132c
|
|
REG_FIDDLE(Path_022, 256, 256, false, 0) {
|
|
void draw(SkCanvas* canvas) {
|
|
SkPaint paint;
|
|
SkPath path;
|
|
path.addRRect(SkRRect::MakeRectXY({20, 20, 220, 220}, 30, 50));
|
|
SkRRect rrect;
|
|
if (path.isRRect(&rrect)) {
|
|
const SkRect& bounds = rrect.rect();
|
|
paint.setColor(0xFF9FBFFF);
|
|
canvas->drawRect(bounds, paint);
|
|
}
|
|
paint.setColor(0x3f000000);
|
|
canvas->drawPath(path, paint);
|
|
}
|
|
} // END FIDDLE
|