Search code examples
c++winapiaudiovolume

change volume win32 c++


How would I go about changing the sound volume in c++ win32? Also how would I mute/unmute it? Thanks for the help!


Solution

  • Two options:

    1. There's an answer to that question here on SO (changing the master volume from C++, which also includes SetMute, etc.)

    2. Have you considered showing the Volume controls and letting the user? If so, I can post some code for that. (You basically just shell out to the volume control applet.