简体   繁体   中英

where in registry can i find different parts of audio device name

I need to change some properties of the an audio device in my c++ code(on window 7) where the only input I am getting is a Device Name coming from flash player(the name is same as that shown in the recording devices list which we get from right clicking the speaker icon).


Now say there is this device named "Microphone ( 2 - USB Audio Device)" . I am able to check the USB Audio Device and Microphone part from values of the registry key: HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\MMDevices\\Audio\\Capture\\someKindOfDeviceId\\Properties

"Now what I don't get is where from are these '2' or '3' are coming in these names."

I have to find a match to the device name in the registry and that's why this becomes so very necessary. please help. thanks in advance.

I found how the numbers are assigned but am not able to proceed further.
Actually when we plug a device(say usb pnp device), driver is installed and if it is the first time the device is installed then this port is numbered 1.
Now say we unplug this device and plug it in some other port(usb), again the driver will be installed and our this port will get number 2.
and so on..
Now whenever we plug the device, the number in the name is decided by the fact that 'when the driver was installed ie when the device was first used with this pin..."did we already use this with other ports and is yes then how many?".

But the question that still remains is which value in audio/capture represents this number so that we can match it against the input device name?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM