101#ifdef SK_BUILD_FOR_MAC
105static std::unique_ptr<SkCanvas> make_canvas(
const SkBitmap& bm) {
113 if (
info.isOpaque()) {
120 paint.setAntiAlias(
true);
122 make_canvas(bm)->drawCircle(50, 50, 49,
paint);
125 CGImageRef
image = SkCreateCGImageRefWithColorspace(bm,
nullptr);
128 SkCreateBitmapFromCGImage(&bm2,
image);
132 CGImageRelease(
image);
186 paint.setAntiAlias(
true);
188 paint.setColor(0xFFCCCCCC);
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
@ kOpaque_SkAlphaType
pixel is opaque
@ kPremul_SkAlphaType
pixel components are premultiplied by alpha
@ kBGRA_8888_SkColorType
pixel with 8 bits for blue, green, red, alpha; in 32-bit word
@ kRGB_565_SkColorType
pixel with 5 bits red, 6 bits green, 5 bits blue, in 16-bit word
@ kRGBA_8888_SkColorType
pixel with 8 bits for red, green, blue, alpha; in 32-bit word
#define SkColorSetRGB(r, g, b)
constexpr SkColor SK_ColorBLUE
constexpr SkColor SK_ColorRED
constexpr SkColor SK_ColorGREEN
static void test_image(const sk_sp< SkSpecialImage > &img, skiatest::Reporter *reporter, GrRecordingContext *rContext, bool isGPUBacked)
static void draw_rect_tests(SkCanvas *canvas)
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
static void draw_column(SkCanvas *canvas, int x, int y)
DEF_SIMPLE_GM(aaclip, canvas, 240, 120)
static void draw_square(SkCanvas *canvas, int x, int y)
static void draw_bar(SkCanvas *canvas, int x, int y)
SkString getName() const override
void onDraw(SkCanvas *canvas) override
void doDraw(SkCanvas *canvas, const SkPath &path)
void drawAndClip(SkCanvas *canvas, const SkPath &path, SkScalar dx, SkScalar dy)
SkISize getISize() override
void allocPixels(const SkImageInfo &info, size_t rowBytes)
sk_sp< SkImage > asImage() const
const SkImageInfo & info() const
void eraseColor(SkColor4f) const
void drawRect(const SkRect &rect, const SkPaint &paint)
void clipRect(const SkRect &rect, SkClipOp op, bool doAntiAlias)
void translate(SkScalar dx, SkScalar dy)
void drawPath(const SkPath &path, const SkPaint &paint)
static std::unique_ptr< SkCanvas > MakeRasterDirect(const SkImageInfo &info, void *pixels, size_t rowBytes, const SkSurfaceProps *props=nullptr)
void drawImage(const SkImage *image, SkScalar left, SkScalar top)
SkMatrix & setRotate(SkScalar degrees, SkScalar px, SkScalar py)
void setColor(SkColor color)
void setAntiAlias(bool aa)
@ kStroke_Style
set to stroke geometry
SkPathBuilder & cubicTo(SkPoint pt1, SkPoint pt2, SkPoint pt3)
SkPathBuilder & moveTo(SkPoint pt)
SkPath makeTransform(const SkMatrix &m, SkApplyPerspectiveClip pc=SkApplyPerspectiveClip::kYes) const
sk_sp< const SkImage > image
skia_private::AutoTArray< sk_sp< SkImageFilter > > filters TypedMatrix matrix TypedMatrix matrix SkScalar dx
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
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
static constexpr SkISize Make(int32_t w, int32_t h)
static SkImageInfo Make(int width, int height, SkColorType ct, SkAlphaType at)
static constexpr SkRect MakeXYWH(float x, float y, float w, float h)
static constexpr SkRect MakeWH(float w, float h)