Sign in to follow this  
jwezorek

Rendering with subpixel accuracy in SDL

Recommended Posts

jwezorek    2663
I was thinking about using SDL for my next project to ease the pain of supporting multiple platforms. I'm currently using a custom implementation of standard 2D graphics functions, e.g. Blit, written on top of DirectX. This custom API is actually very close to what's in SDL with the exception that it uses floats for coordinates. SDL functions such as SDL_BlitSurface all seem to take SDL_Rects, which are composed of integers. Are there SDL functions that I'm missing that don't have to render to whole pixel locations?

Share this post


Link to post
Share on other sites
jwezorek    2663
After looking into this more, it looks like you can't do this with SDL calls and if you want to render 2D with subpixel accuracy using SDL you'd have to make OpenGL calls directly ... Is this true?

Obvious next question, is there a small thin library that someone has written that sits on top of OpenGl and exposes 2D functionality that supports blitting with subpixel accuracy?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this