技术标签: canvas drawImage. そしてここに私のコードがあります: Javascript TypeError:无法执行';drawImage';在';CanvasRenderingContext2D'; The CanvasRenderingContext2D method getImageData() of the Canvas 2D API returns an ImageData object representing the underlying pixel data for a specified portion of the canvas.. The HTMLImageElement provided is in the 'broken' state.表明元素在获取过程中被中断了,也即元素可能 没有正确获取 Uncaught TypeError: Failed to execute 'putImageData' on 'CanvasRenderingContext2D': The provided double value is non-finite. In my case I had to modify the Image.toString() method in order to avoid the problem and get it integrated with data urls. Canvas tests - 2d.drawImage.9arg.* The specification permits any canvas image source ( CanvasImageSource ), specifically, a CSSImageValue, an HTMLImageElement, an SVGImageElement, an HTMLVideoElement, an HTMLCanvasElement, an ImageBitmap, or an OffscreenCanvas . Blitz Breaker Blitz Breaker by Boncho Games - linkingin.co Error: Uncaught (in promise) DOMException: Failed to execute ... Uncaught DOMException: Failed to execute 'drawImage' on ... this.show = function(){ g.drawImage(this.img, this.x, this.y); } 我在stackoverflow和其他几个网站上搜索过. Uncaught DOMException: Failed to execute 'toDataURL' on ... pls. 分析:Uncaught DOMException表明未获取dom元素. Probably means canvas unable to perform toDataURL method: Contamination of the canvas can not be output , please forgive my soul translation. 使用wpaint绘图软件时:Uncaught DOMException: Failed to execute 'drawImage' on ... . The canvas is 1920x1080 in size, and then shrunk to fit using CSS (width:100%;). 2d. Uncaught DOMException: Failed to execute 'drawImage' on ... - CSDN drawImage() Non-Standard drawWidgetAsOnScreen() Non-Standard Deprecated drawWindow . from - failed to execute 'drawimage' on 'canvasrenderingcontext2d' the ... 以下のようなerrorをもらってしまいました。.