From ScummVM :: Wiki
Jump to navigation Jump to search


  • Fill stubs in audio code
  • Get rid of Window classes. We handle that in OSystem
  • Enhance package manager to allow running with extracted data just like original did
  • Graphics:
    • Problems with the exit menu:
      1. Wrong shading of 'yes/no' glyphs
      2. Background is black instead of shadowed game screen
    • Speedup Theora video playback
    • Audio sync for Theora video playback
  • Get rid of BS_SERVICE_TABLE (?)
    • because it is (a) ugly concept (b) implemented with global constructors. The worse approach would be to turn those into Singleton classes, but proper would be to remove the wrappers completely since we do not have multiple implementations of each service
  • Translate comments from German
  • Fix 64-bitness
  • Check how it behaves on BE machine
  • Rename/get rid of leftover BS_* things
  • Fix tons of warnings under MinGW and probably others
  • Make libtheora optional, as it really is (cutscenes then will be skipped) - this has been done, but it should be tested
  • The engine is currently somewhat slower than the original game, particularly on game startup. Some profiling should be done to identify and improve performance.
    • A major reason for slowness is that when finding a matching file list for a given file-spec, it currently scans the entire contents of the zip file index. When we correct the Zip file implementation to properly handle folders, this will speed things up, since since it will be able to traverse down to a specific folder, and only have to scan the files of that folder.
  • Fix issues due to using libpng: The engine uses libpng. This will cause problems when building with dynamic plugins, as then either the sword25 engine then would have to be linked directly against libpng (which may not be possible everywhere), or the main ScummVM executable. But in the latter case, we get issues on systems that do not allow backlinking (such as Windows). The way we overcame this for other similar cases is to add a thin wrapper API around the library and put that into the shared code base (in this case, something like graphics/png.* might be appropriate).


  • Lua exceptions require use of setjmp (not portable) or throw/catch (but we normally disable exceptions in ScummVM builds to reduce memory usage). This needs to be dealt with. E.g. we should add a configure check for setjmp, and only enable the engines on ports that support this.
  • Lua makes use of several other potentially non-portable or "dangerous" routines, that should be avoided in ScummVM code. I noticed the following (but the list may not be complete):
    • in loslib.cpp:
      • strerror
      • system (!!)
      • remove
      • rename
      • tmpname / mktemp
      • getenv
      • clock
      • gmtime
      • localtime
      • mktime
      • time
      • difftime
      • setlocale
      • exit (replace by a call to OSystem::quit, or "just" quit the engine?)
    • in liolib.cpp and lauxlib.cpp:
      • fopen, fread, fwrite, fclose, fseek, setvbuf, ... -> use our file API instead?
    • in loadlib.cpp
      • fopen / fclose
      • this contains stuff for dealing with loadable modules (which we don't really need, do we?). So we might be able to just stub it out completely.