summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <bjorn@lindeijer.nl>2025-02-18 12:26:27 +0100
committerThorbjørn Lindeijer <bjorn@lindeijer.nl>2025-02-18 12:27:17 +0100
commite0b55f0f58931e67008d317855cadeb9d59fccbf (patch)
tree1dc701caf5521ec308e1192b5f7bd714d3acea0e
parent63807cbe838a32cb6805f0a8ee5efe1548513a83 (diff)
downloadtools-master.tar.gz
tools-master.tar.bz2
tools-master.tar.xz
tools-master.zip
Disable compression for OGG filesHEADmaster
Compressing OGG files makes little sense (I'm seeing a 1.3% increase in file size for TMW-music.zip with compression disabled) but the need for decompressing these relatively large files is causing a noticeable stutter when the Mana client switches music. Without compressing OGG files, the `Mix_LoadMUS_RW` call still takes about 45ms, so the stutter isn't gone entirely unfortunately. But previously it could take over 250ms, depending on the song. See https://git.themanaworld.org/mana/mana/-/issues/93
-rwxr-xr-xclient/make-updates.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/client/make-updates.sh b/client/make-updates.sh
index dba3bde..9c94d59 100755
--- a/client/make-updates.sh
+++ b/client/make-updates.sh
@@ -67,10 +67,10 @@ if [ "$UPDATE_HTTP" == "none" ] ; then
fi
echo -e "\e[96m>> Compressing files...\e[0m"
-find -path ./music -prune -o -path ./mods -prune -o -iregex ".+[.]\(xml\|png\|jpg\|tmx\|ogg\|txt\|po\|tsx\)" -printf "%P\n" | zip -X -@ $dir/files/TMW.zip
-find -path ./sfx -prune -o -path ./mods -prune -o -iregex ".+[.]\(ogg\)" -printf "%P\n" | zip -X -@ $dir/files/TMW-music.zip
+find -path ./music -prune -o -path ./mods -prune -o -iregex ".+[.]\(xml\|png\|jpg\|tmx\|ogg\|txt\|po\|tsx\)" -printf "%P\n" | zip -X -@ -n .ogg $dir/files/TMW.zip
+find -path ./sfx -prune -o -path ./mods -prune -o -iregex ".+[.]\(ogg\)" -printf "%P\n" | zip -X -@ -0 $dir/files/TMW-music.zip
#find ./mods -printf "%P\n" | zip -X -@ $dir/files/TMW-mods.zip
-find ./mods -type f | xargs zip -9 -r $dir/files/TMW-mods.zip
+find ./mods -type f | xargs zip -9 -r -n .ogg $dir/files/TMW-mods.zip
touch $dir/files/TMW-music.zip
touch $dir/files/TMW-mods.zip