Måns Rullgård <mans@xxxxxxxxx> writes: > Thomas Foerster <tjfoerster@xxxxxx> writes: > >> Hi, >> >> I am a little bit confused about the following procedure >> (Windows). What is wrong? >> >> 1. Take a usual 2ch/16 Bit/44,1 kHz WAV-File (CD) >> 2. To get a 32 Bit FLOAT 88200 Hz File: >> sox input_16_44100.wav" -b 32 -e float output_88200_32F.wav rate -s -a >> -v -L 88200 >> 3. sox output_88200_32F.wav output_88200_32F.raw >> >> The *.raw file has 58 bytes less-> the Wav-Float-Header has a size of >> 58 bytes. My own codecannot read this header in Audio format 3 (only >> wav-PCM and Extensible like 24 Bit Wav and 32 Bit Wav). I looked >> inside with Hex-Editor: >> >> -4 byte fact-chunk is beginning at byte 38 >> -4 byte data-chunk is beginning at byte 50 ("usually" before fact-chunk) >> >> I could not read the size of the raw-data-chunk (raw data >> length). Theses bytes are at the end of the header. Here(hex): 00 00 >> D8 0E -> >> 55310 bytes, what is wrong! >> It should be (dec:) 249036800bytes! This would be 0E D8 00 00 -> most >> significant bit! >> >> Then I tried this: >> sox.exe -r 88200 -e float -b 24 -c 2output_88200_32F.raw out.wav >> Error! >> This would be working (but makes no sense...): >> sox.exe -r 88200 -e signed-integer -b 24 -c 2output_88200_32F.raw out.wav >> >> Any idea? > > Can you post a hex dump of the full header? The dump you sent (and please stay on the mailing list) looks fine. The data chunk size has the bytes 0x00 0x00 0xd8 0x0e, which read as *little endian* is 0xed80000 or 249036800 in decimal, just like you said it should be. All values in wav files are stored as little endian. -- Måns Rullgård ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Sox-users mailing list Sox-users@xxxxxxxxxxxxxxxxxxxxx https://lists.sourceforge.net/lists/listinfo/sox-users