Class ImageData


  • @JsType(isNative=true,
            name="ImageData",
            namespace="<global>")
    public final class ImageData
    extends Object
    Represents the underlying pixel data of an area of a <canvas> element.
    Author:
    Andrea "Stock" Stocchero
    • Method Detail

      • getHeight

        @JsProperty
        public int getHeight()
        Returns the actual height, in pixels.
        Returns:
        the actual height, in pixels
      • getWidth

        @JsProperty
        public int getWidth()
        Returns the actual width, in pixels.
        Returns:
        the actual width, in pixels
      • getData

        @JsOverlay
        public ArrayInteger getData()
        Returns the array which is representing a one-dimensional array containing the data in the RGBA order, with integer values between 0 and 255 (inclusive).
        Returns:
        the array which is representing a one-dimensional array containing the data in the RGBA order, with integer values between 0 and 255 (inclusive)