write_wav supports generators