Try / OpenGothic

Reimplementation of Gothic 2 Notr
MIT License
1.14k stars 80 forks source link

Can't set 4K resolution on modern system with Win 11 #299

Open KorychSP opened 2 years ago

KorychSP commented 2 years ago

Got a new PC recently and checked how OpenGothic runs (on 1.0.1583 and 1.0.1527 ) my setup is: RYZEN 9 5950X RTX 3080 12G Windows 11 2 monitor setup (4k TV 120Hz and 1080p 60 Hz) The executable doesn't take into account resolution settings in Gothic.ini or other ini files and I can't change resolution in-game (field is blank) the resolution in game is probably 800x600 FPS is 600+ , but but that doesn't make me happy :)

settings in Gothic.ini: zVidDevice=0 zVidResFullscreenX=3840 zVidResFullscreenY=2160 zVidResFullscreenBPP=32 zStartupWindowed=0

are there any arguments I can specify resolution with? or settings tweak?

on GD3D11 It seems like there is also a similar problem (the current resolution is shown in-game as 1280x720, but I can't change it) looks better than OpenGothic in terms of resolution, but it looks bad too

do you have any suggestion?

KorychSP commented 2 years ago

forgot to mention that I am using latest steam version of the game

Try commented 2 years ago

Hi @KorychSP !

The executable doesn't take into account resolution settings in Gothic.ini or other ini files

Application runs only in native resolution(as reported by OS).

Assuming that your monitor is HiDpi: as far as I know on Windows(and on others systems), if monitor is HiDpi then application has to explicitly declare that it's capable of hi-res rendering. Otherwise windows will emulate 1080p, for this particular application. OpenGothic doesn't do so, since unfortunately I don't have any HiDpi device with windows and can't test it.

ghost commented 1 year ago

v1.0.1705 Win11, laptop with i7 1165g7 and integrated graphics, external 4k monitor (2160p), laptop monitor (1080p) is disabled when external monitor is connected. Within game settings resolution indeed cannot be changed, but game runs in 2160p by default.

KorychSP commented 1 year ago

Correct, with 2-monitor setup the engine takes the primary monitor resolution into account. In your case, when one of the monitors is disabled you get the resolution of an external one.

Well, to fix any issues on the OpenGothic part, it would be nice to have command line arguments to override resolution and specify primary display/graphics card explicitly

hwnde commented 6 months ago

I just hit the same issue. The workaround is pretty simple: right click on exe file -> properties -> compatibility -> change high dpi settings -> set the override high DPI scaling checkbox. The game will start at the correct resolution, the interface will be small though :( Ideally the interface would scale automatically, not sure how hard it would be to implement though.

Try commented 6 months ago

@hwnde

What you after is INTERFACE/scale, that already been implemented as part of https://github.com/Try/OpenGothic/issues/535 For now I'm preferring to be conservative in regard 4k/HiDPI, as only hardware and OS I have to test it is MacOS/M1, nothing with windows/linux.

See also https://github.com/Try/OpenGothic/issues/301 for subject of ui/swapchain scaling