How to get larger scaling with minimal new code

General chat related to ScummVM, adventure gaming, and so on.

Moderator: ScummVM Team

Post Reply
mband
Posts: 5
Joined: Thu Jun 08, 2006 5:21 pm

How to get larger scaling with minimal new code

Post by mband »

I've noticed that support for wide screens is currently being planned in <http://sourceforge.net/tracker/index.ph ... tid=418823>.
This will let ScummVM run full-screen in the monitor's native resolution, thereby eliminating the horizontal stretching that currently takes place with wide screens (or vertical stretching for those with 1280x1024 LCD's).

However, in order to accommodate native resolutions for large displays (e.g. 1680x1050 or 1280x1024) without making the play-area too small for 320x200 games, I foresee ScummVM needing some kind of support for larger scalers.

Since the present scaler code is already perceived to be too-bloated, any new scaler support would need to be as simple as possible. I see 2 ways of supporting larger scalers with minimal extra code. We could either:

(1) Add support for cascading scalers. E.g. HQ2X followed by Normal2X to get a 4x scaler.

(2) Support new scalers via a plugin architecture, as proposed in <http://sourceforge.net/tracker/index.ph ... tid=418823>.
(In fact, the Kega Fusion emulator has already adopted this approach, with an API that appears to be quite compatible with ScummVM.)

Would either of these 2 approaches be an acceptable feature for ScummVM? Note that I am happy to implement either of these approaches myself, as long as there is sufficient buy-in from the development team.

Comments?
Threepwood
Posts: 18
Joined: Tue May 30, 2006 1:16 pm

Post by Threepwood »

i like no 1

for agi games, i like hq2x most, stetching it by 2 would fill my monitor (at least in x-direction)
User avatar
gord
Posts: 25
Joined: Tue Feb 21, 2006 10:48 pm

Post by gord »

i don't like the idea of a 'plug-in' scaler, for an open source program plugin apis seem unnessasery, why should someone have to goto website x to get plugin y just so they can do z. if the software is needed then surely its just better to integrate it into scummvm.

this does seem to be a case where opengl rendering would be usefull, don't need to apply any scaler then.
mband
Posts: 5
Joined: Thu Jun 08, 2006 5:21 pm

Post by mband »

Gord, your point about plugins not being necessary with an open-source model is well-taken. However, I think there are still advantages to using plugins. With plugins:

(a) Incorporating new scalers, e.g. 2xPM or HQ4x will not bloat the ScummVM code. (For instance, I've heard that compiling HQ4x takes as long as the whole rest of ScummVM.)

(b) Incorporating new scalers will not have to involve the additional time and effort of the ScummVM development team, who are already donating a huge amount of time and skill. The ScummVM developers have historically rejected new scaler requests with reasons like "We already have too many scalers" and "That would bloat the code". Thus, a plugin model would remove the effort of incorporating and maintaining scalers away from the core development team.

(c) A plugin model is more generic, and could be used to theoretically support non-open-source scalers.

An OpenGL rendering would indeed be useful for scaling to full-screen size, but I would consider this as a separate case, since with OpenGL the type of scaling is controlled by the hardware/OS rather than by ScummVM (or a plugin). I.e. Ideally, you'd want to use your favorite scaler to scale the original graphics to as close to full-screen as possible, and then use an OpenGL rendering to rescale to true screen dimensions.
Post Reply