Well basically I can't find anything on how to rotate an image in SDL. So just if anyone knows of anyway possible to rotate one. If it be sending me a tutorial or if you know how.
But I want it to have no external files i need to include. Like a function someone has already made a small framework for etc.
I'm learning SDL myself, so I don't know to much about it. But when you can isolate every single pixel in a surface, it would be quit easy to calculate it's new position by writing you're own function.
Thanks for that Scipio - But not exactly what I'm looking for as they are talking about using something from SDL_gfx and well. If you look at his code for his rotation its very complex / resource consuming for something so basic. I have a wrapper function in OpenGL somewhere back on another PC of mine. So I think I'll have to go dig that up and use it. I'll post the code for it if you'd like a copy of it.
I know it works perfect as I've used it before but yeah - Have to use some openGL for it.
Nearest neighbor is the cheapest interpolation algorithm, but it's results are usually unacceptable. If you don't mind using it, arbitrary rotation can be cheap. Otherwise...