[SDL] moving screen when u change resolution

Michael Wyrzykowski wyrzy at juno.com
Sat Jan 29 17:57:09 PST 2005

Relating to what the first poster had mentioned about: 

> the thing is i cant seem to update either of the following
> putenv( "SDL_VIDEO_CENTERED=1" );
> putenv( "SDL_VIDEO_WINDOW_POS=100,100" );

I used to be using VC++, but I couldn't find a way around getting the window to center, so I switched to using MinGW for Windows. All I do is set 'putenv("SDL_VIDEO_CENTERED=1");' at the beginning of my program and when I change resolutions, the window auto-centers.

My game also uses OpenGL (so I need to reload all the textures), but I don't need to call SDL_Quit to make the window recenter. What platform are you running and which compiler? 

Speed up your surfing with Juno SpeedBand.
Now includes pop-up blocker!
Only $14.95/month -visit http://www.juno.com/surf to sign up today!

More information about the SDL mailing list