libretro / swanstation

GNU General Public License v3.0
96 stars 22 forks source link

Add CHD precache support #1

Closed realnc closed 2 years ago

realnc commented 2 years ago

This uses the chd_precache() function of libchdr which just loads the CHD image to memory without decompressing it. So this is "weaker" than the full preload to RAM option, which fully decompresses the CHD image, but it still solves the problem of having the CHD images stored on unreliable network storage. It's also much faster, since CHDs are quite slow to decompress in whole.

The main point of this is to be able to use M3U files to run multi-disc games and still be able to work around unreliable storage. The full preload to RAM option does not work with M3U files. This option does.

CHD precache is ignored (and the option disabled in the UI) if the full preload to RAM option is enabled.

DarthMew commented 2 years ago

Gave it a run, and everything works as expected.