FMOD .ogg from .fsb from .bank

Codecs, formats, encoding/decoding of game audio, video and music
swinei
Posts: 20
Joined: Sat Nov 05, 2016 2:19 pm

FMOD .ogg from .fsb from .bank

Post by swinei »

I am using

Code: Select all

for OFFSET = 0
    goto OFFSET
    findloc OFFSET string "FSB5"
    goto OFFSET
    getdstring FSB_SIGN 4   # FSOUND_FSB_HEADER_FSB5 (fsb.h)
    get version long
    get numsamples long
    get shdrsize long
    get namesize long
    get datasize long
    xmath SIZE "0x3c + shdrsize + namesize + datasize"
    log "" OFFSET SIZE
next OFFSET + SIZE

to extract the .fsb files from a .bank file. This works for the most part, but I am running into problems with some banks.

The audio files in the banks are .ogg so I'm using fsb_aud_ext.exe to get them. Trying to extract the .fsb made from the .bank (see attachment) gives me the error "End of file unexpectedly reached while trying to read essential data (truncated?)"

The resulting .ogg files are complete but have added static in the end. I assume this is a problem with the generated .fsb files? This problem also occurs with files where the error mentioned above does not happen.
id-daemon
Posts: 1040
Joined: Sun Mar 22, 2015 7:09 pm

Re: FMOD .ogg from .fsb from .bank

Post by id-daemon »

I got the FSB file you have here and it was completely extracted with fsb_aud_extr.exe

I don't understand what else you want.
swinei
Posts: 20
Joined: Sat Nov 05, 2016 2:19 pm

Re: FMOD .ogg from .fsb from .bank

Post by swinei »

Is there no static at the end of the files for you?

And do you not get the "End of file unexpectedly reached while trying to read essential data (truncated?)" error?
id-daemon
Posts: 1040
Joined: Sun Mar 22, 2015 7:09 pm

Re: FMOD .ogg from .fsb from .bank

Post by id-daemon »

No static.
No errors.
swinei
Posts: 20
Joined: Sat Nov 05, 2016 2:19 pm

Re: FMOD .ogg from .fsb from .bank

Post by swinei »

Hm, strange. I tried different dll versions and different computers and I always get audio with static and three files throw an error. This is my output, any idea what's causing this?
id-daemon
Posts: 1040
Joined: Sun Mar 22, 2015 7:09 pm

Re: FMOD .ogg from .fsb from .bank

Post by id-daemon »

wrong old version of a tool maybe. I used my latest and the one from this thread viewtopic.php?f=17&t=1901

both work ok
swinei
Posts: 20
Joined: Sat Nov 05, 2016 2:19 pm

Re: FMOD .ogg from .fsb from .bank

Post by swinei »

Okay let's see, I am using:
  • quickbms 0.7.6a
  • the script from my first post to extract the .fsb
  • fsb_aud_extr.exe from your post
  • fmodL.dll from this post

Is that different from what you are using?
id-daemon
Posts: 1040
Joined: Sun Mar 22, 2015 7:09 pm

Re: FMOD .ogg from .fsb from .bank

Post by id-daemon »

ok the problem is in fmodL.dll. It is newer then the API code I used to build my tool. This can cause problems, they warned about that.

This is old version.
swinei
Posts: 20
Joined: Sat Nov 05, 2016 2:19 pm

Re: FMOD .ogg from .fsb from .bank

Post by swinei »

It works now! Thanks a lot! :)