envx.c: extracts an amplitude envelope from a mono soundfile