New Horizon on 24/10/2005 at 21:24
Hey guys,
I'm still working on this little project and I need some assistance from you programmers. :)
I sent Shadowspawn a PM but I thought I would throw this out for everyone to take a look at.
I want to get the installer size down...way down. The biggest hurdle will be the sound files, so what I would like to do, is extract all the sounds from T3 into the "sound" folder upon T3Ed installation.
Only a handful of the ingame sounds were included with the editor and those that were are in an xbox codec format. DXIW Sound drone extracts them as regular ogg or wav files....which is much better for listening to them outside of the editor.
Basically, I need something that functions like DXIW sound drone but with the possible addition of intelligently disecting the sounds, based on their group/type and putting them into their respective folders. Guard1 into guard1 for example. From the tests I've done, they should work if they're just thrown into the sound folder unsorted but I would like some sanity behind it all. :)
At any rate, how hard would it be to put together something like this with a command line interface? It would all be activated by the installer and would pull the sounds out of the .csc files in the main thief install folder and extract them to the T3Ed install folder.
Crispy on 25/10/2005 at 08:05
Well, the filenames of the files are all predictable - all the files in a specific subfolder have the same prefix. So all you need to do is write a little script to sort them into folders based on that prefix.
OrbWeaver on 25/10/2005 at 08:59
I was actually intending to write a tool to do this way back when, kind of like a PKzip for CSC files which would allow you to add, remove and extract sounds from them, but never got round to it since there did not appear to be a huge demand and Sound Drone already did quite a lot of that (it does not edit the metafiles but you can extract individual sounds).
It is certainly possible to do, since the format is "documented" (i.e. by examining the compileschemas.pl file packaged with the editor), but I don't think there is any current way to do it without writing a new custom tool.
New Horizon on 25/10/2005 at 11:54
Quote Posted by OrbWeaver
I was actually intending to write a tool to do this way back when, kind of like a PKzip for CSC files which would allow you to add, remove and extract sounds from them, but never got round to it since there did not appear to be a huge demand and Sound Drone already did quite a lot of that (it does not edit the metafiles but you can extract individual sounds).
It is certainly possible to do, since the format is "documented" (i.e. by examining the compileschemas.pl file packaged with the editor), but I don't think there is any current way to do it without writing a new custom tool.
It would be very cool if we could do that. The cleanest route would be to have all the sounds extracted into folders that match the names of their schema folder counterparts. If this could be done, it would greatly reduce the size of the installer. :) I have it down to around 220 to 250 megs with the sounds that came with it, but I bet we could get it down below 200 megs if we didn't have to package the sounds with it.
Dark Arrow on 25/10/2005 at 14:27
I would be more interested in extracting the .lad files from the metafiles. They are Lipsinc animation data files that control the lipsinc animations. If anyone wants to recompile the metafiles properly, they would first have to get these files out of the original metafiles.
New Horizon on 25/10/2005 at 15:43
Quote Posted by Dark Arrow
I would be more interested in extracting the .lad files from the metafiles. They are Lipsinc animation data files that control the lipsinc animations. If anyone wants to recompile the metafiles properly, they would first have to get these files out of the original metafiles.
That would be cool too. The more we can get out of it, the better...but we really need to be able to extract the sounds during the installer installation if I'm going to get the download size down to something more reasonable.
OrbWeaver on 26/10/2005 at 11:49
I had a look last night and I still have the fledgling script I wrote to dissect the CSCs. Currently all it does is parse some of the metadata at the beginning and build some structures in memory that index the various tags and schemas. I will see if it is possible to progress it to a point where it can dump out the schema data into a directory, although I don't know how much work this would involve or whether it is even possible (it may be that it is not possible to reconstruct all of the individual schemas from the combined metafile).
New Horizon on 26/10/2005 at 13:14
Hmmm. If it's not possible to extract them into their proper folders, then it would also be just as helpful if the wavs could be dumped into an 'sfx' folder and the .oggs dumped into a 'characters' folder, inside the Sounds folder. It won't matter if they're all jumpled up in the directory because the schemas are sorted properly in the schema editor and the sounds only need to be in the sound directory to be found by the game or the editor
One thing that Sound Drone does is that it strips the wav files down to a basic wav file format, instead of leaving them in xbox format.
From the Sound Drone Readme:
Quote:
- Extracting.
Select 'Extract' or 'Extract Raw' from the popup menu. What is the difference? Extract Raw extracts the data exactly as it is stored in the DXIW files. The problem with that is:
1. Most WAV sounds are stored in an audio format that is normally not playable. You will need the Xbox ADPCM audio codec for that, it can be found on the internet.
2. Some WAV sounds are just plain WRONG. To get technical: the size in the RIFF chunk is often not correct and the fact chunk is often missing for the Xbox ADPCM sounds. Some sound utilities will not be pleased with these files and either complain and/or even refuse to open them.
This is where Extract comes in...it will extract the Xbox ADPCM sounds as normal 16 bit PCM and it will
strip WAV files to their bare bone chunks (RIFF, format and data) with corrected sizes.
Note: OGG files are NOT affected in any way.
New Horizon on 11/11/2005 at 01:11
Has anyone had a chance to look into this?
I'm on my third test compile of the installer. After turning any wav files that have corresponding oggs into dummy files of 1kb, the installer is still far too big. (Perl script looks for ogg versions of any wav listed and uses ogg if they exist. If no wav files exist then none of the oggs are loaded into the metafile, hence the need for the dummy files. If only wavs exist, then they are loaded into the metafile).
I have compiled a full set of metafiles to go with this custom version of the editor but we could really get the size down if there was a simple app that would extract all the wavs and oggs into the sound folder. They don't even have to be sorted properly into folders because they are sorted properly in the editor by the .sch files.
Hmmm, perhaps it might even be easier if I just set it up to compile the schemameta files upon installation? This would require installing perl though, so it would be best to make it optional. I'll have to be sure to state that many sounds only work with the compiled schemameta files though. I'm leaning heavily towards this latter method.
OrbWeaver on 11/11/2005 at 10:29
Altering the Perl script to pick up OGGs if there is no WAV should be easy (assuming it is not written in some godawful way which makes it hard, but I don't think it is).
Is the schema extraction something you want to do once, to create your installer, or something that needs to be performed on the user's PC?