This project is read-only.

Setting sound channel configuration

Sep 21, 2010 at 9:00 PM

I'm trying to find a way to programmatically set the sound channel configuration for Windows 7.  I have a set of 5.1 speakers plugged into my machine and need to be able to switch the channel configuration for the system from 5.1 to stereo fairly frequently (many programs don't play nice with analog headphones plugged in while the system is set to use 5.1 surround-- I think this is due to my soundcard).  At any rate, switching the channel configuration manually does the trick, but is tedious.  

I've been looking through your code here and it looks like there is a way to retrieve the current channel configuration, but is there a way to set it?  I saw in another discussion that you mentioned setting the default audio device programmatically in Win 7 isn't possible-- is setting the channel configuration programmatically likewise not possible?

Sep 23, 2010 at 3:58 PM

As far as I know, this is not a possibility using the WinMM API.

Both Win 7 and Win Vista have a significantly reduced set of functionality around controlling the audio properties of the system.

If I were you, I would look into AutoIt as a solution for automating the "tedious" parts of the configuration.

 

Sorry I couldn't be of more help.