NWaves
NWaves copied to clipboard
Update WaveFile.cs
Fix to allow parsing WAV files which use an Extension chunk to describe PCM audio formats greater than 16-bit. Microsoft states that any WAV file with a Bit Depth of more than 16 should use the Extension chunk to describe the Audio Format, but it will still use the same Audio Format constants used in the container-level Audio Format.
When a file uses the Extension chunk to describe a non-custom Audio Format, the container-level Audio Format will be set to 0xFFFE
.
This is currently not handled by WaveFile
, and at the moment results in no sample data being read.
Link to relevant sources included in code comments.