Hi Jean-Sebastien,

Thanks.  I may look into the SDL way to keep cross-platform.
However, I tried the ChangeDisplaySettings way and it works just fine if you
change them back on exit.  Since I'm always running full-screen, this will
work for me.  


Zach

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jean-Sebastien
Guay
Sent: Tuesday, October 31, 2006 09:41
To: osg users
Subject: RE: [osg-users] osgScreenResolution

Hello Zach,

> I searched the archives a bit and found this from Farshid at least:
>
> WIN32
> If you are running on Windows then you could do it manually. Perform 
> the following on startup:

That will work, but it's messy. It changes the *actual* desktop resolution
to some other resolution. The result is that all the user's currently open
windows will be resized if they're bigger than the target resolution. I've
seen this happen for some programs/games and it's pretty annoying to have to
resize all your windows back to the size you want after the program
terminates.

Use SDL. Believe me, it's a much better way of doing this. It will create a
separate screen surface and change resolution, but once the program exits
the user's windows will not have changed. Check out osgSimpleViewerSDL in
the OSG examples to see how it's done. Just remove or add SDL_FULLSCREEN to
the flags in the SDL_SetVideoMode call to see what it looks like in a window
or in full screen mode. Of course, only full screen mode changes your screen
resolution.

J-S
--
______________________________________________________
Jean-Sebastien Guay     [EMAIL PROTECTED]
                        http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to