Flutter Engine
The Flutter Engine
skpaint_path_1d_path_effect.cpp
Go to the documentation of this file.
1// Copyright 2020 Google LLC.
2// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
4REG_FIDDLE(skpaint_path_1d_path_effect, 256, 256, false, 0) {
5void draw(SkCanvas* canvas) {
8 path.addOval(SkRect::MakeWH(16.0f, 6.0f));
9 paint.setPathEffect(
11 paint.setAntiAlias(true);
12 canvas->clear(SK_ColorWHITE);
13 canvas->drawCircle(128.0f, 128.0f, 122.0f, paint);
14}
15} // END FIDDLE
constexpr SkColor SK_ColorWHITE
Definition: SkColor.h:122
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
Definition: aaclip.cpp:27
void clear(SkColor color)
Definition: SkCanvas.h:1199
void drawCircle(SkScalar cx, SkScalar cy, SkScalar radius, const SkPaint &paint)
Definition: SkCanvas.cpp:2707
static sk_sp< SkPathEffect > Make(const SkPath &path, SkScalar advance, SkScalar phase, Style)
Definition: SkPath.h:59
const Paint & paint
Definition: color_source.cc:38
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
Definition: switches.h:57
REG_FIDDLE(skpaint_path_1d_path_effect, 256, 256, false, 0)
static constexpr SkRect MakeWH(float w, float h)
Definition: SkRect.h:609