fullscreen on projector, television and retinal displays
Posted: Wed Jan 15, 2014 11:58 pm
Hi all,
Just managed to fix a weird bug that reported in my game "Eggz" and figured the solution might be useful to someone.
The bug was: on really big screens I get, for some reason, a view on a tiny corner of the game. The television I'm testing on reset its resolution to 800x600 but Löve still reported 1920x1080 as a valid resolution and set it successfully. The result is an image that doesn't fit in the screen, which has mysteriously been set to 800x600.
The reason the screen is set to this low resolution seems to be that fullscreen is set to true in love.conf:
Löve creates a default window at 800x600 fullscreen, the television automatically adapts its resolution to compensate. It's not until later that the window.setMode shows up and sets the resolution to 1920x1080 - for some reason by this time it is too late as the windows already exists: the television doesn't reset its resolution a second time and to add insult to injury I'm stuck with an 800x600 resolution after I exit the game.
This problem occurs on large televisions, projectors and retinal displays.
Just managed to fix a weird bug that reported in my game "Eggz" and figured the solution might be useful to someone.
The bug was: on really big screens I get, for some reason, a view on a tiny corner of the game. The television I'm testing on reset its resolution to 800x600 but Löve still reported 1920x1080 as a valid resolution and set it successfully. The result is an image that doesn't fit in the screen, which has mysteriously been set to 800x600.
The reason the screen is set to this low resolution seems to be that fullscreen is set to true in love.conf:
Code: Select all
t.window.fullscreen = true
This problem occurs on large televisions, projectors and retinal displays.