Rotating a circle around a point?

Title

How about something like this (not tested on iPad)


function setup()
 originx=WIDTH/2 --x position of the point you are rotating about
 originy=HEIGHT/2 --y position of the point you are rotating about
 angle=0 --start angle in radians
 dist=50 -- distance from centre of circle to point
end

function draw()
 circlex=originx+dist*math.sin(angle)
 circley=originy+dist*math.cos(angle)
 ellipse(circlex,circley,10)
 angle=angle+0.01 (increment in radians - the larger the number the faster the rotation
end

Look at the Animation Example Project an look at Paths or Aequences tabs. Should Help

thanks

Is there any smoother animations i can achieve using the rotate method?

For 3D, Pick a point, translate then rotate.