Skip to content

Trying to convert image to CMYK and display it - rgbData is not a valid imageData format #1

Open
@iroth

Description

@iroth

I am trying to follow your code example for coverting an image to CMYK.
This part is failing:
var rgbData = cmyk2rgb.transformArray(cmykData, false, true);
ctx.putImageData(rgbData, 0, 0);

where I get an exception for putImageData parameter 1 is not of type ImageData.

I tried to fix the code by putting the result rgbData as the data field of a synthetic imageData object, but all my attempts failed. What am I missing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions