Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Toggle fullscreen #531

Closed
yvt opened this issue Jan 6, 2017 · 1 comment
Closed

Toggle fullscreen #531

yvt opened this issue Jan 6, 2017 · 1 comment
Assignees
Labels
enhancement request/proposal to add a new feature
Milestone

Comments

@yvt
Copy link
Owner

yvt commented Jan 6, 2017

Most games released recently provide a functionality to switch back and forth between fullscreen mode and window mode anytime. It'd be great to have support for this in OpenSpades.

Possibly related to #417, because opening a browser cannot be done reliably in full screen mode.

SDL 2.0 provides a function named SDL_SetWindowFullscreen, but I'm not sure whether toggling full screen mode is as easy as calling this function. For example, when you're switching to full screen mode, it's possible that the video card doesn't support the current resolution. Unfortunately, SDL's documentation doesn't mention about what happens in this case. Also note that the current code doesn't support a dynamic change of resolution, and doing so would require a massive amount of rewriting.

@yvt yvt added the enhancement request/proposal to add a new feature label Jan 6, 2017
@VelocityRa
Copy link
Collaborator

I'm not sure whether toggling full screen mode is as easy as calling this function. For example, when you're switching to full screen mode, it's possible that the video card doesn't support the current resolution.

If the target resolution isn't supported, it seems like the resolution is restored. This is in SDL_UpdateFullscreenMode, which gets called in SDL_SetWindowFullscreen (basically a wrapper for it).
Still, we won't know for sure untill we try.

Also note that the current code doesn't support a dynamic change of resolution, and doing so would require a massive amount of rewriting.

So, we don't support that. Just support the switching between fullsreen and windowed.

@yvt yvt added this to the 0.1.1 milestone Jan 7, 2017
@yvt yvt self-assigned this Jan 7, 2017
yvt added a commit that referenced this issue Jan 7, 2017
@yvt yvt closed this as completed Jan 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement request/proposal to add a new feature
Projects
None yet
Development

No branches or pull requests

2 participants