void drawPaint(double x, double y) { Graphics2D gg = (Graphics2D) imgg.create(); gg.translate(x, y); gg.setPaint(paint); gg.fill(brush); gg.dispose(); repaint(new Rectangle((int) (x - 6), (int) (y - 6), 12, 12)); // close your eyes if you're under-age ... win.recalc(); }
public void drawDot(double width, double height, double angle) { Graphics2D gg = (Graphics2D) imgg.create(); gg.setPaint(paint); gg.translate(img.getWidth() / 2, img.getHeight() / 2); gg.rotate(angle); gg.scale(width, height); gg.fill(brush); gg.dispose(); repaint(); win.recalc(); }