PDF output and icc profiles

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
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

PDF output and icc profiles

Post by stefan9 »

Hi all,

i found some posts to this questions but not realy clear with this.

If i convert image with embedded icc profiles into PDF and i open this PDF with Photoshop no profile found/used.
Is there a way of getting a PDF with icc profile included so Photoshop can read/apply it correct?

IM 6.7.6-8 tested

thanks,
stefan
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: PDF output and icc profiles

Post by anthony »

The question is, can photoshop use a profile embeded in an image, embeded in a PDF to begin with?

Unfortunately this is the wrong forum to ask that question!
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by stefan9 »

good point!
as far as i tested with CS3 and CS5.5 it does NOT work.

so anybody has a "workaround" to put an icc profile to a PDF so Photoshop will use it?
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by stefan9 »

if i save a PDF with Illustrator and have include an image with embedded icc profile Photoshop recognized this profile correct!
so it seams to be a IM issue?
indiego
Posts: 75
Joined: 2010-10-16T06:35:10-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by indiego »

Is this question just academic? I can't see a reason to use PDF here instead of a pure graphic format, like JPG or PNG with embedded profile. Where is the benefit?
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by stefan9 »

not a academical question. very practical from my point of view.

advantage of PDF is everyboday has acrobat reader installed for print the final images
with JPEG or TIF you have a lot of differend tools to open and print , even with standard system.
some does not correct use JPEG included sizes other do not handle profiles correct.

PDF output seems to be the best and universal for printing (for me at the moment).

Acrobat Reader also see the included profiles from Illustrator correct and with the Imagemagick created PDF's colors are wrong :(
indiego
Posts: 75
Joined: 2010-10-16T06:35:10-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by indiego »

I agree, PDF is the best format for printing.

Anyhow, I doubt that IM (GhostScript) can do the same as Illustrator. But we will see...
Can you post a link to a test picture and its IM/Illustrator PDF export then?
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by stefan9 »

testphoto with included ProPhoto RGB ICC i grabed from here:
http://photography-on-the.net/forum/sho ... p?t=982758

Portraits looks "brown" / "mucky" if you browser has no colormanagement (e.g. Chrom)

Image

result with Illustrator/Photoshop (simplest PDF setting possible with including profiles):
http://50.30.47.202/test-prophoto-ai.pdf
http://50.30.47.202/test-prophoto-ps.pdf

result with IM 6.7.6-8 Q8 Win7:
http://50.30.47.202/test-prophoto-im.pdf


best,
stefan
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: PDF output and icc profiles

Post by magick »

This command produces reasonable results:
  • convert 5336735385_a06570a8e0_b.jpg -profile AdobeRGB1998.icc -profile sRGB.icc looks-good.png
indiego
Posts: 75
Joined: 2010-10-16T06:35:10-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by indiego »

I checked the test image and the PDF documents for embedded icc profiles.

jpg, AI and PS: ProPhoto RGB
IM: no profile

So it seems, that IM (GhostScript) has stripped of the profile.
A quick search showed, that icc profile support was introduced in GS9.0. Is your version older?
stefan9
Posts: 15
Joined: 2012-02-22T00:56:56-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by stefan9 »

@magick: yes, i agree that i can get good results with IM if i use other output then PDF.

But the problem is PDF output, becouse profiles striped (or not correct included)
indiego
Posts: 75
Joined: 2010-10-16T06:35:10-07:00
Authentication code: 8675308

Re: PDF output and icc profiles

Post by indiego »

Just did a manual check of the PDF in emacs (prior was preflight with Adobe Acrobat).

The icc profile is part of the IM generated PDF. Even the generated thumbnail graphic has embedded it in its stream (graphic and profile in one object). The /ColorSpace of the document is set to /DeviceRGB.

Looks like the AI generated PDF has a separeted(!) icc profile (16 0 obj). The /ColorSpace entry (17 0 obj) points to a /ICCBased entry (15 0 obj), which is linked to the profile (16 0 R).

I have no experience with GhostScript, so I can't say if something goes wrong here or if it is even possible to do this in GS.
Also: as written in the prior mail, you should check your GhostScript version (>9.0). Maybe an update helps here.
Post Reply