You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NBT files (from Notch's design) have its data compressed using Gzip. MC-Repack should have a special minifier for checking and recompressing this file format. (Suggestion from #2)
It should use either gzip or zopfli.
The text was updated successfully, but these errors were encountered:
zopfli can be quite slow based on using it in the past, so idk if it's worth using it tbh
here's a test file I ran through it, with the default zopfli iterations (15):
$ time zopfli --gzip -c infwoodfarm.nbt.uncompressed > infwoodfarm.zopfli.nbt
real 0m10.879s
user 0m10.712s
sys 0m0.032s
$ la
total 1.4M
-rw-r--r-- 1 solonovamax solonovamax 91K May 3 12:44 infwoodfarm.nbt
-rw-r--r-- 1 solonovamax solonovamax 1.2M May 3 12:45 infwoodfarm.nbt.uncompressed
-rw-r--r-- 1 solonovamax solonovamax 68K May 3 12:47 infwoodfarm.zopfli.nbt
so, it saved 24kb in 10 seconds, on a 91kb source file. (note: du shows it as being 92kb originally, so I'm using that)
decreasing it to only 5 iterations still takes 0m8.855s, but results in a file that is 72kb.
reducing it further to 1 iteration takes 0m8.263s, and the result is a file that is (also) 72kb.
Using 20 iterations takes 0m11.375s, and the result is a file that is 68kb, and using 80 iterations takes 0m20.615s, with the result being still 86kb 68kb.
but, if there's like even 20 or so nbt files in a mod, 10 seconds for each is quite long.
NBT files (from Notch's design) have its data compressed using Gzip. MC-Repack should have a special minifier for checking and recompressing this file format. (Suggestion from #2)
It should use either
gzip
orzopfli
.The text was updated successfully, but these errors were encountered: