Here is an applet that demonstrates most of the possible variables at play:
This applet (source included) is available here.
Also there are several AlphaComposite
types where it makes a huge difference whether you're rendering images vs shapes. In this applet if "Use Images" is selected then the shapes you see are first rendered in a BufferedImage
, and then those images are rendered together.
That's all. This is a clean, short article -- as much for my benefit as anyone else's.