--- title: ImageData.height slug: Web/API/ImageData/height translation_of: Web/API/ImageData/height ---
{{APIRef("Canvas API")}}
只读的 ImageData.height
属性,返回在图像数据对象中的行的数量。
imagedata.height
var imagedata = new ImageData(100, 100); imagedata.height; // 100
Specification | Status | Comment |
---|---|---|
{{SpecName('HTML WHATWG', 'scripting.html#dom-imagedata-height', 'ImageData.height')}} | {{Spec2('HTML WHATWG')}} |