Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


SDL_DisplayFormat Question...

This topic is 5921 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

Hi, I use the SDL_DisplayFormat function on surfaces once they are made and when they are modified (transparent, etc...) because its supposed to speed things up on blitting. I was wondering if this is ok. (NOTE: MySurface is a SDL Surface obvioulsy :-)) 1. MySurface=SDL_DisplayFormat(MySurface); or is it better to 2. SDL_Surface *Temp; Temp=SDL_DisplayFormat(MySurface); MySurface=Temp; SDL_FreeSurface(Temp); Does 1 do the same as number 2? I am wondering this because all I do is init the SDL video and do a basic loop with the SDL_Flip(Surface) at the end of it. And my frame rate is around 76FPS, I was wondering if thats normal, because when I see DirectX Direct Draw or OpenGL on blank screens I see frame rates into the hundreds. Why is SDL not doing that, it is using DirectX5 for the drawing (I checked the video driver after the init)

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!