The example code was reported in PHP, I can convert this to C if required.
Code: Select all
$img=new Imagick();
$img->newImage(700,700,new ImagickPixel('#f0f')); //Calls MagickNewImage(magickwand, 700, 700, color_wand)
$pic=new Imagick('im.jpg'); //This image is in CMYK
$pic->thumbnailImage(500,500);
$img->compositeImage($pic,imagick::COMPOSITE_DEFAULT,100,100);
$img->writeImage("worldMapOutput_cmyk.jpg");
This produces the image:
Where the map has been composited as CMYK, but the background image is in RGB space. This was tested with ImageMagick 6.9.0-7
This can worked around by explicitly converting the image that is going to be composited to the RGB colorspace. I would have expected this to happen automatically.
Source image if required is here:
https://cloud.githubusercontent.com/ass ... db4404.jpg