Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Functions
image_to_bitmap_does_not_preserve_genid.cpp File Reference
#include "tools/fiddle/examples.h"

Go to the source code of this file.

Functions

 REG_FIDDLE (image_to_bitmap_does_not_preserve_genid, 128, 128, true, 5)
 

Function Documentation

◆ REG_FIDDLE()

REG_FIDDLE ( image_to_bitmap_does_not_preserve_genid  ,
128  ,
128  ,
true  ,
 
)

Definition at line 4 of file image_to_bitmap_does_not_preserve_genid.cpp.

4 {
5// image_to_bitmap_does_not_preserve_genid
6void draw(SkCanvas* canvas) {
7 SkBitmap bm1, bm2;
10 SkDebugf("%u\n%u\n", bm1.getGenerationID(), bm2.getGenerationID());
11}
12} // END FIDDLE
void SK_SPI SkDebugf(const char format[],...) SK_PRINTF_LIKE(1
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
Definition aaclip.cpp:27
uint32_t getGenerationID() const
Definition SkBitmap.cpp:361
bool asLegacyBitmap(SkBitmap *bitmap, LegacyBitmapMode legacyBitmapMode=kRO_LegacyBitmapMode) const
Definition SkImage.cpp:233
@ kRO_LegacyBitmapMode
returned bitmap is read-only and immutable
Definition SkImage.h:826
sk_sp< SkImage > image
Definition examples.cpp:29