@@ -27,4 +27,46 @@ class ImageData extends js.Object {
27
27
28
28
/** Is an unsigned long representing the actual height, in pixels, of the ImageData. */
29
29
def height : Int = js.native
30
+ /**
31
+ * Create an ImageData instance from an array of pixel data and a width.
32
+ * @param data pixel data
33
+ * @param width width in pixels
34
+ */
35
+ def this (data : js.typedarray.Uint8ClampedArray , width : Int ) = this ()
36
+
37
+ /**
38
+ * Create an ImageData instance from an array of pixel data, width, and height.
39
+ * @param data pixel data
40
+ * @param width width in pixels
41
+ * @param height height in pixels
42
+ */
43
+ def this (data : js.typedarray.Uint8ClampedArray , width : Int , height : Int ) = this ()
44
+
45
+ /**
46
+ * Create a blank ImageData instance from specified width and height.
47
+ *
48
+ * @param width width in pixels
49
+ * @param height height in pixels
50
+ */
51
+ def this (width : Int , height : Int ) = this ()
52
+
53
+ /**
54
+ * Create a blank ImageData instance from specified width, height, and settings object.
55
+ *
56
+ * @param width width in pixels
57
+ * @param height height in pixels
58
+ * @param settings image settings
59
+ */
60
+ def this (width : Int , height : Int , setings : js.Object ) = this ()
61
+
62
+ /**
63
+ * Create a blank ImageData instance from specified pixel data, width, height, and settings object.
64
+ *
65
+ * @param data pixel data
66
+ * @param width width in pixels
67
+ * @param height height in pixels
68
+ * @param settings image settings
69
+ */
70
+ def this (data : js.typedarray.Uint8ClampedArray , width : Int , height : Int , setings : js.Object ) = this ()
71
+
30
72
}
0 commit comments