home *** CD-ROM | disk | FTP | other *** search
- %!
- /findcmykcustomcolor {5 packedarray} def
- /setcustomcolor
- { exch
- [/Separation 3 -1 roll aload pop 5 1 roll /DeviceCMYK 5 1 roll
- [5 1 roll 4 {4 index mul 4 1 roll} /repeat cvx 5 -1 /roll cvx /pop cvx] cvx bind]
- setcolorspace
- setcolor
- } def
- /sharedcustomcolorimagedict 8 dict def
- /customcolorimage
- { gsave 1 setcustomcolor
- currentcolorspace 0 get /DeviceCMYK eq
- {[/Indexed /DeviceCMYK 4095 [4095 /div cvx currentcolor 4 {4 index mul 4 1 roll} /repeat cvx
- 5 -1 /roll cvx /pop cvx] cvx bind] setcolorspace 4095 setcolor
- } if
- sharedcustomcolorimagedict begin
- currentcolorspace 0 get /Indexed eq {[currentcolorspace 2 get 0]} {[1 0]} ifelse false 1
- {/ImageType /MultipleDataSources /Decode /DataSource /ImageMatrix /BitsPerComponent
- /Height /Width} {exch def} forall currentdict end image grestore
- } def
-