0

Does anyone know of a way to rotate an image horizontally in Java sort of like this?

http://puu.sh/48iLc.png Original

http://puu.sh/48iHN.jpg Rotated

I just got the rotated one from MS Word because I knew they have those type of rotations.

Anyone have an idea?

Bradsta
  • 157
  • 1
  • 12

1 Answers1

2

This is referred to as shear in Java (though I call it skew.)

Use the AffineTransform class to "shear" your image. That will produce the effect you want.

Here's a tutorial on shearing.

William Morrison
  • 10,953
  • 2
  • 31
  • 48