Jump to content

View more

Image of the Day

Working on an auto spawn system. #gamedev #indiedev #screenshotsaturday https://t.co/Mm2kfekz7b
IOTD | Top Screenshots

The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.


Sign up now

Rendering with subpixel accuracy in SDL

4: Adsense

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
1 reply to this topic

#1 jwezorek   Members   

2631
Like
0Likes
Like

Posted 16 January 2012 - 01:52 PM

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?

#2 jwezorek   Members   

2631
Like
0Likes
Like

Posted 17 January 2012 - 01:25 PM

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?




Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.