[PD] Peeking at a WAV file's headers?

Ken Restivo ken at restivo.org
Thu Apr 24 08:17:37 CEST 2008


I've built a little patch to read and play stereo WAV files, but soundfiler crashes PD completely and exits if I open a mono WAV file.

I'm using "read -resize $1 testsampleL testsampleR" to read into two arrays.

Is there some way in PD to conditionally peek at the WAV header, so that I can do that first and only open the file if it has 2 channels?

-ken




More information about the Pd-list mailing list