Converts an HTMLImageElement to a Canvas with specified dimensions. The image is scaled to fit the target width and height.
The source HTML image element
The target canvas width
The target canvas height
A new Canvas element containing the scaled image
Converts an HTMLImageElement to a Canvas with specified dimensions. The image is scaled to fit the target width and height.