[Tex/LaTex] pdfx: CMYK color profile in PDF/A

cmykcolor-profilepdf-apdfx

I am not completely sure whether this is even supposed to work, but reading the documentation of pdfx it is my understanding that while PDF/A by default uses a RGB profile, it is possible to specifically ask for a CMYK profile. The manual says the following (p. 12): "For users who have a specific color profile they wish to use, it is possible to do so by including a \setRGBcolorprofile or \setCMYKcolorprofile command in the .xmpdata file."

I tried the following MWE:

\RequirePackage{filecontents}
 \begin{filecontents*}{\jobname.xmpdata}
 \setCMYKcolorprofile{coated_FOGRA39L_argl.icc}
                     {Coated FOGRA39}
                     {FOGRA39 (ISO Coated v2 300\% (ECI))}
                     {http://www.argyllcms.com/}
        \Title{Title}
        \Author{Author\sep}
        \Language{de-DE}
        \Keywords{keyword1\sep keyword2\sep keyword3}
        \Publisher{Publisher}
      \end{filecontents*}
\documentclass[]{scrbook}

\usepackage[a-3b]{pdfx}

\begin{document}
Test
\end{document}

While this is a valid PDF/A according to Adobe Acrobat – the preflight test does not produce an error – the color profile used is IEC sRGB. And if I actually include CMYK images, it does not pass as proper PDF/A since the color profiles of the PDF and the included image differ.

pdfx simply seems to ignore the color profile set in the .xmpdata file.

Best Answer

You can force the output intent with :

\RequirePackage{filecontents}
 \begin{filecontents*}{\jobname.xmpdata}
 \setCMYKcolorprofile{coated_FOGRA39L_argl.icc}
                     {Coated FOGRA39}
                     {FOGRA39 (ISO Coated v2 300\% (ECI))}
                     {http://www.argyllcms.com/}
        \Title{Title}
        \Author{Author\sep}
        \Language{de-DE}
        \Keywords{keyword1\sep keyword2\sep keyword3}
        \Publisher{Publisher}
      \end{filecontents*}
\documentclass[]{scrbook}

\usepackage[a-3b]{pdfx}

% -- snipp --

\immediate\pdfobj stream attr{/N 4} file{coated_FOGRA39L_argl.icc}
\pdfcatalog{%
/OutputIntents [ <<
/Type /OutputIntent
/S/GTS_PDFA1
/DestOutputProfile \the\pdflastobj\space 0 R
/OutputConditionIdentifier (Coated FOGRA39)
/Info(FOGRA39L)
>> ]
}

% -- snapp -- 

\begin{document}
Test
\end{document}

But preflight will complain, that the output intent isn't RGB

Related Question