Click to See Complete Forum and Search --> : rotating a shape


susancbk
02-17-2005, 10:23 PM
where do I start to rotate a shape (specifically a square)?
What methods are there? What should I use?

I need to apply it to an animation (shapes moving, rotate a little, its moving in another direction), but i first need to figure out how to rotatte.

buntine
02-17-2005, 10:30 PM
You will need to consult the documentation for the Graphics2D class. It has a rotate() method. Here: http://java.sun.com/j2se/1.4.2/docs/api/java/awt/Graphics2D.html

Regards.