From: <sb...@us...> - 2007-06-05 19:56:24
|
Revision: 1001 http://svn.sourceforge.net/iaxclient/?rev=1001&view=rev Author: sbalea Date: 2007-06-05 12:56:22 -0700 (Tue, 05 Jun 2007) Log Message: ----------- Fixed Microphone Boost on Lenovo desktops with "soundmax hd" audio hardware. It appears that Mic Boost controls are not always MIXERCONTROL_CONTROLTYPE_ONOFF In this case, the control was MIXERCONTROL_CONTROLTYPE_LOUDNESS. Anyway, the control is of the more general "BOOLEAN" type so we test for that. Combined with the existing test for "MIC" and "BOOST", we should get the correct mic boost control, if one is available. Modified Paths: -------------- trunk/lib/portmixer/px_win_wmme/px_win_wmme.c Modified: trunk/lib/portmixer/px_win_wmme/px_win_wmme.c =================================================================== --- trunk/lib/portmixer/px_win_wmme/px_win_wmme.c 2007-06-05 19:12:24 UTC (rev 1000) +++ trunk/lib/portmixer/px_win_wmme/px_win_wmme.c 2007-06-05 19:56:22 UTC (rev 1001) @@ -36,6 +36,7 @@ */ #include <windows.h> +#include <stdio.h> #include "portaudio.h" #include "portmixer.h" @@ -683,7 +684,7 @@ for ( ; x < mixerLineControls.cControls ; ++x ) { // check control type - if ( mixerControl[x].dwControlType == MIXERCONTROL_CONTROLTYPE_ONOFF ) + if ( mixerControl[x].dwControlType & MIXERCONTROL_CONTROLTYPE_BOOLEAN ) { // normalize control name char* name = _strupr( mixerControl[x].szName ) ; @@ -807,7 +808,7 @@ for ( ; x < mixerLineControls.cControls ; ++x ) { // check control type - if ( mixerControl[x].dwControlType == MIXERCONTROL_CONTROLTYPE_ONOFF ) + if ( mixerControl[x].dwControlType & MIXERCONTROL_CONTROLTYPE_BOOLEAN ) { // normalize control name char* name = _strupr( mixerControl[x].szName ) ; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |