Fullscreen with GiGi (with SDL)

Programmers discuss here anything related to FreeOrion programming. Primarily for the developers to discuss.

Moderator: Committer

Post Reply
Message
Author
User avatar
StarFire
Space Floater
Posts: 21
Joined: Sat Mar 24, 2007 8:28 am

Fullscreen with GiGi (with SDL)

#1 Post by StarFire »

Hello World,

I am trying to use libgigi on my own project.

The executable can be started with -w for windowed mode. If this option is not set, the program should run in full screen.

The GiGi documentation (and the code supports this), GiGi (with SDL --> SDLGUI) supports only the windowed mode, full screen mode is not possible. How can I circumvent this limitation? How do you do it in FreeOrion? Where can I look in the FreeOrion code?

TIA and best regards Andreas

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Fullscreen with GiGi (with SDL)

#2 Post by Geoff the Medio »

FreeOrion hasn't used SDL for the GUI since around SVN revision 2789, which was nearly a year ago, so you might not be able to find the relevant code in the current SVN version of FreeOrion.

I don't know what settings or function calls or parameters are needed to get GiGi with SDL to start in fullscreen mode. A quick review of FreeOrion SVN 2789 on the web source viewer didn't reveal anything, but if you check out that revision, you could search for "fullscreen" in the code and try to find where the OptionsDB entry for "fullscreen" or "f" are checked and passed to some initialization code, which should lead to where it's actually used to set up the rendering mode.

Sorry I can't be more helpful, but I don't know that much about the internals of how GiGi works or worked.

User avatar
StarFire
Space Floater
Posts: 21
Joined: Sat Mar 24, 2007 8:28 am

Re: Fullscreen with GiGi (with SDL)

#3 Post by StarFire »

Thanks that helped a lot.

Apparently it's simply overwriting the SDL_Init method of GG:SDLGUI as done in HumanClientApp.cpp (in rev 2789)

Thank you and best regards Andreas

Post Reply