change volume win32 c++

后端 未结 6 1991
你的背包
你的背包 2020-12-09 05:41

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

6条回答
  •  悲&欢浪女
    2020-12-09 06:27

    waveOutSetVolume and mixerSetControlDetails only change the volume for your application on Windows Vista and above.

    If you want to change the master volume on Vista and beyond, search for the IAudioEndpointVolume interface.

    Here's a blog post I wrote on this a couple of years ago.

提交回复
热议问题