Flutter Engine
The Flutter Engine
Functions
Point_addto_operator.cpp File Reference
#include "tools/fiddle/examples.h"

Go to the source code of this file.

Functions

 REG_FIDDLE (Point_addto_operator, 256, 128, false, 0)
 

Function Documentation

◆ REG_FIDDLE()

REG_FIDDLE ( Point_addto_operator  ,
256  ,
128  ,
false  ,
 
)

Definition at line 4 of file Point_addto_operator.cpp.

4 {
5void draw(SkCanvas* canvas) {
7 paint.setAntiAlias(true);
8 SkPoint points[] = { { 3, 1 }, { 4, 2 }, { 5, 1 }, { 7, 3 },
9 { 6, 4 }, { 7, 5 }, { 5, 7 },
10 { 4, 6 }, { 3, 7 }, { 1, 5 },
11 { 2, 4 }, { 1, 3 }, { 3, 1 } };
12 canvas->scale(30, 15);
15 points[1] += {1, 1};
16 points[2] += {-1, -1};
17 paint.setColor(SK_ColorRED);
19}
20} // END FIDDLE
static const int points[]
constexpr SkColor SK_ColorRED
Definition: SkColor.h:126
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
Definition: aaclip.cpp:27
void drawPoints(PointMode mode, size_t count, const SkPoint pts[], const SkPaint &paint)
Definition: SkCanvas.cpp:1710
void scale(SkScalar sx, SkScalar sy)
Definition: SkCanvas.cpp:1289
@ kPolygon_PointMode
draw the array of points as a open polygon
Definition: SkCanvas.h:1243
@ kStroke_Style
set to stroke geometry
Definition: SkPaint.h:194
const Paint & paint
Definition: color_source.cc:38
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
Definition: switches.h:259