34 paint.setImageFilter(filter);
45 paint.setColor(0xFFFFFFFF);
57 paint.setColor(0xFFFFFFFF);
154 using INHERITED =
GM;
constexpr SkColor SK_ColorTRANSPARENT
constexpr SkColor SK_ColorGRAY
#define SkScalarRoundToInt(x)
void onOnceBeforeDraw() override
SkISize getISize() override
void onDraw(SkCanvas *canvas) override
sk_sp< SkImageFilter > make(sk_sp< SkPicture > pic, SkRect r, const SkSamplingOptions &sampling)
SkString getName() const override
sk_sp< SkImageFilter > make(const SkSamplingOptions &sampling)
int saveLayer(const SkRect *bounds, const SkPaint *paint)
void drawRect(const SkRect &rect, const SkPaint &paint)
void clipRect(const SkRect &rect, SkClipOp op, bool doAntiAlias)
void translate(SkScalar dx, SkScalar dy)
void drawPaint(const SkPaint &paint)
void clear(SkColor color)
void scale(SkScalar sx, SkScalar sy)
void drawString(const char str[], SkScalar x, SkScalar y, const SkFont &font, const SkPaint &paint)
static sk_sp< SkColorSpace > MakeSRGB()
@ kSubpixelAntiAlias
glyph positioned in pixel using transparency
static sk_sp< SkImageFilter > Image(sk_sp< SkImage > image, const SkRect &srcRect, const SkRect &dstRect, const SkSamplingOptions &sampling)
static sk_sp< SkImageFilter > Picture(sk_sp< SkPicture > pic, const SkRect &targetRect)
@ kStroke_Style
set to stroke geometry
SkCanvas * beginRecording(const SkRect &bounds, sk_sp< SkBBoxHierarchy > bbh)
sk_sp< SkPicture > finishRecordingAsPicture()
virtual SkRect cullRect() const =0
GM(SkColor backgroundColor=SK_ColorWHITE)
SK_API sk_sp< SkImage > DeferredFromPicture(sk_sp< SkPicture > picture, const SkISize &dimensions, const SkMatrix *matrix, const SkPaint *paint, BitDepth bitDepth, sk_sp< SkColorSpace > colorSpace, SkSurfaceProps props)
@ kU8
uses 8-bit unsigned int per color component
Optional< SkRect > bounds
clipRect(r.rect, r.opAA.op(), r.opAA.aa())) template<> void Draw
SkSamplingOptions sampling
font
Font Metadata and Metrics.
SkSamplingOptions(SkFilterMode::kLinear))
static void fill_rect_filtered(SkCanvas *canvas, const SkRect &clipRect, sk_sp< SkImageFilter > filter)
static sk_sp< SkPicture > make_picture()
static sk_sp< SkPicture > make_LCD_picture()
static constexpr SkISize Make(int32_t w, int32_t h)
SkScalar fLeft
smaller x-axis bounds
static constexpr SkRect MakeXYWH(float x, float y, float w, float h)
constexpr float height() const
constexpr float width() const
SkScalar fTop
smaller y-axis bounds