[Scummvm-devel] Another plugin question
Max Horn
max at quendi.de
Fri Sep 11 00:01:11 CEST 2009
Am 10.09.2009 um 06:39 schrieb yotam barnoy:
>>
>> In the case of the DC, this also has the additional disadvantage that
>> the plugins would need to be present on the same disc which is
>> scanned
>> for games, or else 100 disc swaps would be required by the user.
>>
>
> Wow Marcus -- I completely forgot about that limitation of the DC. The
> PS2 would probably have a similar issue then, right?
>
>> In the scenario with separate plugins for detection, three swaps
>> would
>> still be required if the game plugin is not on the game disc.
>
> Nevertheless, I think the best overall solution is to have separate
> detection plugins
Quite possible, although it's not completely trivial, and needs to be
properly designed and implemented.
One caveat is for example what Johannes already mentioned: some
engines, like SCI, use detection code that is tightly interwoven with
the engine. While I consider this a deficiency of the engine that
should be removed, it still is a matter of fact, that would have to be
dealt with before such a "detection plugin" strategy could be really
useful (the strategy could be implemented before, of course).
> -- how often does one add games anyway?
On the DC: Possibly every time you want to play, if I understand
correctly... :)
> For now
> though, it would still be nice if we could choose via a variable or a
> #define whether to load all plugins at once for detection (option 1)
> or to load them one at a time (option 2). To sum up:
>
> NDS: MUST have option 2.
> DC: MUST have option 1.
> PS2: Probably must have option 1.
> PSP: Can work with option 1, but much better with option 2.
> Planning ahead: option 3 (detection plugins) is (probably) best.
>
> Max, I looked a little more into the code, and I see what you mean
> with the overhead. The problem is in MassAddDialog::handleTickle(),
> where we recurse through directories, calling EngineMan.detectgames()
> over and over. However, I think we could restructure it so that we
> first recurse through the directories, building up the file list, and
> only after that do we call EngineMan.detectgames() which will
> load/unload the plugins to check. If our concern is a list that's too
> big because of a monstrously huge file system, we can set a limit to
> the maximum list size to fill up and then call EngineMan.detectgames()
> on it and then resume.
Well, feel free to prepare a patch that implements this, and we can
have a look at it :)
Cheers,
Max
More information about the Scummvm-devel
mailing list