How to disable color conversion in image magick

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
Posts: 1
Joined: 2017-11-04T02:49:54-07:00
Authentication code: 1152

How to disable color conversion in image magick

Post by Anantha » 2017-11-04T02:53:03-07:00

Hi guys i'm using image magick for converting PDF to image! the command im running is

convert.exe -verbose -density 600 +antialias "E:\sample pdf\sample50 B.pdf" -quality 100 "D:\sample50_2.png"

Now the problem i'm having is the color difference color on the PDF is not the same on the generated image , so what is the problem? i think the problem might be because of -dUseCIEColor its the only odd thing. I used "-dNOPSICC" to disable the loading of CIE but it didn't work!!! What do you guys think is the problem!? can you guys help me?

[ghostscript library 9.20] -dSAFER -dBATCH -dNOPAUSE -dMaxBitmap=50000000 -dNOPSICC "-sDEVICE=png16m" -dTextAlphaBits=1 -dGraphicsAlphaBits=1 -interpolate "-r600x600" -dUseCIEColor "-sOutputFile=C:/Users/Krishnan/AppData/Local/Temp/magick-10476W1YyhtVJCpMd%d" "-fC:/Users/Krishnan/AppData/Local/Temp/magick-104767XSvm7MvBazx" "-fC:/Users/Krishnan/AppData/Local/Temp/magick-10476lNv4Czk03v-v"C:/Users/Krishnan/AppData/Local/Temp/magick-10476W1YyhtVJCpMd1 PNG 6614x10394 6614x10394+0+0 8-bit sRGB 593KB 7.438u 0:07.435
E:\sample pdf\sample50 B.pdf PDF 6614x10394 6614x10394+0+0 16-bit sRGB 593KB 6.438u 0:06.447
E:\sample pdf\sample50 B.pdf=>D:\sample50_2.png PDF 6614x10394 6614x10394+0+0 8-bit sRGB 126c 446KB 6.656u 0:07.048

Posts: 9399
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: How to disable color conversion in image magick

Post by snibgo » 2017-11-04T08:43:17-07:00

I suggest you supply a link to an example PDF. Please also say what version IM you use, on what platform (I assume Windows).

Perhaps "-colorspace sRGB" before the PDF will help.
snibgo's IM pages:

User avatar
Posts: 22101
Joined: 2007-07-02T17:14:51-07:00
Location: Sunnyvale, California, USA

Re: How to disable color conversion in image magick

Post by fmw42 » 2017-11-04T09:25:51-07:00

Note that +antialias is not relevant there. If you want higher detail, then you should use a larger density value and then resize to the pixel dimensions you want.

Also -quality values mean something totally different for PNG than for JPG. See ... hp#quality

If using -colorspace sRGB before your PDF does not help. Then you could use profiles for more accurate color conversion.

Post Reply