Flutter Engine
The Flutter Engine
|
#include <SkPixmap.h>
Public Member Functions | |
SkPixmap () | |
SkPixmap (const SkImageInfo &info, const void *addr, size_t rowBytes) | |
void | reset () |
void | reset (const SkImageInfo &info, const void *addr, size_t rowBytes) |
void | setColorSpace (sk_sp< SkColorSpace > colorSpace) |
bool | reset (const SkMask &mask) |
bool | extractSubset (SkPixmap *subset, const SkIRect &area) const |
const SkImageInfo & | info () const |
size_t | rowBytes () const |
const void * | addr () const |
int | width () const |
int | height () const |
SkISize | dimensions () const |
SkColorType | colorType () const |
SkAlphaType | alphaType () const |
SkColorSpace * | colorSpace () const |
sk_sp< SkColorSpace > | refColorSpace () const |
bool | isOpaque () const |
SkIRect | bounds () const |
int | rowBytesAsPixels () const |
int | shiftPerPixel () const |
size_t | computeByteSize () const |
bool | computeIsOpaque () const |
SkColor | getColor (int x, int y) const |
SkColor4f | getColor4f (int x, int y) const |
float | getAlphaf (int x, int y) const |
const void * | addr (int x, int y) const |
const uint8_t * | addr8 () const |
const uint16_t * | addr16 () const |
const uint32_t * | addr32 () const |
const uint64_t * | addr64 () const |
const uint16_t * | addrF16 () const |
const uint8_t * | addr8 (int x, int y) const |
const uint16_t * | addr16 (int x, int y) const |
const uint32_t * | addr32 (int x, int y) const |
const uint64_t * | addr64 (int x, int y) const |
const uint16_t * | addrF16 (int x, int y) const |
void * | writable_addr () const |
void * | writable_addr (int x, int y) const |
uint8_t * | writable_addr8 (int x, int y) const |
uint16_t * | writable_addr16 (int x, int y) const |
uint32_t * | writable_addr32 (int x, int y) const |
uint64_t * | writable_addr64 (int x, int y) const |
uint16_t * | writable_addrF16 (int x, int y) const |
bool | readPixels (const SkImageInfo &dstInfo, void *dstPixels, size_t dstRowBytes) const |
bool | readPixels (const SkImageInfo &dstInfo, void *dstPixels, size_t dstRowBytes, int srcX, int srcY) const |
bool | readPixels (const SkPixmap &dst, int srcX, int srcY) const |
bool | readPixels (const SkPixmap &dst) const |
bool | scalePixels (const SkPixmap &dst, const SkSamplingOptions &) const |
bool | erase (SkColor color, const SkIRect &subset) const |
bool | erase (SkColor color) const |
bool | erase (const SkColor4f &color, const SkIRect *subset=nullptr) const |
SkPixmap provides a utility to pair SkImageInfo with pixels and row bytes. SkPixmap is a low level class which provides convenience functions to access raster destinations. SkCanvas can not draw SkPixmap, nor does SkPixmap provide a direct drawing destination.
Use SkBitmap to draw pixels referenced by SkPixmap; use SkSurface to draw into pixels referenced by SkPixmap.
SkPixmap does not try to manage the lifetime of the pixel memory. Use SkPixelRef to manage pixel memory; SkPixelRef is safe across threads.
Definition at line 40 of file SkPixmap.h.
|
inline |
Creates an empty SkPixmap without pixels, with kUnknown_SkColorType, with kUnknown_SkAlphaType, and with a width and height of zero. Use reset() to associate pixels, SkColorType, SkAlphaType, width, and height after SkPixmap has been created.
Definition at line 50 of file SkPixmap.h.
|
inline |
Creates SkPixmap from info width, height, SkAlphaType, and SkColorType. addr points to pixels, or nullptr. rowBytes should be info.width() times info.bytesPerPixel(), or larger.
No parameter checking is performed; it is up to the caller to ensure that addr and rowBytes agree with info.
The memory lifetime of pixels is managed by the caller. When SkPixmap goes out of scope, addr is unaffected.
SkPixmap may be later modified by reset() to change its size, pixel type, or storage.
info | width, height, SkAlphaType, SkColorType of SkImageInfo |
addr | pointer to pixels allocated by caller; may be nullptr |
rowBytes | size of one row of addr; width times pixel size, or larger |
Definition at line 72 of file SkPixmap.h.
|
inline |
Returns pixel address, the base address corresponding to the pixel origin.
It is up to the SkPixmap creator to ensure that pixel address is a useful value.
Definition at line 153 of file SkPixmap.h.
Returns readable pixel address at (x, y). Returns nullptr if SkPixelRef is nullptr.
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined. Returns nullptr if SkColorType is kUnknown_SkColorType.
Performs a lookup of pixel size; for better performance, call one of: addr8, addr16, addr32, addr64, or addrF16().
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 314 of file SkPixmap.h.
|
inline |
Returns readable base pixel address. Result is addressable as unsigned 16-bit words. Will trigger an assert() if SkColorType is not kRGB_565_SkColorType or kARGB_4444_SkColorType, and is built with SK_DEBUG defined.
One word corresponds to one pixel.
Definition at line 339 of file SkPixmap.h.
Returns readable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined.
Will trigger an assert() if SkColorType is not kRGB_565_SkColorType or kARGB_4444_SkColorType, and is built with SK_DEBUG defined.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 416 of file SkPixmap.h.
|
inline |
Returns readable base pixel address. Result is addressable as unsigned 32-bit words. Will trigger an assert() if SkColorType is not kRGBA_8888_SkColorType or kBGRA_8888_SkColorType, and is built with SK_DEBUG defined.
One word corresponds to one pixel.
Definition at line 352 of file SkPixmap.h.
Returns readable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined.
Will trigger an assert() if SkColorType is not kRGBA_8888_SkColorType or kBGRA_8888_SkColorType, and is built with SK_DEBUG defined.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 434 of file SkPixmap.h.
|
inline |
Returns readable base pixel address. Result is addressable as unsigned 64-bit words. Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
One word corresponds to one pixel.
Definition at line 365 of file SkPixmap.h.
Returns readable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined.
Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 452 of file SkPixmap.h.
|
inline |
Returns readable base pixel address. Result is addressable as unsigned 8-bit bytes. Will trigger an assert() if SkColorType is not kAlpha_8_SkColorType or kGray_8_SkColorType, and is built with SK_DEBUG defined.
One byte corresponds to one pixel.
Definition at line 326 of file SkPixmap.h.
Returns readable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined.
Will trigger an assert() if SkColorType is not kAlpha_8_SkColorType or kGray_8_SkColorType, and is built with SK_DEBUG defined.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 398 of file SkPixmap.h.
|
inline |
Returns readable base pixel address. Result is addressable as unsigned 16-bit words. Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
Each word represents one color component encoded as a half float. Four words correspond to one pixel.
Definition at line 379 of file SkPixmap.h.
Returns readable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined.
Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
Each unsigned 16-bit word represents one color component encoded as a half float. Four words correspond to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 473 of file SkPixmap.h.
|
inline |
Definition at line 175 of file SkPixmap.h.
|
inline |
SkColorSpace * SkPixmap::colorSpace | ( | ) | const |
Returns SkColorSpace, the range of colors, associated with SkImageInfo. The reference count of SkColorSpace is unchanged. The returned SkColorSpace is immutable.
Definition at line 61 of file SkPixmap.cpp.
|
inline |
Definition at line 173 of file SkPixmap.h.
|
inline |
Returns minimum memory required for pixel storage. Does not include unused memory on last row when rowBytesAsPixels() exceeds width(). Returns SIZE_MAX if result does not fit in size_t. Returns zero if height() or width() is 0. Returns height() times rowBytes() if colorType() is kUnknown_SkColorType.
Definition at line 231 of file SkPixmap.h.
bool SkPixmap::computeIsOpaque | ( | ) | const |
Returns true if all pixels are opaque. SkColorType determines how pixels are encoded, and whether pixel describes alpha. Returns true for SkColorType without alpha in each pixel; for other SkColorType, returns true if all pixels have alpha values equivalent to 1.0 or greater.
For SkColorType kRGB_565_SkColorType or kGray_8_SkColorType: always returns true. For SkColorType kAlpha_8_SkColorType, kBGRA_8888_SkColorType, kRGBA_8888_SkColorType: returns true if all pixel alpha values are 255. For SkColorType kARGB_4444_SkColorType: returns true if all pixel alpha values are 15. For kRGBA_F16_SkColorType: returns true if all pixel alpha values are 1.0 or greater.
Returns false for kUnknown_SkColorType.
example: https://fiddle.skia.org/c/@Pixmap_computeIsOpaque
Definition at line 577 of file SkPixmap.cpp.
|
inline |
Writes color to pixels bounded by subset; returns true on success. if subset is nullptr, writes colors pixels inside bounds(). Returns false if colorType() is kUnknown_SkColorType, if subset is not nullptr and does not intersect bounds(), or if subset is nullptr and bounds() is empty.
color | unpremultiplied color to write |
subset | bounding integer SkRect of pixels to write; may be nullptr |
Definition at line 746 of file SkPixmap.cpp.
|
inline |
Writes color to pixels inside bounds(); returns true on success. Returns false if colorType() is kUnknown_SkColorType, or if bounds() is empty.
color | sRGB unpremultiplied color to write |
Definition at line 712 of file SkPixmap.h.
Writes color to pixels bounded by subset; returns true on success. Returns false if colorType() is kUnknown_SkColorType, or if subset does not intersect bounds().
color | sRGB unpremultiplied color to write |
subset | bounding integer SkRect of written pixels |
example: https://fiddle.skia.org/c/@Pixmap_erase
Definition at line 742 of file SkPixmap.cpp.
Sets subset width, height, pixel address to intersection of SkPixmap with area, if intersection is not empty; and return true. Otherwise, leave subset unchanged and return false.
Failing to read the return value generates a compile time warning.
subset | storage for width, height, pixel address of intersection |
area | bounds to intersect with SkPixmap |
Definition at line 65 of file SkPixmap.cpp.
Look up the pixel at (x,y) and return its alpha component, normalized to [0..1]. This is roughly equivalent to SkGetColorA(getColor()), but can be more efficent (and more precise if the pixels store more than 8 bits per component).
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 94 of file SkPixmap.cpp.
Returns pixel at (x, y) as unpremultiplied color. Returns black with alpha if SkColorType is kAlpha_8_SkColorType.
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined; and returns undefined values or may crash if SK_RELEASE is defined. Fails if SkColorType is kUnknown_SkColorType or pixel address is nullptr.
SkColorSpace in SkImageInfo is ignored. Some color precision may be lost in the conversion to unpremultiplied color; original pixel data may have additional precision.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
example: https://fiddle.skia.org/c/@Pixmap_getColor
Definition at line 187 of file SkPixmap.cpp.
Returns pixel at (x, y) as unpremultiplied color as an SkColor4f. Returns black with alpha if SkColorType is kAlpha_8_SkColorType.
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined; and returns undefined values or may crash if SK_RELEASE is defined. Fails if SkColorType is kUnknown_SkColorType or pixel address is nullptr.
SkColorSpace in SkImageInfo is ignored. Some color precision may be lost in the conversion to unpremultiplied color; original pixel data may have additional precision, though this is less likely than for getColor(). Rounding errors may occur if the underlying type has lower precision.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 388 of file SkPixmap.cpp.
|
inline |
Returns pixel row count.
Definition at line 166 of file SkPixmap.h.
|
inline |
Returns width, height, SkAlphaType, SkColorType, and SkColorSpace.
Definition at line 135 of file SkPixmap.h.
|
inline |
Returns true if SkAlphaType is kOpaque_SkAlphaType. Does not check if SkColorType allows alpha, or if any pixel value has transparency.
Definition at line 201 of file SkPixmap.h.
|
inline |
Copies a SkRect of pixels to dstPixels. Copy starts at (0, 0), and does not exceed SkPixmap (width(), height()).
dstInfo specifies width, height, SkColorType, SkAlphaType, and SkColorSpace of destination. dstRowBytes specifics the gap from one destination row to the next. Returns true if pixels are copied. Returns false if dstInfo address equals nullptr, or dstRowBytes is less than dstInfo.minRowBytes().
Pixels are copied only if pixel conversion is possible. If SkPixmap colorType() is kGray_8_SkColorType, or kAlpha_8_SkColorType; dstInfo.colorType() must match. If SkPixmap colorType() is kGray_8_SkColorType, dstInfo.colorSpace() must match. If SkPixmap alphaType() is kOpaque_SkAlphaType, dstInfo.alphaType() must match. If SkPixmap colorSpace() is nullptr, dstInfo.colorSpace() must match. Returns false if pixel conversion is not possible.
Returns false if SkPixmap width() or height() is zero or negative.
dstInfo | destination width, height, SkColorType, SkAlphaType, SkColorSpace |
dstPixels | destination pixel storage |
dstRowBytes | destination row length |
Definition at line 592 of file SkPixmap.h.
bool SkPixmap::readPixels | ( | const SkImageInfo & | dstInfo, |
void * | dstPixels, | ||
size_t | dstRowBytes, | ||
int | srcX, | ||
int | srcY | ||
) | const |
Copies a SkRect of pixels to dstPixels. Copy starts at (srcX, srcY), and does not exceed SkPixmap (width(), height()).
dstInfo specifies width, height, SkColorType, SkAlphaType, and SkColorSpace of destination. dstRowBytes specifics the gap from one destination row to the next. Returns true if pixels are copied. Returns false if dstInfo address equals nullptr, or dstRowBytes is less than dstInfo.minRowBytes().
Pixels are copied only if pixel conversion is possible. If SkPixmap colorType() is kGray_8_SkColorType, or kAlpha_8_SkColorType; dstInfo.colorType() must match. If SkPixmap colorType() is kGray_8_SkColorType, dstInfo.colorSpace() must match. If SkPixmap alphaType() is kOpaque_SkAlphaType, dstInfo.alphaType() must match. If SkPixmap colorSpace() is nullptr, dstInfo.colorSpace() must match. Returns false if pixel conversion is not possible.
srcX and srcY may be negative to copy only top or left of source. Returns false if SkPixmap width() or height() is zero or negative. Returns false if: abs(srcX) >= Pixmap width(), or if abs(srcY) >= Pixmap height().
dstInfo | destination width, height, SkColorType, SkAlphaType, SkColorSpace |
dstPixels | destination pixel storage |
dstRowBytes | destination row length |
srcX | column index whose absolute value is less than width() |
srcY | row index whose absolute value is less than height() |
Definition at line 170 of file SkPixmap.cpp.
|
inline |
Copies pixels inside bounds() to dst. dst specifies width, height, SkColorType, SkAlphaType, and SkColorSpace of destination. Returns true if pixels are copied. Returns false if dst address equals nullptr, or dst.rowBytes() is less than dst SkImageInfo::minRowBytes.
Pixels are copied only if pixel conversion is possible. If SkPixmap colorType() is kGray_8_SkColorType, or kAlpha_8_SkColorType; dst SkColorType must match. If SkPixmap colorType() is kGray_8_SkColorType, dst SkColorSpace must match. If SkPixmap alphaType() is kOpaque_SkAlphaType, dst SkAlphaType must match. If SkPixmap colorSpace() is nullptr, dst SkColorSpace must match. Returns false if pixel conversion is not possible.
Returns false if SkPixmap width() or height() is zero or negative.
dst | SkImageInfo and pixel address to write to |
Definition at line 668 of file SkPixmap.h.
Copies a SkRect of pixels to dst. Copy starts at (srcX, srcY), and does not exceed SkPixmap (width(), height()). dst specifies width, height, SkColorType, SkAlphaType, and SkColorSpace of destination. Returns true if pixels are copied. Returns false if dst address equals nullptr, or dst.rowBytes() is less than dst SkImageInfo::minRowBytes.
Pixels are copied only if pixel conversion is possible. If SkPixmap colorType() is kGray_8_SkColorType, or kAlpha_8_SkColorType; dst.info().colorType must match. If SkPixmap colorType() is kGray_8_SkColorType, dst.info().colorSpace must match. If SkPixmap alphaType() is kOpaque_SkAlphaType, dst.info().alphaType must match. If SkPixmap colorSpace() is nullptr, dst.info().colorSpace must match. Returns false if pixel conversion is not possible.
srcX and srcY may be negative to copy only top or left of source. Returns false SkPixmap width() or height() is zero or negative. Returns false if: abs(srcX) >= Pixmap width(), or if abs(srcY) >= Pixmap height().
dst | SkImageInfo and pixel address to write to |
srcX | column index whose absolute value is less than width() |
srcY | row index whose absolute value is less than height() |
Definition at line 647 of file SkPixmap.h.
sk_sp< SkColorSpace > SkPixmap::refColorSpace | ( | ) | const |
Returns smart pointer to SkColorSpace, the range of colors, associated with SkImageInfo. The smart pointer tracks the number of objects sharing this SkColorSpace reference so the memory is released when the owners destruct.
The returned SkColorSpace is immutable.
Definition at line 63 of file SkPixmap.cpp.
void SkPixmap::reset | ( | ) |
Sets width, height, row bytes to zero; pixel address to nullptr; SkColorType to kUnknown_SkColorType; and SkAlphaType to kUnknown_SkAlphaType.
The prior pixels are unaffected; it is up to the caller to release pixels memory if desired.
example: https://fiddle.skia.org/c/@Pixmap_reset
Definition at line 32 of file SkPixmap.cpp.
void SkPixmap::reset | ( | const SkImageInfo & | info, |
const void * | addr, | ||
size_t | rowBytes | ||
) |
Sets width, height, SkAlphaType, and SkColorType from info. Sets pixel address from addr, which may be nullptr. Sets row bytes from rowBytes, which should be info.width() times info.bytesPerPixel(), or larger.
Does not check addr. Asserts if built with SK_DEBUG defined and if rowBytes is too small to hold one row of pixels.
The memory lifetime pixels are managed by the caller. When SkPixmap goes out of scope, addr is unaffected.
info | width, height, SkAlphaType, SkColorType of SkImageInfo |
addr | pointer to pixels allocated by caller; may be nullptr |
rowBytes | size of one row of addr; width times pixel size, or larger |
example: https://fiddle.skia.org/c/@Pixmap_reset_2
Definition at line 38 of file SkPixmap.cpp.
bool SkPixmap::reset | ( | const SkMask & | mask | ) |
Deprecated.
Definition at line 47 of file SkPixmap.cpp.
|
inline |
Returns row bytes, the interval from one pixel row to the next. Row bytes is at least as large as: width() * info().bytesPerPixel().
Returns zero if colorType() is kUnknown_SkColorType. It is up to the SkBitmap creator to ensure that row bytes is a useful value.
Definition at line 145 of file SkPixmap.h.
|
inline |
Returns number of pixels that fit on row. Should be greater than or equal to width().
Definition at line 214 of file SkPixmap.h.
bool SkPixmap::scalePixels | ( | const SkPixmap & | dst, |
const SkSamplingOptions & | sampling | ||
) | const |
Copies SkBitmap to dst, scaling pixels to fit dst.width() and dst.height(), and converting pixels to match dst.colorType() and dst.alphaType(). Returns true if pixels are copied. Returns false if dst address is nullptr, or dst.rowBytes() is less than dst SkImageInfo::minRowBytes.
Pixels are copied only if pixel conversion is possible. If SkPixmap colorType() is kGray_8_SkColorType, or kAlpha_8_SkColorType; dst SkColorType must match. If SkPixmap colorType() is kGray_8_SkColorType, dst SkColorSpace must match. If SkPixmap alphaType() is kOpaque_SkAlphaType, dst SkAlphaType must match. If SkPixmap colorSpace() is nullptr, dst SkColorSpace must match. Returns false if pixel conversion is not possible.
Returns false if SkBitmap width() or height() is zero or negative.
dst | SkImageInfo and pixel address to write to |
example: https://fiddle.skia.org/c/@Pixmap_scalePixels
Definition at line 29 of file SkPixmapDraw.cpp.
void SkPixmap::setColorSpace | ( | sk_sp< SkColorSpace > | colorSpace | ) |
Changes SkColorSpace in SkImageInfo; preserves width, height, SkAlphaType, and SkColorType in SkImage, and leaves pixel address and row bytes unchanged. SkColorSpace reference count is incremented.
colorSpace | SkColorSpace moved to SkImageInfo |
example: https://fiddle.skia.org/c/@Pixmap_setColorSpace
Definition at line 57 of file SkPixmap.cpp.
|
inline |
Returns bit shift converting row bytes to row pixels. Returns zero for kUnknown_SkColorType.
Definition at line 221 of file SkPixmap.h.
|
inline |
Returns pixel count in each pixel row. Should be equal or less than: rowBytes() / info().bytesPerPixel().
Definition at line 160 of file SkPixmap.h.
|
inline |
Returns writable base pixel address.
Definition at line 483 of file SkPixmap.h.
Returns writable pixel address at (x, y).
Input is not validated: out of bounds values of x or y trigger an assert() if built with SK_DEBUG defined. Returns zero if SkColorType is kUnknown_SkColorType.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 494 of file SkPixmap.h.
Returns writable_addr pixel address at (x, y). Result is addressable as unsigned 16-bit words. Will trigger an assert() if SkColorType is not kRGB_565_SkColorType or kARGB_4444_SkColorType, and is built with SK_DEBUG defined.
One word corresponds to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 522 of file SkPixmap.h.
Returns writable pixel address at (x, y). Result is addressable as unsigned 32-bit words. Will trigger an assert() if SkColorType is not kRGBA_8888_SkColorType or kBGRA_8888_SkColorType, and is built with SK_DEBUG defined.
One word corresponds to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 537 of file SkPixmap.h.
Returns writable pixel address at (x, y). Result is addressable as unsigned 64-bit words. Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
One word corresponds to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 551 of file SkPixmap.h.
Returns writable pixel address at (x, y). Result is addressable as unsigned 8-bit bytes. Will trigger an assert() if SkColorType is not kAlpha_8_SkColorType or kGray_8_SkColorType, and is built with SK_DEBUG defined.
One byte corresponds to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 508 of file SkPixmap.h.
Returns writable pixel address at (x, y). Result is addressable as unsigned 16-bit words. Will trigger an assert() if SkColorType is not kRGBA_F16_SkColorType and is built with SK_DEBUG defined.
Each word represents one color component encoded as a half float. Four words correspond to one pixel.
x | column index, zero or greater, and less than width() |
y | row index, zero or greater, and less than height() |
Definition at line 566 of file SkPixmap.h.