How can I control the Windows 7 mixer programmatically?

前端 未结 1 450
心在旅途
心在旅途 2021-01-03 09:19

Windows 7 has per-application volume controls that let you mute applications individually. How can I mute and unmute an application from a console app?

1条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-03 09:44

    You'll want to use the IAudioSessionManager2 COM interface. Have a look at Vista Core Audio API Master Volume Control that wraps some of the new Core Audio APIs. The console project therein enumerates active audio sessions and lets you tweak volume and mute status of an active audio session.

    0 讨论(0)
提交回复
热议问题