python-soundfile icon indicating copy to clipboard operation
python-soundfile copied to clipboard

Wav Extensible Format Channel Mask

Open ehmean opened this issue 9 years ago • 2 comments
trafficstars

Hi, in Wav Extensible format struct, there is dwChannelMask to ensure correct channel layouts for multichannels wav.

Looks like this variable is handled by the following function in wavlike.c in libsndfile-1.0.27: int wavlike_gen_channel_mask (const int *chan_map, int channels) ;

Would like to know whether there is any plan to support this function in PySoundFile?

http://www-mmsp.ece.mcgill.ca/documents/audioformats/wave/wave.html https://msdn.microsoft.com/en-us/library/windows/hardware/ff538802(v=vs.85).aspx

Thanks.

ehmean avatar Aug 02 '16 08:08 ehmean

There is currently no plan to support this. For my personal taste, I would like to focus PySoundFile on being a module for reading audio files first, and leave the fact that it is implemented using libsndfile as an implementation detail.

However, I'd be happy to merge a pull request if you were to contribute some non-intrusive way of setting the channel map.

bastibe avatar Aug 02 '16 09:08 bastibe

I could try to work something out, however it might take some time. Will keep you posted on this. Thanks.

ehmean avatar Aug 03 '16 02:08 ehmean