wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes way to rotate without using Graphics2D.rotate() Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "way to rotate without using Graphics2D.rotate()" Watch "way to rotate without using Graphics2D.rotate()" New topic
Author

way to rotate without using Graphics2D.rotate()

Stephen Huey
Ranch Hand

Joined: Jul 15, 2003
Posts: 618
I've had lots of issues with using rotate and then translate to get an image rotated 180 degrees the way I want to. My problem is that I need the image to be generated upside down now, and I'm rotating it Math.PI and then translating it back into place, but I can't get it right (in trying to translate it to the right position, it's rotating a second time or cancelling the first rotation, or something like that).

I'm looking for an alternative way to do this...at the end, I take my BufferedImage and write it out to a JPEG or PNG, and I'm wondering if there's a way at that point to rotate it without using the Graphics2D.rotate() method...? Thanks!
Craig Wood
Ranch Hand

Joined: Jan 14, 2004
Posts: 1535
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: way to rotate without using Graphics2D.rotate()
 
Similar Threads
Rotating a JWindow with multiple JPanels
rotate image java2d
Tiled Layer
Getting image location
Resetting or Undoing AffineTransforms