>>>>> "HH" == Huang Haitao-G17843 <[EMAIL PROTECTED]> writes:

HH> Should we directly pass in color bit depth instead of number of
HH> colors?  In my application it's actually easier more natural to
HH> just pass in the bit depth than number of colors.


    This isn't quite as flexible, but I don't have strong feelings as
the number of colors is almost certain to be one of 2,4,16,256
(corresponding to 1,2,4,8 bits).

HH> Also, this approach is to reduce color depth after rendering, is
HH> there a way to let the renderer deirectly render SVG into an image
HH> with a specified color depth?

    With Batik no all of the rendering is pretty hard coded to 8bits
per channel of RGB and Alpha.  Even in general this would be extreamly
difficult as there are lots of places where blending takes place which
is just a bear to do in indexed color spaces (gradients, opacity,
filters, ...).

    One suggestion I might make if you really want to keep the number
of colors down is to turn off anti-aliasing (see the section on
rendering hints in the SVG specification).

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to