lah7 / sims2-4k-ui-patch

Work in progress patch program to upscale The Sims 2's UI for 4K displays
GNU General Public License v3.0
33 stars 2 forks source link

Optimising QFS compression level #36

Closed lah7 closed 4 months ago

lah7 commented 4 months ago

Just an issue to document test findings.

The game compresses its packages using QFS compression - but which level is best for recreating the package?

I wrote a script to benchmark the levels using a test file (can be found in the tools folder) to find out!

Test Environment

Results

Higher compression levels take longer to compress. When you add up the game & expansion packs, and that the patcher program is currently single threaded, it does take a really long time. After about level 30, it's not really worth the trivial smaller file size. Overall, there is not much difference to the decompression time.

For now, I'll set the hardcoded value to 20. In future, I'll add more options to the patcher program so this can be freely changed.

QFS Level vs File Size

QFS Level vs Time

Colour Scale Results

results.csv