Strategies for Slow Loading

What strategies do folks use to combat long loading times?

I'm working on my second port to Saturn using Jo Engine. It's a modest sized game but it's big enough that I am seeing a 15-30 second pause on game launch when I try to load all of the assets. I'm thinking about splitting the loading into three parts: intro assets, title assets, and game assets. I do not have separate levels.

Do people tend to load assets in chunks to minimize a one time hit? On bigger games, do you unload assets at the end of a level (just curious)? Are you using some kind of loading indicator while assets load? Are there any general optimization strategies used to try to reduce the size of assets in hopes of reducing the loading time?
 
Part of it is because the Jo Engine TGA loader is just slow. Because of how it works, it copies the file to HWRAM, parses it, and then copies it to VRAM - this isn't efficient.

It also has to parse the palette header every time (unless you're using RGB, but you will run out of VRAM faster), - and even if you set it to use the same palette slot, it still has to read that unnecessary data from the CD into HWRAM for each individual sprite file, wasting even more time.

You can definitely break up the loading into different parts (I do that), and you can use jo engine's sprite sheet loader so you're at least not parsing/seeking multiple files (RAM is a constraint here). You can also avoid using nested folders, because that takes additional seek time and directory processing.

But ultimately the better option is not to use the default loader/format and make your own. Check out the difference here between the jo engine TGA loader and my own custom one - keeping in mind I added *more* sprites to the custom one, to the point that I couldn't even load these assets without breaking them into multiple files on Jo Engine:


I basically pack about 350 individual sprites into a handful of container files. each scene loads a single container, which is also compressed, so loading from CD is really fast. It basically decompresses it straight into VRAM, so I'm only limited by VRAM on how many sprites can be packed together.
 
Last edited:
Back
Top