When I did it before I started using Dx3D I had an if statement that said when the angle was 90, 180, 270 or 360 (0) it would not use the normal method and would do a kind of flip and mirror method which meant less processing and not a dodgy end result. The code that Note gave seems to work well but by the looks of it it doesn't seem to resize the destination to fit the whole rotated image in .