michael-fadely / sadx-dc-lighting

Sonic Adventure 1 palette lighting for SADX PC.
MIT License
39 stars 3 forks source link

Implement Disk Shader Cache #57

Closed michael-fadely closed 6 years ago

michael-fadely commented 6 years ago

In order to speed up startup times in release builds, I'd like to implement a shader cache system not too dissimilar to the one used in Dolphin pre-uber shader.

This system would minimally need to detect changes made to the shader via checksum of the HLSL source code and invalidate if checksums differ.

My initial idea for implementation is:

Assuming the cache has not already been invalidated, the shader cache loading process would be something along the lines of: