Do you want to just flip the image horizontally or vertically, or do real-time sprite rotation? The latter would be difficult, but flipping is relatively easy. You could just make a new surface with the correct dimensions AFTER flipping and move the pixels one-by-one. You could also do this with real-time sprite rotation, but it would be painfully slow and you'd have to do a lot of trial-and-error to get it to work with diagonal angles.