[Scummvm-devel] PS2 #1 : GUI : Add Game List : must
Max Horn
max at quendi.de
Tue Mar 3 01:40:22 CET 2009
Am 02.03.2009 um 18:32 schrieb sunmax at libero.it:
> Ciao Max!
>
> Thanks for fixing this!
>
>>> You can see that when you are trying to add a new game,
>
>> Aha, finally I see why my fixes from some months ago didn't help
>> you --- you are not using the aspect ratio correction,
>> and the GUI runs in 320x200 mode
>
> I mean, if I am doing something dumb on my side (like: I should
> use a slighter higher y-res and aspect ratio) I am very glad to
> comply! I actually (beside the PAL/NTSC detection I quickly
> modified in the latest PS2 backend) did not have much time to
> spend on the PS2 GUI yet (which was my very first goal ;-)
Well, the launcher can run in virtually any resolution (at least in
theory). What we currently do when starting the launcher is the
following, from base/main.cpp, setupGraphics(OSystem &system)
...
// Set the user specified graphics mode (if any).
system.setGraphicsMode(ConfMan.get("gfx_mode").c_str());
system.initSize(320, 200);
if (ConfMan.hasKey("aspect_ratio"))
system.setFeatureState(OSystem::kFeatureAspectRatioCorrection,
ConfMan.getBool("aspect_ratio"));
if (ConfMan.hasKey("fullscreen"))
system.setFeatureState(OSystem::kFeatureFullscreenMode,
ConfMan.getBool("fullscreen"));
...
So we set the gfx mode to 320x200, and then activate aspect ratio
correction if request. I have it enabled in the config file, and the
SDL backend uses it. Combined that means the SDL backend will use an
actual screen size of 320x240 instead of 320x200; this area is also
available to the GUI. But *games* get a 320x200 buffer, which is
automatically upscaled by the backend.
Two conclusions
1) If you don't have it already, you may wish to add support for
aspect ratio correction to your backend.
2) We should ask ourselves if we should really setup a resolution of
320x200 as default. We could at the very least make it customizable by
backends in a standardized way. I mean, there is no reason why we
couldn't start in 640x480 with 1x scaler instead of 320x200 with 2x
scaler, for example, right? So maybe for the launcher, there should be
an OSystem method "initForLauncher()", which has a default
implementation like the above, but can be overloaded by backends to
set another resolution / scaler as default.
Bye,
Max
More information about the Scummvm-devel
mailing list