> JDK1.1, and Java2 both seem to assume that to display any image on an
> 8-bit display, the image data should be mapped or dithered to a standard
> color cube first, then mapped to the screen colors (or it appears this
> way).

This was addressed in Java 2, Standard Edition Release 1.2.  If you set
the environment variable FORCEGRAY and your framebuffer is configured
appropriately, you will not get the dithering on grayscale images.

On the Solaris reference implementation, you will need to also set the
environment variable FORCEDEFVIS and make the default visual be either
a StaticGray or PseudoColor visual, or the visual selection code will
use a 24-bit visual if one is available.  For a StaticGray visual all
256 grays will be used.  For a PseudoColor visual, the code will attempt
to allocate a large number of grays.

On the Win32 implementation, you have to set your graphics card to 8-bit
mode.  If you are running on a card that has already set the color LUT
to a 256-gray ramp (e.g. Dome), then you will get 256 grays.  If you are
not running on such a card, the code will allocate 236 grays (everything
except the bottom 10 and top 10 LUT entries).

Jerry Evans

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to