Advertisement Jump to content
Sign in to follow this  
silverphyre673

Rotation in SDL

This topic is 4902 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm sure this has been covered many times, but great Google has not availed me this time. I am developing a 2D game using SDL, and need to rotate lots of graphics in realtime. Since software rotation is such an expensive operation, I need a way to do it fairly rapidly. Unfortunately, I've learned that SDL doesn't natively provide a way to do this, and doesn't support hardware rendering. The only thing I can think of is to use OpenGL with it and render everything on a textured quad, and use OpenGL's hardware rotation. However, I'm hoping there is a simpler solution, because I don't really want to bring OpenGL into this. Any help is greatly appreciated. Thanks.

Share this post


Link to post
Share on other sites
Advertisement
I fear bringing in OpenGL is one of your few options.
However, this can be a lot simpeler than you may think. glSDL is a backend for SDL that renders your sprites with OpenGL, and version 0.71 also supports rotation and scaling.

Good luck!

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!