I'm using the old good Mixer API right now, but it does not work as expected on Windows Vista & 7 in the normal, not in XP compatibility mode. It mutes the sound for the current app only, but I need a global (hardware) mute. How to rearch the goal? Is there any way to code this w/o COM interfaces and strange calls, in pure C/C++?
views:
212answers:
1
+1
A:
The audio stack was significantly rewritten for Vista. Per-application volume and mute control was indeed one of the new features. Strange calls will be required to use the IAudioEndpointVolume interface.
Hans Passant
2010-02-27 15:04:05
Could you give a working sample for the problem stated above? Is there any way to abstain from COM, and to write the code in pure C or C++?
Dmitry Kramarov
2010-02-27 23:02:53
You've lived a blessed life if you never wrote any COM code before. There's no way around it. You can get a code sample from the guy that designed the interface. Link: http://blogs.msdn.com/larryosterman/archive/2007/03/06/how-do-i-change-the-master-volume-in-windows-vista.aspx
Hans Passant
2010-02-27 23:37:53