Optimize sounds by removing unused ones and re-encoding with VBR #134
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR aims to help somewhat with #126 by doing two things:
ffmpeg -c:a libvorbis -qscale:a 3. Converting to VBR is theoretically a very conservative change because VBR vs fixed shouldn't have a noticeable change in quality. However, since the source file was also an OGG and it's a lossy format, just re-encoding at all will lead to some quality loss. If the original source files were available, re-encoding from them would be betterI split these two changes into two separate commits, because I'm not entirely sure about nr 2. Unless I messed something up, I think nr 1 is a pure win, however, nr 2 may represent a small loss in quality as described above
OR, we may want to consider a more extreme version of nr 2 where we reduce the sample rate (would have a noticeable difference in quality, but may not matter given the ambient nature of the audio?) or use a lower quality setting for VBR (so having a lower overall bit rate, again, with a noticeable loss in quality).
Here are the size numbers for the
assets/sounddirectory:main: 46 MBSo, about a ~20 MB reduction in the source files. When exporting to web, I see about a ~18 MB reduction in the size of the PCK file