Add rotation support.

I added two lines of code. Please check :)