extracting audio

Adm_maverick

Rear Admiral
Hey all, so I'm working on a project using Wing Commander Prophacy and I'd like to extract the audio. So I figure it is stored in audio.tre. Did some reading and found the HCI made a Tre manager that can extract the files. Cool. So did some more digging found there's also an audio decompressor for the files once they are extracted. Cool so I'm rolling. Oh wait, they don't work under Windows 10. Okay no big. I'll pull out my vista laptop, install the game and run the extraction/decompression from there. Pull out the disks, install the game, use a flash drive to move the tools. So I drag and drop audio.tre onto the tre manager, it opens and I hit the 'Extract all files from tre' option. It runs for abut a minute give or take, lots and lots of file info flashes before my eyes and it comes back to the main menu. I assume it's finished.

Where does it extract the files to? I see no new files in C:\, Documents, the WCP folder, the USB drive I ran the tool from. Nothing.

Thinking maybe the extraction 'unlocked' the tre file to allow the audio tool to work I open that. I click on the 'decompress' option, it asks what file.

And this is when I see a new folder in the WCP folder. This one labeled "audio". I open that and find several dozen .iff files. Okay looks like the extractor worked. I select the files and hit 'select'. The audio sits where it is. I have the 3 buttons that read "decompress" "compress" and "exit". So maybe it's a single run command? I click exit, it closes. So where are the decompressed files? Where are the files the tre manager extracted? Why can I only see this phantom 'audio' file and it's contents when I use the audio tool?

In short, is there some instruction for using these tools?
 
The tre file extractor will just break the tre file down into it's component parts, which will be all those IFF files your found. The IFF files should be the individual audio files.

I did a test extraction on audio.tre found in my prophecy install. I used treman.exe via dosbox and extracted all files (note: you have to also have cwsdpmi.exe in the same directory as treman). I ended up with a subdirectory called audio with another directory in it called SOUNDFX that included 226 individual IFF files and one RAW file. The IFF files are the individual sound files, but they still need changed into a usable file format... IFFUTIL tells me these are all saved in XA audio format.
 
Okay, I need to run TREMAN in DosBox, that helped a lot. Thanks AD. Is there by anychance some sort of online documentation I can get my hands on so I can see what files is what in the tres? Also is there a utility that can do batch conversion by anychance?
 
I believe if you just run treman without specifying a tre file it will tell you the proper usage and options that you can use when running. One of them should just list all the included files instead of extracting them. Another option lets you extract specific files, and one just dumps everything in the TRE all at once. Once you have the files extracted with TREMAN, you should be able to use some of the utils like IFFUTIL or VIFF (included on some old archived dev cds of prophecy stuff) that will give you a a look at the basic structure of the IFF and what the main chunks are within it. Alternately you can sometimes just open the IFF in notepad or a hex editor and sometimes you can spot the chunk headers.

The audio files I extracted start with
Code:
FORM SAMP
{
    CHUNK FRMT
    {
        byte 0x01,0x00,0x01,0x00,0x22,0x56,0x00,0x00,0x44,0xAC,0x00
        byte 0x00,0x02,0x00,0x41,0x00
    }
    CHUNK LENG
    {
        byte 0x72,0xBA,0x00,0x00
    }
    CHUNK C XA

It's 'form samp' because it's a sample. The 'CHUNK LENG' is presumably because this is the english language clip. CHUNK C XA contains the actual sound data
 
Thanks for the help AD. You've just earned yourself a listing in the credits of my WCP Video series (or at least the first video of it). But I've found myself in a new situation. I've gone through an extracted literally every file from all of the tre files in the WCP directory (found 2 FMVs I hadn't seen before by the way). But I can't seem to find all of the in-flight responses from the pilots. I've found them from the Midway and I've found the story specific comms, well most of them. But like when Stilleto says "Tagged him!" or Maniac exclaims "I do believe that is a kill for the maniac" or any of the communications for the Nephilim. Don't suppose you have any idea where else these files could be?
 
Last edited by a moderator:
I don't have time to check them all until later tonight but I'd suggest looking at all the speech*.tre files and possibly the gf/gameflow tre files. Some times there's mission specific audio in the files where the missions themselves are specified too.
 
I don't have time to check them all until later tonight but I'd suggest looking at all the speech*.tre files and possibly the gf/gameflow tre files. Some times there's mission specific audio in the files where the missions themselves are specified too.

Yeah I went through all the speech tres (speech1, speech2 and speech3), as well as the audio.tre I found a lot of audio files, including the computer voice that explains the mission from the ICIS panels. Didn't find a single audio file from Amazon, Spyder, Maniac, Maestro or the other pilots. Only found Blair's story bit comms. Not his in-flight comms.
 
Back
Top