[pdftex] Separation Colors with pdftex
lehmke at jupiter.cs.uni-dortmund.de
lehmke at jupiter.cs.uni-dortmund.de
Fri Apr 19 18:05:43 CEST 2002
Hans Hagen wrote on Thu, 18 Apr 2002 22:49:57 +0200:
>
> At 04:00 PM 4/17/2002 +0200, you wrote:
>
> >\pdfpageattr {/ColorSpace << /Cs42 [ /Separation /Sonderfarbe /DeviceCMYK
> >\pdfrefobj\pdflastobj ]>>}
> >
> >then "\pdfrefobj\pdflastobj" is inserted verbatim into the pdf file.
> >According to the pdftex manual, \pdfrefobj is also unexpandable,
> >so \edef trickery doesn't work either.
>
> you can expand the number with \the\pdflastobj adn use the "x y R" syntax
Thanks, good idea.
> I have no time now to explain the gory details, but you need to build and
> specify the extended graphic state dictionaries (/ExtGState)
Are you certain absence of this resource can lead to errors?
I've experimented some more now, and if I use
--------------------------------------------------------------------------
1 0 obj
<< /Font << /F1 6 0 R >> /ProcSet [ /PDF /Text ] /ColorSpace << /Cs42 [
/Separation /Sonderfarbe /DeviceGray /Identity]>> >>
endobj
4 0 obj <<
/Length 135
>>
stream
1 0 0 1 72 769.887 cm
/Cs42 cs 0.5 scn
1 0 0 1 19.925 -9.963 cm
BT
/F1 9.963 Tf 0 0 Td[(T)83(es)-1(t)]TJ 211.583 -654.744 Td[(1)]TJ
ET
endstream
endobj
3 0 obj <<
/Type /Page
/Contents 4 0 R
/Resources 1 0 R
/MediaBox [0 0 595.273 841.887]
/Parent 7 0 R
>> endobj
--------------------------------------------------------------------------
using the builtin function /Identity as tint transform, then this is
read by acroread and acrobat without error, and displays as expected.
Only CrackerJack doesn't like it: "There was a problem reading
the document". Again, as had to be expected, the manual doesn't
give any hint on how to interpret this error message.
Adding an /ExtGState resource like this:
--------------------------------------------------------------------------
1 0 obj
<< /Type /ExtGState /SA false /SM 0.02 /OP true /op true /OPM 1 /BG2 /Default
/UCR2 /Default /TR2 /Default >>
endobj
2 0 obj
<< /Font << /F1 7 0 R >> /ProcSet [ /PDF /Text ] /ColorSpace << /Cs42 [
/Separation /Sonderfarbe /DeviceGray /Identity]>> /ExtGState << /GS2 1 0 R >> >>
endobj
5 0 obj <<
/Length 143
>>
stream
1 0 0 1 72 769.887 cm
/Cs42 cs /GS2 gs 0.5 scn
1 0 0 1 19.925 -9.963 cm
BT
/F1 9.963 Tf 0 0 Td[(T)83(es)-1(t)]TJ 211.583 -654.744 Td[(1)]TJ
ET
endstream
endobj
4 0 obj <<
/Type /Page
/Contents 5 0 R
/Resources 2 0 R
/MediaBox [0 0 595.273 841.887]
/Parent 8 0 R
>> endobj
--------------------------------------------------------------------------
doesn't change anything :-(
When trying to define a CMYK alternative for my /Separation
color, however, I'm still stuck. I have added some required
attributes to the function declaration:
--------------------------------------------------------------------------
1 0 obj
<< /FunctionType 4 /Domain [0 1] /Range [0 1 0 1 0 1 0 1] /Length 28 >> stream {
pop 0.06 0.00 0.00 0.34 } endstream
endobj
2 0 obj
<< /Type /ExtGState /SA false /SM 0.02 /OP true /op true /OPM 1 /BG2 /Default
/UCR2 /Default /TR2 /Default >>
endobj
3 0 obj
<< /Font << /F1 8 0 R >> /ProcSet [ /PDF /Text ] /ColorSpace << /Cs42 [
/Separation /Sonderfarbe /DeviceCMYK 1 0 R ]>> /ExtGState << /GS2 2 0 R >> >>
endobj
6 0 obj <<
/Length 143
>>
stream
1 0 0 1 72 769.887 cm
/Cs42 cs /GS2 gs 0.5 scn
1 0 0 1 19.925 -9.963 cm
BT
/F1 9.963 Tf 0 0 Td[(T)83(es)-1(t)]TJ 211.583 -654.744 Td[(1)]TJ
ET
endstream
endobj
5 0 obj <<
/Type /Page
/Contents 6 0 R
/Resources 3 0 R
/MediaBox [0 0 595.273 841.887]
/Parent 9 0 R
>> endobj
--------------------------------------------------------------------------
Now I get an error message from acroread: "There was an error processing a
page. Invalid Function resource."
So I'm pretty convinced my function declaration is wrong.
As you see, this example also contains an /ExtGState resource.
No change of behaviour whether it's present or not.
Even if I try to create my own /Identity function:
--------------------------------------------------------------------------
1 0 obj
<< /FunctionType 4 /Domain [0 1] /Range [0 1] /Length 4 >> stream { } endstream
endobj
2 0 obj
<< /Type /ExtGState /SA false /SM 0.02 /OP true /op true /OPM 1 /BG2 /Default
/UCR2 /Default /TR2 /Default >>
endobj
3 0 obj
<< /Font << /F1 8 0 R >> /ProcSet [ /PDF /Text ] /ColorSpace << /Cs42 [
/Separation /Sonderfarbe /DeviceGray 1 0 R ]>> /ExtGState << /GS2 2 0 R >> >>
endobj
--------------------------------------------------------------------------
the error message stays the same. That's as simple as it can
get I guess. I'm really at a loss now...
Do you have a working separable example of a `handcafted'
pdf file, not a several MB monstrosity where functions are flate
compressed sampled ones?
Well. Maybe I'll try function type 0 next...
Then I only have to find out why CrackerJack balks...
regards
Stephan
--
Stephan Lehmke Stephan.Lehmke at cs.uni-dortmund.de
Fachbereich Informatik, LS I Tel. +49 231 755 6434
Universitaet Dortmund FAX 6555
D-44221 Dortmund, Germany
More information about the pdftex
mailing list