4REG_FIDDLE(SkPath_quadTo_example_parametric, 512, 512,
false, 0) {
7 return {(
s *
s * p0.
x()) + (2 *
s * t * p1.
x()) + (t * t * p2.
x()),
8 (
s *
s * p0.
y()) + (2 *
s * t * p1.
y()) + (t * t * p2.
y())};
26 paint.setAntiAlias(
true);
28 paint.setStrokeWidth(5);
60 for (
int i = 0;
i <=
N; ++
i) {
static constexpr SkColor SkColorSetARGB(U8CPU a, U8CPU r, U8CPU g, U8CPU b)
REG_FIDDLE(SkPath_quadTo_example_parametric, 512, 512, false, 0)
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
void drawPoint(SkScalar x, SkScalar y, const SkPaint &paint)
void clear(SkColor color)
void drawPath(const SkPath &path, const SkPaint &paint)
void drawString(const char str[], SkScalar x, SkScalar y, const SkFont &font, const SkPaint &paint)
sk_sp< SkTypeface > matchFamilyStyle(const char familyName[], const SkFontStyle &) const
void setColor(SkColor color)
void setAntiAlias(bool aa)
void setStrokeCap(Cap cap)
@ kStroke_Style
set to stroke geometry
void setStrokeWidth(SkScalar width)
SkPath & moveTo(SkScalar x, SkScalar y)
SkPath & lineTo(SkScalar x, SkScalar y)
SkPath & quadTo(SkScalar x1, SkScalar y1, SkScalar x2, SkScalar y2)
sk_sp< SkFontMgr > fontMgr
font
Font Metadata and Metrics.
constexpr float y() const
constexpr float x() const