You shouldn't be using Antialiased rendering on an Indexed image. Antialiasing requires the ability to choose a color that is N% of the way from the foreground to the background and store that color, but that color may not be in the colormap of an Indexed image.

One could argue that we should have just ignored the AA hint for Indexed images since we may not find the intermediate colors that we need for the effect, but some images may actually have enough of the intermediate colors that we can render a nice effect even just restricting ourselves to the colors available in the colormap. So, we left it in and let the developer choose whether or not it is working well for their situation (which depends on the colormap that they are using).

Since it doesn't seem to be working well with your particular colormap, my suggestion is to not use Antialiasing - or to come up with a better selection of colors in your colormap that provide enough intermediate colors for the AA algorithm to do its job...

                        ...jim

[EMAIL PROTECTED] wrote:
If I draw into an Indexed bitmap, it seems that with antialias on it uses some kind of 
"change color on edges" algorithm. I am writing with one color, but the new 
pixels that antialiasing adds are not always the same color. I need to find a way to turn 
this off, and force it to use the same color.
[Message sent by forum member 'keith198' (keith198)]

http://forums.java.net/jive/thread.jspa?messageID=290418

===========================================================================
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".

===========================================================================
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