Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

unexpected greyscale to RGB behaviour

6 views
Skip to first unread message

J.J. Green

unread,
Mar 19, 2012, 1:20:00 PM3/19/12
to
Hi all,

I have a query about PS colour spaces and their rasterisation.

I have some PS produced by the Generic Mapping Tools, it is
supposed to have a dark grey (50) rectangle in it. Looking
at PS I see

/A /setgray
:
{0.196 A} FS

which I understand is setting the colour to 0.196 = 50/255
before doing the fill. Typically the PS will have other layers
in it and these will be in the RGB colour space.

Now, viewing this file in gv, converting it to png with the
gs device png16m or almost any other way of looking at it,
the rectangle is RGB 65/65/65. There seems to be some kind of
transformation of greyscale value x to RGB which is not the
obvious x -> x/x/x.

Could anyone point me to some resources on how/why/where in gs
this transformation is performed, in particular if it is possible
to coerce gs to use the "obvious" transformation.

There is some background on this issue at

http://gmtrac.soest.hawaii.edu/issues/40

Thanks in advance!

Jim


Chris

unread,
Mar 20, 2012, 5:07:12 AM3/20/12
to
You don't mention what version of Ghostscript you're testing with.

Since 9.00, Ghostscript uses ICC profiles for all colour conversions, the
default profiles match the defaults used by Adobe Acrobat. You can tell
Ghostscript to use other ICC profiles to better suit your workflow - see:
http://www.ghostscript.com/doc/current/Use.htm#ICC_color_parameters

If you are using GS 9.05 you can use -dUseFastColor which, for "device
colors" will force it to use the basic Postscript device color
conversions.

Versions earlier than 9.00 should be using the basic PS conversions
(those are old and unsupported, now).

Chris


0 new messages