Constructor DecodedRasterImage
DecodedRasterImage(int, int, int, byte[], byte[]?)
Initializes a decoded image.
public DecodedRasterImage(int width, int height, int channels, byte[] colorData, byte[]? alphaData)
Parameters
widthintWidth in pixels.
heightintHeight in pixels.
channelsintColour samples per pixel: 1 (gray), 3 (RGB) or 4 (CMYK).
colorDatabyte[]Interleaved colour samples,
channelsbytes per pixel.alphaDatabyte[]One alpha byte per pixel, or null when the image is opaque.
Exceptions
- ArgumentNullException
colorDatais null.- ArgumentOutOfRangeException
A dimension or the channel count is invalid.