2022-08-12 17:28:54 +01:00
|
|
|
#import <HTML/HTMLCanvasElement.idl>
|
|
|
|
|
#import <HTML/HTMLImageElement.idl>
|
|
|
|
|
|
2024-04-05 09:11:31 -04:00
|
|
|
typedef (HTMLImageElement or
|
|
|
|
|
// FIXME: We should use HTMLOrSVGImageElement instead of HTMLImageElement
|
|
|
|
|
// FIXME: HTMLVideoElement or
|
|
|
|
|
HTMLCanvasElement
|
|
|
|
|
// FIXME: ImageBitmap
|
|
|
|
|
// FIXME: OffscreenCanvas
|
|
|
|
|
// FIXME: VideoFrame
|
|
|
|
|
) CanvasImageSource;
|
|
|
|
|
|
2022-08-12 17:28:54 +01:00
|
|
|
// https://html.spec.whatwg.org/multipage/canvas.html#canvasdrawimage
|
|
|
|
|
interface mixin CanvasDrawImage {
|
2024-04-05 09:11:31 -04:00
|
|
|
undefined drawImage(CanvasImageSource image, unrestricted double dx, unrestricted double dy);
|
|
|
|
|
undefined drawImage(CanvasImageSource image, unrestricted double dx, unrestricted double dy, unrestricted double dw, unrestricted double dh);
|
|
|
|
|
undefined drawImage(CanvasImageSource image, unrestricted double sx, unrestricted double sy, unrestricted double sw, unrestricted double sh, unrestricted double dx, unrestricted double dy, unrestricted double dw, unrestricted double dh);
|
2022-08-12 17:28:54 +01:00
|
|
|
};
|