Нарисуйте изображение в холсте HTML
context.drawImage(image, point.x, point.y, width, height)
Himanshu Jangid
context.drawImage(image, point.x, point.y, width, height)
ctx.drawImage(image, x, y) // top left coords
ctx.drawImage(image, x, y, width, height) // scaled
/**
* @function drawImage
* @param {HTMLImageElement} image
* @param {Vector} point
* @param {number} width
* @param {number} height
* draw an image on the canvas
* @memberof Shapes
*/
function drawImage(image: HTMLImageElement, point: Vector, width: number, height: number) {
this.context.drawImage(image, point.x, point.y, width, height)
}