本页内容

CanvasPixelArray QML Type

提供对图像数据中每个像素的组成部分进行有序且带索引的访问。更多...

Import Statement: import QtQuick

属性

详细说明

CanvasPixelArray 对象提供对图像数据中每个像素的颜色分量进行有序、基于索引的访问。CanvasPixelArray 可像普通 JavaScript 数组一样进行访问。

另请参阅 CanvasImageData 以及W3C 2D 上下文标准中关于 PixelArray 的内容。

属性文档

length : int

CanvasPixelArray 对象表示一个h×w×4的整数数组,其中w和h取自CanvasImageData 。CanvasPixelArray 对象的length属性必须返回该h×w×4的数值。该属性为只读属性。

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.