ich habe ein paar PCM Dateien die ich nach WAV wandeln möchte.
Die PCM Dateien haben angeblich folgendes Format:
- Raw PCM (no header)
8000 samples per second
8 bits per sample
uLaw compression
Ich lese sie in den Speicher und setze die 44 bytes WAV header davor.
- 4 ChunkID Contains the letters "RIFF" in ASCII form
4 ChunkSize This is the size of the entire file in bytes minus 8 bytes 4 Format Contains the letters "WAVE"
4 Subchunk1ID Contains the letters "fmt "
4 Subchunk1Size 16 for PCM. This is the size of the rest of the Subchunk
2 AudioFormat PCM = 1 (i.e. Linear quantization)
2 NumChannels Mono = 1, Stereo = 2, etc.
4 SampleRate 8000, 44100, etc.
4 ByteRate == SampleRate * NumChannels * BitsPerSample/8
2 BlockAlign == NumChannels * BitsPerSample/8
2 BitsPerSample 8 bits = 8, 16 bits = 16, etc.
4 Subchunk2ID Contains the letters "data"
4 Subchunk2Size == NumSamples * NumChannels * BitsPerSample/8
* Data The actual sound data.
Kann es sein dass das mit der "ulaw" Kompression zu tun hat?
Ich habe schon mit dem Wert "AudioFormat" gespielt, aber das führt zu nichts.
Gruß
Michael
edit:
Ich habe eine Lösung gefunden.
http://sox.sourceforge.net/
Das tool kann alle Sounds konvertieren.
Wäre nett wenn es das auch als DLL gäbe.