4 {
6
7
8
9
13
16
19 SkScalar positions[] = { 0.0, 0.65, 1.0 };
20
21 for (
int i = 0;
i < 4;
i++) {
24 SkPoint pts[] = { {blockX, blockY}, {blockX + 50, blockY + 100} };
25
28
29 flags = SkGradientShader::Flags::kInterpolateColorsInPremul_Flag;
30 }
31
34
36 }
37
41
46 }
47}
48}
constexpr SkColor SK_ColorBLUE
constexpr SkColor SK_ColorRED
static constexpr SkColor SkColorSetARGB(U8CPU a, U8CPU r, U8CPU g, U8CPU b)
constexpr SkColor SK_ColorBLACK
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
void drawRect(const SkRect &rect, const SkPaint &paint)
static sk_sp< SkShader > MakeLinear(const SkPoint pts[2], const SkColor colors[], const SkScalar pos[], int count, SkTileMode mode, uint32_t flags=0, const SkMatrix *localMatrix=nullptr)
SkMatrix & setRotate(SkScalar degrees, SkScalar px, SkScalar py)
static const SkMatrix & I()
void setStyle(Style style)
void setColor(SkColor color)
@ kStroke_Style
set to stroke geometry
@ kFill_Style
set to fill geometry
FlutterSemanticsFlag flags
PODArray< SkColor > colors
static constexpr SkRect MakeLTRB(float l, float t, float r, float b)