Hello,

I am using PDFBox and noticed that the color conversions were not always
accurate for CMYK PDFs. I tested some examples and it seems like the
default color profile used here
<https://github.com/apache/pdfbox/blob/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDDeviceCMYK.java#L100>
by
PDFBox is not a very close match to *U.S. Web Coated (SWOP) v2 *(which
can't be used directly for licensing reasons as per the in-code comment).

I have found that the icc profile here
<https://github.com/saucecontrol/Compact-ICC-Profiles#cmyk> under creative
commons CC0 license is much closer visually to *U.S. Web Coated (SWOP) v2*.
WDYT about changing the deviceCMYK color profile? Or making it configurable
at runtime?

Here are a few examples that show the difference between these color
profiles for page 2 of this
<https://www.berwicktoyota.com.au/images/showroom/hiace-ebrochure.pdf> file
(sorry I can't attach this PDF to the email due to 1MB size restrictions).
The only change I made is the color profile referenced here
<https://github.com/apache/pdfbox/blob/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDDeviceCMYK.java#L100>
.
With U.S. Web Coated (SWOP) v2 - as opened in Acrobat:
[image: acrobat_screenshot_346x243.png]
With ISOcoated_v2_300_bas.icc (used by PDFBox currently), screenshot taken
from pdfbox debugger:
[image: ISO_Coated_screenshot_from_pdfbox_debugger_1_346x243.png]
With CGATS001Compat-v2-micro.icc (proposed change), screenshot taken from
pdfbox debugger:
[image: CGATS001_screenshot_from_pdfbox_debugger_1_346x243.png]

Cheers,
Etienne.

-- 
**
** <https://www.canva.com/>Empowering the world to design
We're hiring, 
apply here <https://www.canva.com/careers/>! Check out the latest news and 
learnings from our team on the Canva Newsroom 
<https://www.canva.com/newsroom/news/>.
 <https://twitter.com/canva> 
<https://facebook.com/canva> <https://au.linkedin.com/company/canva> 
<https://twitter.com/canva>  <https://facebook.com/canva>  
<https://www.linkedin.com/company/canva> 
 <https://instagram.com/canva>



Reply via email to