[Scummvm-devel] Slowdowns in SCI and SAGA

Johannes Schickel lordhoto at scummvm.org
Wed Nov 25 20:08:35 CET 2009


yotam barnoy wrote:
> I know SCI is in development. However, SCI0 works so beautifully on 
> the PC, and it used to work well on the PSP too. I decided to load it 
> up in gprof to see what's eating up cycles -- the engine simply 
> crawls. Turns out the OPL code is bringing the PSP to its knees, no 
> matter which OPL driver I use (Dosbox or MAME). 90% of CPU time is 
> used up handling the OPL stuff. This doesn't happen in any other engine.

Actually for SCI it doesn't matter which driver you select in the config 
options... Our code for selecting an OPL emulator does ignore the user's 
setting, when the selected emulator does not support what the engine 
requires (in this case dual opl2 mode). Instead it will always try to 
auto select an OPL emulator which support dual opl 2.

This behavior can be easily changed by changing "drv = -1;" to "return 
-1;" in sound/fmopl.cpp line 86.

It shouldn't break audio at all for SCI, since the SCI engine falls back 
to mono (single OPL2) in case there's no emulator supporting dual opl2 
built in.

// Johannes




More information about the Scummvm-devel mailing list