re-program ScummVM to output to hardware overlay.

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

Moderator: ScummVM Team

Post Reply
Malice
Posts: 6
Joined: Mon Oct 31, 2005 9:03 am

re-program ScummVM to output to hardware overlay.

Post by Malice »

I know in the past the SDL graphics library ScummVM uses couldn't output to hardware overlay. But recently i read it is possible now under Linux. So that makes me wonder if it's possible under windows also.

Has anyone tried this?
User avatar
sev
ScummVM Lead
Posts: 2301
Joined: Wed Sep 21, 2005 1:06 pm
Contact:

Post by sev »

It's out of scope of ScummVM, but rather SDL question.


Eugene
User avatar
eriktorbjorn
ScummVM Developer
Posts: 3558
Joined: Mon Oct 31, 2005 7:39 am

Re: re-program ScummVM to output to hardware overlay.

Post by eriktorbjorn »

Malice wrote:I know in the past the SDL graphics library ScummVM uses couldn't output to hardware overlay. But recently i read it is possible now under Linux. So that makes me wonder if it's possible under windows also.

Has anyone tried this?
That'd be SDL's YUV Overlays I suppose.

I did some experimenting with them to see if I could use them for the MPEG movies in Broken Sword, since they already use the YUV colour space, and our YUV to RGB conversion used ridiculous amonts of memory. I never could get it to work quite right (my own fault, probably), and it was pretty messy: It was drawing outside of the normal ScummVM scaling framework, so it had to use the scaling abilities of the overlay instead. And that's only guaranteed to work for 1x and 2x scaling, not 3x. Also, I couldn't decide on any sensible way of exposing the overlay API to the game engine.

In the end, I simply borrowed SDL's much less memory-hungry YUV to RGB conversion code.

Using it to create an accelerated 2x scaler might be less messy since it would be private to the backend. It'd probably still be quite a bit of work, though, and I'm not entirely convinced of its usefulness. Of course, if someone were to submit a patch, it could then be evaluated...
Post Reply