mirror of
https://github.com/ScrelliCopter/VGM-Tools
synced 2025-02-21 04:09:25 +11:00
Compare commits
2 Commits
7c5a577fba
...
6d60ea91c0
| Author | SHA1 | Date | |
|---|---|---|---|
| 6d60ea91c0 | |||
| 6164533c1a |
@@ -1,32 +1,46 @@
|
|||||||
Neo-Geo VGM tools
|
Neo-Geo VGM tools
|
||||||
-----------------
|
=================
|
||||||
|
|
||||||
A hodge-podge of tools for working on NG VGM files,
|
A hodge-podge of tools for working on NG VGM files,
|
||||||
these files are provided in the hope that they may be useful to someone.
|
these files are provided in the hope that they may be useful to someone.
|
||||||
|
|
||||||
Makefiles have currently not been tested but shouldn't be hard to get working.
|
|
||||||
Windows binaries are available under the Releases tab.
|
|
||||||
|
|
||||||
Included tools (sources included).
|
Included tools (sources included).
|
||||||
- **adpcm.exe**:
|
- **adpcm**:
|
||||||
ADPCM Type-A to WAV converter.
|
ADPCM Type-A to WAV converter.
|
||||||
- **adpcmb.exe**:
|
- **adpcmb**:
|
||||||
ADPCM Type-B encoding tool that also does decoding to WAV.
|
ADPCM Type-B encoding tool that also does decoding to WAV.
|
||||||
- **neoadpcmextract.exe**:
|
- **neoadpcmextract**:
|
||||||
Scans a .vgm and dumps all ADPCM type A&B data to raw .pcm files.
|
Scans a .vgm and dumps all ADPCM type A&B data to raw .pcm files.
|
||||||
- **autoextract.bat**:
|
- **autoextract**:
|
||||||
Convenience batch script that uses the above tools to dump all samples to WAVs.
|
Convenience shell/batch script that uses the above tools to dump all samples to WAVs.
|
||||||
|
|
||||||
|
Building
|
||||||
|
--------
|
||||||
|
Linux:
|
||||||
|
```shell script
|
||||||
|
make -f adpcm.Makefile
|
||||||
|
make -f adpcmb.Makefile
|
||||||
|
make -f neoadpcmextract.Makefile
|
||||||
|
```
|
||||||
|
|
||||||
|
Windows:
|
||||||
|
- The updated Makefiles haven't been tested on Windows yet.
|
||||||
|
- Working Windows binaries are available from the [Releases](https://github.com/ScrelliCopter/VGM-Tools/releases) tab.
|
||||||
|
|
||||||
How to use
|
How to use
|
||||||
----------
|
----------
|
||||||
Copy your .vgz into this directory, drag it onto autoextract.bat,
|
Linux:
|
||||||
the script will create a directory of the same name and dump all the converted samples there.
|
- Run `./autoextract.sh` from this directory with a path to your .vgm or .vgz,
|
||||||
|
a directory for the song will be created containing wav samples.
|
||||||
|
|
||||||
|
Windows:
|
||||||
|
- You will need gzip.exe (provided with the aforementioned release).
|
||||||
|
- Copy your .vgm or .vgz into this directory, drag it onto autoextract.bat,
|
||||||
|
the script will create a directory of the same name and dump all the converted samples there.
|
||||||
|
|
||||||
That's all there is to it.
|
That's all there is to it.
|
||||||
|
|
||||||
TODO
|
TODO
|
||||||
----
|
----
|
||||||
|
|
||||||
- Replace the batch script with something less shite (and actually cross-platform).
|
- Unify all tools into one & obsolete the crappy glue scripts.
|
||||||
- Write a makefile for neoadpcmextract.
|
|
||||||
- Make this stuff build on Linux.
|
|
||||||
|
|||||||
19
neotools/autoextract.sh
Executable file
19
neotools/autoextract.sh
Executable file
@@ -0,0 +1,19 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
FILE="$1"
|
||||||
|
NAME="$(basename "$FILE")"
|
||||||
|
WAVDIR="${NAME%%.*}"
|
||||||
|
|
||||||
|
if [ "${NAME##*.}" = "vgz" ]; then
|
||||||
|
cp "$FILE" "temp.vgm.gz"
|
||||||
|
gzip -d "temp.vgm.gz"
|
||||||
|
FILE="temp.vgm"
|
||||||
|
fi
|
||||||
|
|
||||||
|
./neoadpcmextract "$FILE"
|
||||||
|
mkdir -p "$WAVDIR"
|
||||||
|
for I in smpa_*.pcm; do ./adpcm "$I" "$WAVDIR/${I%%.*}.wav"; done
|
||||||
|
for I in smpb_*.pcm; do ./adpcmb -d "$I" "$WAVDIR/${I%%.*}.wav"; done
|
||||||
|
find . -type f -name "*.pcm" -exec rm -f {} \;
|
||||||
|
|
||||||
|
[ "$FILE" = "temp.vgm" ] && rm -f "temp.vgm"
|
||||||
Reference in New Issue
Block a user