aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authortobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2010-06-06 08:23:22 +0000
committertobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2010-06-06 08:23:22 +0000
commitd35ae3cd792d22766f56c8210781148c36c9ae62 (patch)
tree03098700df2827f9effbf41692a68e14311d85a4 /src
parenta33a2cee108eae94dc979b2dc2e9e822bedf035e (diff)
downloadusdx-d35ae3cd792d22766f56c8210781148c36c9ae62.tar.gz
usdx-d35ae3cd792d22766f56c8210781148c36c9ae62.tar.xz
usdx-d35ae3cd792d22766f56c8210781148c36c9ae62.zip
Do not overwrite a devices MicSource if it is already set (Note: MicSource is not used at the moment)
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@2447 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to '')
-rw-r--r--src/media/UAudioInput_Bass.pas7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/media/UAudioInput_Bass.pas b/src/media/UAudioInput_Bass.pas
index b8f914c5..0e79b343 100644
--- a/src/media/UAudioInput_Bass.pas
+++ b/src/media/UAudioInput_Bass.pas
@@ -471,9 +471,12 @@ begin
Flags := BASS_RecordGetInput(SourceIndex, PSingle(nil)^);
if (Flags <> -1) then
begin
- // is the current source a mic-source?
- if ((Flags and BASS_INPUT_TYPE_MIC) <> 0) then
+ // chech if current source is a mic (and none was set before)
+ if ((Flags and BASS_INPUT_TYPE_MIC) <> 0) and
+ (BassDevice.MicSource = -1) then
+ begin
BassDevice.MicSource := SourceIndex;
+ end;
end;
Inc(SourceIndex);