3.3.0 update: improved display resolution selection

Started by Crimson Wizard, Sun 30/03/2014 15:22:03

Previous topic - Next topic

Radiant

Testing now...

Scale x2, no side borders. Works as before, it gives 640x480 with the game running 640x400.
Scale x2, side borders. Works as before, it gives 1280x720 with the game running 640x400.
Scale max, no side borders. Ends up running in x4 scale with no borders, as expected.
Spoiler

Built library path: d3d9.dll
Created graphics driver: Direct3D 9
Initializing screen settings
Game native resolution: 320 x 200 (32 bit), letterbox optional, side borders disabled
Initializing gfx filters
Requested gfx filter: max
Chosen gfx resolution: 1280 x 800 (32 bit), game frame: 320 x 200
Applying scaling filter: StdScale4
Switching to graphics mode
Attempt to switch gfx mode to 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Succeeded. Using gfx mode 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Preparing graphics mode screen
[close]
Scale max, side borders. Does exactly the same as above, which is a bit surprising.
Spoiler

Built library path: d3d9.dll
Created graphics driver: Direct3D 9
Initializing screen settings
Game native resolution: 320 x 200 (32 bit), letterbox optional, side borders enabled
Initializing gfx filters
Requested gfx filter: max
Chosen gfx resolution: 1280 x 800 (32 bit), game frame: 320 x 200
Applying scaling filter: StdScale4
Switching to graphics mode
Attempt to switch gfx mode to 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Succeeded. Using gfx mode 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Preparing graphics mode screen
Initializing colour conversion
[close]

Scale max, no side borders, tob/bottom borders. Does the same as above, which is expected.
Spoiler

Init gfx driver
Built library path: d3d9.dll
Created graphics driver: Direct3D 9
Initializing screen settings
Game native resolution: 320 x 200 (32 bit), letterbox forced, side borders disabled
Initializing gfx filters
Requested gfx filter: max
Chosen gfx resolution: 1280 x 800 (32 bit), game frame: 320 x 200
Applying scaling filter: StdScale4
Switching to graphics mode
Attempt to switch gfx mode to 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Succeeded. Using gfx mode 1280 x 800 (32-bit) fullscreen, game frame 320 x 200, gfx filter: StdScale4
Preparing graphics mode screen
[close]

Scale max, side borders, top/bottom borders. Now I'm getting the side borders.
Spoiler

Init gfx driver
Built library path: d3d9.dll
Created graphics driver: Direct3D 9
Initializing screen settings
Game native resolution: 320 x 200 (32 bit), letterbox forced, side borders enabled
Initializing gfx filters
Requested gfx filter: max
Chosen gfx resolution: 1920 x 1080 (32 bit), game frame: 384 x 216
Applying scaling filter: StdScale5
Switching to graphics mode
Attempt to switch gfx mode to 1920 x 1080 (32-bit) fullscreen, game frame 384 x 216, gfx filter: StdScale5
Succeeded. Using gfx mode 1920 x 1080 (32-bit) fullscreen, game frame 384 x 216, gfx filter: StdScale5
Preparing graphics mode screen
Initializing colour conversion
[close]


So everything works fine, the only thing I don't understand is why I'd have to enable top/bottom borders in order to actually see side borders.

Crimson Wizard

Quote from: Radiant on Sun 13/04/2014 19:29:50
So everything works fine, the only thing I don't understand is why I'd have to enable top/bottom borders in order to actually see side borders.
This depends on supported resolutions. Also, as I mentioned in the first post, this feature still implies some restrictions on which resolutions can be used.
It is possible that all resolutions with side borders but without top/bottom borders simply does not match those requirements, while resolutions with both borders do.
Still, we may calculate which resolutions are possible and see if this really works well.

First of all, to run without top/bottom borders, having 320x200 game, we'd have to have gfx mode heights = multiplies of 200. That is:
x1 => something x 200
x2 => something x 400
x3 => something x 600
x4 => something x 800
x5 => something x 1000
etc

Now, it seems maximal supported (by your monitor) height from this list is 800, which is scaling x4. 320x4 = exactly 1280, which means that no side borders needed whatsoever.

