import element.*; public class DrawIncrCircle { public static void main(String args[]) { DrawingWindow d = new DrawingWindow(); // draw a circle with these parameters: final double RADIUS = 90.0; final int CENTER_X = 100; final int CENTER_Y = 100; // approximate number of points to draw: final double dTheta = 1.0/RADIUS; // current point information: double theta, x, y; for (theta = 0.0; theta < 2*Math.PI; theta += dTheta) { x = RADIUS*Math.cos(theta)+CENTER_X; y = RADIUS*Math.sin(theta)+CENTER_Y; d.draw(new Pt((int)Math.round(x),(int)Math.round(y))); } } } /* */