HearthSim / python-fsb5

Library and tool to extract audio from FSB5 (FMOD Sample Bank) files
https://hearthsim.info
MIT License
133 stars 38 forks source link

OGG Support #10

Closed Mactastic1-5 closed 7 years ago

Mactastic1-5 commented 7 years ago

Is OGG supported or not?

synap5e commented 7 years ago

libogg and libvorbis are required to decode ogg samples. For linux simply install from your package manager. For windows either ensure the dlls are installed or download the appropriate release.

If ogg files are not required to be decoded then the libraries are not required.

Release b7bf605 has working DLLs for this if you are on windows. Some people have has issues with different version of these DLLs so going from this release is the best bet.

Also is is possible FSBs generated with older versions of the packer will fail to decode because of different codebooks. If decoding hits a KeyError then you will need to extract this from the binary using generate_vorbis_header_lookup.py but chances are things will work out of the box.

Mactastic1-5 commented 7 years ago

Other formats can be identified but will be extracted as .dat files and may not play as the headers may be missing.

Why does the README say this if OGG samples are supported with 3rd party libraries?

synap5e commented 7 years ago

Oh I see the cause for confusion. In the readme it says

Supported formats

  • MPEG
  • Vorbis
  • WAVE (PCM8, PCM16, PCM32)

OGG is the container format commonly associated with Vorbis samples, so when one packs OGG files into a FSB the Vorbis data is taken from the OGG file and packed into the FSB. When this tool unpacks it takes the Vorbis data out and puts it inside an OGG container.

I suppose I could update the readme to say

Supported formats

  • MPEG
  • Vorbis (OGG)
  • WAVE (PCM8, PCM16, PCM32)
Mactastic1-5 commented 7 years ago

@synap5e I'll comment it.

synap5e commented 7 years ago

11 merged