0

Is there any way to monitor microphone changes (plug in and plug out events)? Shouldn't matter if the mic is bluetooth / usb / or plugged directly to sound card. Application is built with C# but if there isn't any good way to get the events using C# then C++/CLI might be also option.

RassK
  • 475
  • 4
  • 19

2 Answers2

0

This link may help:

http://blogs.msdn.com/b/coding4fun/archive/2009/10/08/9905168.aspx

The post includes instructions on capturing the microphone level, etc.

Original post. Microphone Input

EDIT: Blog moved here: https://channel9.msdn.com/coding4fun/articles/NET-Voice-Recorder

Nir Maoz
  • 33
  • 1
  • 5
Kᴀτᴢ
  • 2,020
  • 4
  • 24
  • 47
0

I found also IMMNotificationClient from WASAPI which should work. Seems NAudio is not exposing this, but after customization I'm able to use it and get plugin / plugout events. Although it doesn't seem really stable - duplicated events / missing events and etc. Is there any proper implementation example in managed level?

Interface description :: IMMNotificationClient interface

RassK
  • 475
  • 4
  • 19