5REG_FIDDLE(Bitmap_tryAllocPixels_4, 256, 100,
false, 0) {
11 ~LargePixelRef()
override {
12 delete[] (
char* ) this->
pixels();
19 uint64_t rowBytes =
info.minRowBytes64();
21 char* addr =
new char[size];
22 if (
nullptr == addr) {
29 bitmap->setPixelRef(std::move(pr), 0, 0);
35 LargeAllocator largeAllocator;
40 if (
bitmap.tryAllocPixels(&largeAllocator)) {
41 bitmap.eraseColor(0xff55aa33);
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
@ kOpaque_SkAlphaType
pixel is opaque
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
void drawImage(const SkImage *image, SkScalar left, SkScalar top)
#define REG_FIDDLE(NAME, W, H, TEXT, I)
static SkImageInfo MakeN32(int width, int height, SkAlphaType at)