I\'m using Java Graphics and I keep getting \"ugly\" circles.
Here\'s what my Java program makes
You can enable anti-aliasing:
Graphics2D g2 = (Graphics2D) g;
Map hints = new HashMap();
hints.put(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
g2.setRenderingHints(hints);
I also suggest you draw to the Graphics object you get from the paintComponent
method rather than creating an intermediate BufferedImage
.