Support reading sox style piped wav files

Sox writes the RIFF header size as a very large number, instead
of as 0 as in libavformat.
Add support for waveformatex files

This is used for multichannel wave files.