C#: Handling Multiple Keyboards and Multiple Microphones in the Same Software #Root

Brought from our old-site: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1048&title=C#:%20Handling%20Multiple%20Keyboards%20and%20Multiple%20Microphones%20in%20the%20Same%20Software

I was working for software that needed multiple keyboards support along with multiple microphones support; sure in C#, Visual Studio, and MS Access Database.

Multiple keyboards Support:

Detecting multiple keyboards/devices:
GetRawInputDeviceList( IntPtr.Zero, ref deviceCount, (uint)dwSize ) returns the number of devices detected

You can get a project that detects multiple keyboards and stores the devices in a HashTable at: http://www.codeproject.com/KB/system/rawinput.aspx#_Toc156395978

Multiple Microphones


Also, I had to provide support for multiple microphones. You can use the following function to collect speech from a microphone. The first parameter can be 0, 1, 2 for multiple microphones [device identification number]. If you put -1, it will take the default microphone.

m_Recorder = new WaveLib.WaveInRecorder(-1, fmt, 16384, 3, new WaveLib.BufferDoneEventHandler(DataArrived));

Just check the following article for the details:
http://www.codeproject.com/KB/audio-video/cswavrec.aspx

From: http://sitestree.com/?p=3759
Categories:Root
Tags:
Post Data:2016-07-17 13:08:08

Shop Online: https://www.ShopForSoul.com/
(Big Data, Cloud, Security, Machine Learning): Courses: http://Training.SitesTree.com
In Bengali: http://Bangla.SaLearningSchool.com
http://SitesTree.com
8112223 Canada Inc./JustEtc: http://JustEtc.net (Software/Web/Mobile/Big-Data/Machine Learning)
Shop Online: https://www.ShopForSoul.com/
Medium: https://medium.com/@SayedAhmedCanada