Rotated texture width/height messup

For rotated images the unpacking is working wrong, when image is 90 rotated, getSubimage is confusing width with height, as well as transform.translate was offsetting image to the right.
Merge pull request #2384 from azakhary/patch-1

Rotated texture width/height messup