4REG_FIDDLE(Pixmap_writable_addr8, 256, 64,
false, 0) {
6 uint8_t storage[][5] = {{ 0, 0, 64, 0, 0},
7 { 0, 128, 255, 128, 0},
8 {64, 255, 255, 255, 64},
9 { 0, 128, 255, 128, 0},
12 SkPixmap pixmap(imageInfo, storage[0], 5);
14 bitmap.installPixels(pixmap);
15 canvas->
scale(10, 10);
REG_FIDDLE(Pixmap_writable_addr8, 256, 64, false, 0)
@ kPremul_SkAlphaType
pixel components are premultiplied by alpha
@ kGray_8_SkColorType
pixel with grayscale level in 8-bit byte
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
void scale(SkScalar sx, SkScalar sy)
void drawImage(const SkImage *image, SkScalar left, SkScalar top)
uint8_t * writable_addr8(int x, int y) const
static SkImageInfo Make(int width, int height, SkColorType ct, SkAlphaType at)