But as soon as you enable top/bottom borders, then other heights become available too, such as 1080, which is multiple of 5, so allows scaling x5. 320x5 = 1600, which means that there should be 320 pixels of side borders (160 per side).

Radiant

Oh, I see your point. When I do the last test, I actually get 1920x1080, which means it does have top and bottom borders, they're just small enough that I didn't notice them.

Ok, everything seems in order then with build 1160. Thank you for your time!

Crimson Wizard

Please, don't use 1160 for your game (it's hotfix2 number), I'll make a next version soon (maybe today). Just to use new version number, because it will be difficult to know which build it is exactly if any problem arises.

Radiant


Crimson Wizard

I found another bug :(, occurs in room with vertical scrolling (room drawn over top/bottom borders). Should be easy to fix, but I need to test little more to be sure.

Radiant

Could you give us a full build (including the latest hotfix) so that we can help you test?

Crimson Wizard

Ok, this is kind of "release candidate" for the 3.3.0 update (3.3.0.1162). I was thinking about releasing this already, but extra test will be good too.

http://www.mediafire.com/download/5a67mvl0d63i416/AGS-3.3.0.zip

Stacy Davidson

Just to be clear, this build is strictly about setting the playback resolution, and still only allows a maximum of 1024x768 for the game its self, right?
-Stacy Davidson
Jack Houston and the Necronauts
Warbird Games
www.warbirdgames.com

Crimson Wizard

Quote from: Stacy Davidson on Sun 20/04/2014 16:01:20
Just to be clear, this build is strictly about setting the playback resolution, and still only allows a maximum of 1024x768 for the game its self, right?
Yes; also it's inferior to custom resolutions in the way it handles "playback" resolution too (may be non-optimal).

Radiant

I note the current zip no longer includes msvcm90.dll, msvcr90.dll, or Microsoft.VC90.CRT.manifest; do I no longer need these?

abstauber

Just tested 1162, framerates are equal to 1158 and everything looks fine. The only thing I notice is that it doesn't get higher than 5x nearest neighbor. Even if I select 1920x1200, the window isn't bigger than 1600x1000.

Crimson Wizard

#52
Quote from: abstauber on Tue 22/04/2014 08:07:10
Just tested 1162, framerates are equal to 1158 and everything looks fine. The only thing I notice is that it doesn't get higher than 5x nearest neighbor. Even if I select 1920x1200, the window isn't bigger than 1600x1000.
What is the game resolution? Do you run windowed or fullscreen?

Quote from: Radiant on Mon 21/04/2014 22:06:38
I note the current zip no longer includes msvcm90.dll, msvcr90.dll, or Microsoft.VC90.CRT.manifest; do I no longer need these?
I tested on clean system and found they were not used anyway, AGS required VC redistributable to be installed normal way, so I included it to installer.
If you use zip archive, you can download that from MS site (http://www.microsoft.com/en-us/download/details.aspx?id=26368)

abstauber

you are right that info would have been helpful ;)
320x200x32b
Windowed mode only reaches 1600x1000.
Fullscreen with max NN goes up to 1920x1200 and looks great

Crimson Wizard

Quote from: abstauber on Tue 22/04/2014 10:39:53
Windowed mode only reaches 1600x1000.
Windows usually cannot create a window => desktop size. Since window size = content + borders & title bar, there's a "margin" for maximal size of the windowed mode. So, max scaling could be, like, 5.8 or 5.9, but since only integer scaling is supported, it choses factor 5 as max scaling.

abstauber

Ah okay, thanks for explaining it.

XBMC has a nice workaround for this using a borderless fake fullscreen. But I'm already very happy how this turned out.

Crimson Wizard

There was a rare bug found in latest build. It took me some time to find solution. Here's an updated version.
May someone interested check if that still works well for them?
http://www.mediafire.com/download/5a67mvl0d63i416/AGS-3.3.0.zip

BTW, Radiant, did the latest one work for you? Have you released your new game version?

Radiant

No problems so far. We haven't released yet although we're planning to do that this week.

SMF spam blocked by CleanTalk