Solved

Question for Chensu

Posted on 1998-06-02
5
203 Views
Last Modified: 2013-12-03
Hi Chensu!
I'd like to ask in continue of my previous question.
In mixer WaveInput/MixerList there are a few items.
The function mixerGetControlDetails() returns or its values
or its text descriptions.
How I can know what item is the "microphone select".
To use text descriptions is not safe because I think
text descriptions can be or non-standard or not in English.
Thanks, Vladimir_12345
 
0
Comment
Question by:vladimir_12345
  • 3
  • 2
5 Comments
 
LVL 23

Accepted Solution

by:
chensu earned 20 total points
ID: 1406113
When you use mixerGetControlDetails to get the text labels with the MIXER_GETCONTROLDETAILSF_LISTTEXT flag, the MIXERCONTROLDETAILS_LISTTEXT structure returns not only the text but also the dwLineID (the dwParam1 member) which the control is for. Use this dwLineID to compare with the dwLineID you get from mixerGetLineInfo (MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE).
0
 
LVL 1

Author Comment

by:vladimir_12345
ID: 1406114
Hi Chensu, thanks for your idea.
But it need in more accurate definition.
mixerGetLineInfo (MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE) returns
microphone line id for DST Speakers.
But mixerGetControlDetails (MIXERCONTROLDETAILS_LISTTEXT) returns
line ids for DST WaveInput.
If call mixerGetLineInfo() for every line ids from
mixerGetControlDetails (MIXERCONTROLDETAILS_LISTTEXT)
and to compare dwComponentType with MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE
it is possible to find "microphone select".
Chensu, from where you know so many about sound cards?
My e-mail: vladimir@comfy.co.il
Thanks again, Vladimir_12345

0
 
LVL 23

Expert Comment

by:chensu
ID: 1406115
Yes, you are right. Thank you for correcting me. Let me refine it.

There are normally two (or more) MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE source audio lines. One is for MIXERLINE_COMPONENTTYPE_DST_SPEAKERS destination audio line and another is for MIXERLINE_COMPONENTTYPE_DST_WAVEIN destination audio line. mixerGetLineInfo(MIXER_GETLINEINFOF_COMPONENTTYPE, MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE) only returns the information about the first audio line of the type MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE. So, call mixerGetLineInfo(MIXER_GETLINEINFOF_LINEID, dwLineID) to get the dwComponentType and compare it with MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE. The dwLineID is obtained from the dwParam1 member returned by mixerGetControlDetails (MIXERCONTROLDETAILS_LISTTEXT).

My knowledge about sound cards is just average. I am just interested in it.
0
 
LVL 1

Author Comment

by:vladimir_12345
ID: 1406116
Hi Chensu! To finish with the mixer discussion what do you
think: first audio line MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE
is always in MIXERLINE_COMPONENTTYPE_DST_SPEAKERS (if it's present)or not? It is impossible to say that there is too many mixer info in help.



0
 
LVL 23

Expert Comment

by:chensu
ID: 1406117
I think it depends on the device driver. It is not compulsory although most of the device drivers do so.
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

This article describes how to add a user-defined command button to the Windows 7 Explorer toolbar.  In the previous article (http://www.experts-exchange.com/A_2172.html), we saw how to put the Delete button back there where it belongs.  "Delete" is …
This article surveys and compares options for encoding and decoding base64 data.  It includes source code in C++ as well as examples of how to use standard Windows API functions for these tasks. We'll look at the algorithms — how encoding and decodi…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now