Go to the source code of this file.
◆ REG_FIDDLE()
REG_FIDDLE |
( |
UnpremulGPU |
, |
|
|
256 |
, |
|
|
256 |
, |
|
|
false |
, |
|
|
6 |
|
|
) |
| |
Definition at line 4 of file UnpremulGPU.cpp.
4 {
6 canvas->
clear(0xffa020a0);
10 for (
int y = 0;
y < 10;
y++) {
11 for (
int x = 0;
x < 10;
x++) {
13 }
14 }
16
20 for (
int y = 0;
y < 10;
y++) {
21 for (
int x = 0;
x < 10;
x++) {
23 }
24 }
26
31
34}
35}
@ kPremul_SkAlphaType
pixel components are premultiplied by alpha
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
void allocPixels(const SkImageInfo &info, size_t rowBytes)
sk_sp< SkImage > asImage() const
uint32_t * getAddr32(int x, int y) const
void clear(SkColor color)
void drawCircle(SkScalar cx, SkScalar cy, SkScalar radius, const SkPaint &paint)
sk_sp< SkShader > makeShader(SkTileMode tmx, SkTileMode tmy, const SkSamplingOptions &, const SkMatrix *localMatrix=nullptr) const
SkImageInfo makeAlphaType(SkAlphaType newAlphaType) const
static SkImageInfo MakeS32(int width, int height, SkAlphaType at)