Screen resolution and multi-monitor setups

Got a problem with OpenTTD? Find some help here.

Moderator: OpenTTD Developers

Post Reply
tomkcook
Engineer
Engineer
Posts: 2
Joined: 09 Nov 2020 14:11

Screen resolution and multi-monitor setups

Post by tomkcook »

I have Ubuntu 20.04 running a multi-monitor setup. I have a 4k main screen with a 1080 screen below it and another 1080 screen in portrait to the right of it. To support this, I'm running a virtual desktop of 4920x3240. The top part is all visible, but the bottom left and right corners of the virtual space have odd cut-out shapes around the edges of the smaller screens.

OpenTTD gives me two options for screen resolution: 1920x1080 or 4920x3240. At 1920x1080, the "fullscreen" display appears in the top-left corner of the 4k display. At 4920x3240, it covers all the displays and there are various bits of the fullscreen view that you can't see (because there's no physical screen covering that portion of the virtual workspace).

Is there some way to get OpenTTD to go "fullscreen" on a specific display? I think I can tweak the resolution in the cfg file so that it matches the 4k monitor, but I'd also like to be able to show OpenTTD fullscreen on one of the 1080 displays while showing something else on the 4k display. But I can't find any way to get the "fullscreen" display to be offset within the virtual workspace.

Apologies if anyone's having deja vu reading this - I posted something similar this morning but my brand-new account seems to have got caught up in a spam cleanup, hence the re-post.
User avatar
jfs
Tycoon
Tycoon
Posts: 1251
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: Screen resolution and multi-monitor setups

Post by jfs »

I doubt it, you'd have to look to SDL for this. Perhaps SDL has a way of configuring it via a file or environment, though I doubt it.
OpenTTD just asks SDL for available fullscreen modes and presents them, as far as I remember.
tomkcook
Engineer
Engineer
Posts: 2
Joined: 09 Nov 2020 14:11

Re: Screen resolution and multi-monitor setups

Post by tomkcook »

Actually, I suspect the problem here is that OpenTTD by default uses X11 on Linux and I'm running the Wayland GNOME compositor. I tried running

Code: Select all

SDL_VIDEODRIVER=wayland openttd
but this results in a black screen (the system is still okay, just OpenTTD ends up with nothing disayed. I can still Alt+Tab to other windows).

Because Xwayland doesn't know about the different monitors, just the overall virtual desktop, neither does OpenTTD.

Any tips for running OpenTTD natively on wayland?
Eddi
Tycoon
Tycoon
Posts: 7532
Joined: 17 Jan 2007 00:14

Re: Screen resolution and multi-monitor setups

Post by Eddi »

again, that is probably a problem with SDL, not with openttd itself.
You might not exactly be interested in Ferion, but if you are, have fun :)
Post Reply

Return to “OpenTTD Problems”

Who is online

Users browsing this forum: No registered users and 7 guests