Function: createImageBitmap()
Call Signature
function createImageBitmap(image, options?): Promise<ImageBitmap>;Defined in: types/desktop-engine.d.ts:4947
A bitmap of an image (loaded), a canvas, ImageData, another ImageBitmap or a Blob of an image file (decoded away from the JavaScript thread), as on the web (API 5): all of it, or the rectangle (sx, sy, sw, sh), transparent where it's outside. The promise rejects with an InvalidStateError for an image that hasn't loaded, data that isn't an image or a bitmap larger than 16384 wide or high or than 8192 × 8192 pixels in all, a RangeError for a rectangle of size 0
Parameters
| Parameter | Type |
|---|---|
image | | CanvasDrawable | Blob |
options? | ImageBitmapOptions |
Returns
Promise<ImageBitmap>
Call Signature
function createImageBitmap(
image,
sx,
sy,
sw,
sh,
options?
): Promise<ImageBitmap>;Defined in: types/desktop-engine.d.ts:4948
A bitmap of an image (loaded), a canvas, ImageData, another ImageBitmap or a Blob of an image file (decoded away from the JavaScript thread), as on the web (API 5): all of it, or the rectangle (sx, sy, sw, sh), transparent where it's outside. The promise rejects with an InvalidStateError for an image that hasn't loaded, data that isn't an image or a bitmap larger than 16384 wide or high or than 8192 × 8192 pixels in all, a RangeError for a rectangle of size 0
Parameters
| Parameter | Type |
|---|---|
image | | CanvasDrawable | Blob |
sx | number |
sy | number |
sw | number |
sh | number |
options? | ImageBitmapOptions |
Returns
Promise<ImageBitmap>
