READ THE RULES: Click here

Follow us on Facebook: https://www.facebook.com/xentax/ :)

Getting playable OGGs out of Just Cause 3's FMOD .fsb files

Get help on any and all audio formats, or chip in and help others!
Post Reply
User avatar
GordenF
n00b
Posts: 14
Joined: Fri Jul 15, 2016 11:14 pm
Has thanked: 2 times
Been thanked: 2 times

Getting playable OGGs out of Just Cause 3's FMOD .fsb files

Post by GordenF » Fri Jan 06, 2017 6:18 pm

I realize that this is a problem likely as old as time itself, but:

I used Gibbed's tools to extract JC3's arc/tab files and then used this QuickBMS script to extract FSBs from the extracted .bank files:

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
It's from somewhere in this forum, I forgot from where exactly.

Next, I used Aezay's FSB Extractor (I probably could've used fsbext.exe, but this GUI was nice to use and displayed extra info) to try to extract the actual music from these files, but all I got were weird OGG files with what seems to be a missing header.
Now, I used Google extensively before writing this post and it seems that the only solutions to this problem are:
1. Using FMOD Designer to rejigger the FSB files, which is pretty hard because one can't actually download it anymore without emailing their sales dept
2. Recording the output of some tool called "Music Player Ex" which I can't find because there are so many malware sites using that name

I realize that the OGG format (or at least the version used by the FMOD thingy) makes it difficult if not impossible to restore a generic header.
Still, I'd like to avoid reencoding the sound files if at all possible. Has someone solved the problem of extracting FMOD files yet?

If anyone wants to take a shot at extracting the music, here's one of the OGG files: https://bubbelsearch.de/files/jc3/jc3_m ... rd_end.ogg

User avatar
GordenF
n00b
Posts: 14
Joined: Fri Jul 15, 2016 11:14 pm
Has thanked: 2 times
Been thanked: 2 times

Re: Getting playable OGGs out of Just Cause 3's FMOD .fsb fi

Post by GordenF » Sat Jan 07, 2017 4:56 am

Welp, I figured out how to do it.
A kind soul by the name of Tomasz Miąsko wrote a tool to extract samples from FSB5 files, but included an assertion that made the program fail on unexpected headers, making extraction from Just Cause 3's files impossible.
I fixed that assertion to make it possible: https://github.com/SamusAranX/fsb-vorbis-extractor
It's seemingly Linux-only, but that shouldn't be a problem. If I did it, everyone else with access to a working Linux system should be able to do it as well.

It still crashes on FSBs that contain non-music files, namely on these:
  • character
  • debug
  • dialog
  • diegetic
  • effects
  • game_objects
  • gui
  • vehicles*
  • weapons*
Luckily, all the music gets exported correctly, as far as I can tell. Here's the contents of my music_challenges folder after extraction:
Image
And best of all, it doesn't seem to get re-encoded, so you're getting it as the devs intended it to be heard: In ~200-300 kb/s Ogg Vorbis. :D
(Seriously, I can't effing wait for an official soundtrack release on CD. Take all my money, Avalanche.)

ponaromixxx
beginner
Posts: 23
Joined: Thu Jul 17, 2014 4:52 am
Has thanked: 1 time
Been thanked: 7 times

Re: Getting playable OGGs out of Just Cause 3's FMOD .fsb fi

Post by ponaromixxx » Tue Nov 07, 2017 10:30 pm


Post Reply