Skip to content

Commit

Permalink
Modify WebRTC gaincontroller2, remove level estimation, remove VAD
Browse files Browse the repository at this point in the history
This is necessary to update from r4332 to r6818.

Modifies WebRTCAudioPreprocessor::gaincontroller2:

struct
{
    TTBOOL bEnable;
    float fInitialSaturationMarginDB;
    float fExtraSaturationMarginDB;
    float fMaxGainChangeDBPerSecond;
    float fMaxOutputNoiseLevelDBFS;
} adaptivedigital;

By:

struct
{
    TTBOOL bEnable;
    float fHeadRoomDB;
    float fMaxGainDB;
    float fInitialGainDB;
    float fMaxGainChangeDBPerSecond;
    float fMaxOutputNoiseLevelDBFS;
} adaptivedigital;
  • Loading branch information
bear101 committed Dec 3, 2024
1 parent 79652f8 commit 97908aa
Show file tree
Hide file tree
Showing 26 changed files with 160 additions and 362 deletions.
13 changes: 2 additions & 11 deletions Client/TeamTalkClassic/TeamTalkBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,16 +92,7 @@ AudioPreprocessor InitDefaultAudioPreprocessor(AudioPreprocessorType preprocesso
preprocessor.ttpreprocessor.bMuteLeftSpeaker = preprocessor.ttpreprocessor.bMuteRightSpeaker = FALSE;
break;
case WEBRTC_AUDIOPREPROCESSOR:
preprocessor.webrtc.gaincontroller2.bEnable = DEFAULT_WEBRTC_GAINCTL_ENABLE;
preprocessor.webrtc.gaincontroller2.fixeddigital.fGainDB = DEFAULT_WEBRTC_GAINDB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.bEnable = DEFAULT_WEBRTC_SAT_PROT_ENABLE;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialSaturationMarginDB = DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fExtraSaturationMarginDB = DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainChangeDBPerSecond = DEFAULT_WEBRTC_MAXGAIN_DBSEC;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxOutputNoiseLevelDBFS = DEFAULT_WEBRTC_MAX_OUT_NOISE;
preprocessor.webrtc.noisesuppression.bEnable = DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE;
preprocessor.webrtc.noisesuppression.nLevel = DEFAULT_WEBRTC_NOISESUPPRESS_LEVEL;
preprocessor.webrtc.echocanceller.bEnable = DEFAULT_WEBRTC_ECHO_CANCEL_ENABLE;
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
break;
}
return preprocessor;
Expand Down Expand Up @@ -338,4 +329,4 @@ void UserCached::Sync(TTInstance* ttInst, const User& user)
TT_PumpMessage(ttInst, CLIENTEVENT_USER_STATECHANGE, user.nUserID);

TRACE(_T("Restored ") + UserCacheID(user) + _T("\n"));
}
}
16 changes: 7 additions & 9 deletions Client/iTeamTalk/iTeamTalk/UtilTT.swift
Original file line number Diff line number Diff line change
Expand Up @@ -181,14 +181,13 @@ let DEFAULT_SPEEXDSP_ECHO_SUPPRESSACTIVE = INT32(-15)

let DEFAULT_WEBRTC_PREAMPLIFIER_ENABLE = FALSE
let DEFAULT_WEBRTC_PREAMPLIFIER_GAINFACTOR = Float(1)
let DEFAULT_WEBRTC_VAD_ENABLE = FALSE
let DEFAULT_WEBRTC_LEVELESTIMATION_ENABLE = FALSE
let DEFAULT_WEBRTC_GAINCTL_ENABLE = DEFAULT_AGC_ENABLE
let DEFAULT_WEBRTC_GAINDB = Float(15)
let DEFAULT_WEBRTC_SAT_PROT_ENABLE = TRUE
let DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB = Float(20)
let DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB = Float(2)
let DEFAULT_WEBRTC_MAXGAIN_DBSEC = Float(3)
let DEFAULT_WEBRTC_HEADROOM_DB = Float(5)
let DEFAULT_WEBRTC_MAXGAIN_DB = Float(50)
let DEFAULT_WEBRTC_INITIAL_GAIN_DB = Float(15)
let DEFAULT_WEBRTC_MAXGAIN_DBSEC = Float(6)
let DEFAULT_WEBRTC_MAX_OUT_NOISE = Float(-50)
let DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE = DEFAULT_DENOISE_ENABLE
let DEFAULT_WEBRTC_NOISESUPPRESS_LEVEL = INT32(2)
Expand Down Expand Up @@ -295,15 +294,14 @@ func newAudioPreprocessor(preprocessor: AudioPreprocessorType) -> AudioPreproces
ap.webrtc.echocanceller.bEnable = DEFAULT_WEBRTC_ECHO_CANCEL_ENABLE
ap.webrtc.noisesuppression.bEnable = DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE
ap.webrtc.noisesuppression.nLevel = DEFAULT_WEBRTC_NOISESUPPRESS_LEVEL
ap.webrtc.voicedetection.bEnable = DEFAULT_WEBRTC_VAD_ENABLE
ap.webrtc.gaincontroller2.bEnable = DEFAULT_WEBRTC_GAINCTL_ENABLE
ap.webrtc.gaincontroller2.fixeddigital.fGainDB = DEFAULT_WEBRTC_GAINDB
ap.webrtc.gaincontroller2.adaptivedigital.bEnable = DEFAULT_WEBRTC_SAT_PROT_ENABLE
ap.webrtc.gaincontroller2.adaptivedigital.fExtraSaturationMarginDB = DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB
ap.webrtc.gaincontroller2.adaptivedigital.fInitialSaturationMarginDB = DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB
ap.webrtc.gaincontroller2.adaptivedigital.fHeadRoomDB = DEFAULT_WEBRTC_HEADROOM_DB
ap.webrtc.gaincontroller2.adaptivedigital.fMaxGainDB = DEFAULT_WEBRTC_MAXGAIN_DB
ap.webrtc.gaincontroller2.adaptivedigital.fInitialGainDB = DEFAULT_WEBRTC_INITIAL_GAIN_DB
ap.webrtc.gaincontroller2.adaptivedigital.fMaxGainChangeDBPerSecond = DEFAULT_WEBRTC_MAXGAIN_DBSEC
ap.webrtc.gaincontroller2.adaptivedigital.fMaxOutputNoiseLevelDBFS = DEFAULT_WEBRTC_MAX_OUT_NOISE
ap.webrtc.levelestimation.bEnable = DEFAULT_WEBRTC_LEVELESTIMATION_ENABLE
case NO_AUDIOPREPROCESSOR :
fallthrough
default :
Expand Down
2 changes: 2 additions & 0 deletions Client/qtTeamTalk/audiopreprocessordlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ void AudioPreprocessorDlg::showSettings()
switch(m_preprocess.nPreprocessor)
{
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
ui.stackedWidget->setCurrentIndex(0);
setWindowTitle(tr("No Audio Preprocessor"));
break;
Expand Down Expand Up @@ -89,6 +90,7 @@ void AudioPreprocessorDlg::slotAccepted()
switch(m_preprocess.nPreprocessor)
{
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
break;
case SPEEXDSP_AUDIOPREPROCESSOR :
m_preprocess.speexdsp.bEnableAGC = ui.agcCheckBox->isChecked();
Expand Down
24 changes: 14 additions & 10 deletions Client/qtTeamTalk/common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -340,9 +340,10 @@ AudioPreprocessor loadAudioPreprocessor(AudioPreprocessorType preprocessortype)
AudioPreprocessor preprocessor = initDefaultAudioPreprocessor(preprocessortype);
switch (preprocessor.nPreprocessor)
{
case NO_AUDIOPREPROCESSOR:
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
break;
case SPEEXDSP_AUDIOPREPROCESSOR:
case SPEEXDSP_AUDIOPREPROCESSOR :
preprocessor.speexdsp.bEnableAGC = ttSettings->value(SETTINGS_STREAMMEDIA_SPX_AGC_ENABLE, DEFAULT_SPEEXDSP_AGC_ENABLE).toBool();
preprocessor.speexdsp.nGainLevel = ttSettings->value(SETTINGS_STREAMMEDIA_SPX_AGC_GAINLEVEL, DEFAULT_SPEEXDSP_AGC_GAINLEVEL).toInt();
preprocessor.speexdsp.nMaxIncDBSec = ttSettings->value(SETTINGS_STREAMMEDIA_SPX_AGC_INC_MAXDB, DEFAULT_SPEEXDSP_AGC_INC_MAXDB).toInt();
Expand All @@ -354,7 +355,7 @@ AudioPreprocessor loadAudioPreprocessor(AudioPreprocessorType preprocessortype)
preprocessor.speexdsp.nEchoSuppress = DEFAULT_SPEEXDSP_ECHO_SUPPRESS;
preprocessor.speexdsp.nEchoSuppressActive = DEFAULT_SPEEXDSP_ECHO_SUPPRESSACTIVE;
break;
case TEAMTALK_AUDIOPREPROCESSOR:
case TEAMTALK_AUDIOPREPROCESSOR :
preprocessor.ttpreprocessor.bMuteLeftSpeaker = ttSettings->value(SETTINGS_STREAMMEDIA_TTAP_MUTELEFT, false).toBool();
preprocessor.ttpreprocessor.bMuteRightSpeaker = ttSettings->value(SETTINGS_STREAMMEDIA_TTAP_MUTERIGHT, false).toBool();
preprocessor.ttpreprocessor.nGainLevel = ttSettings->value(SETTINGS_STREAMMEDIA_TTAP_GAINLEVEL, SOUND_GAIN_DEFAULT).toInt();
Expand All @@ -363,8 +364,9 @@ AudioPreprocessor loadAudioPreprocessor(AudioPreprocessorType preprocessortype)
preprocessor.webrtc.gaincontroller2.bEnable = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_GAINCTL_ENABLE, DEFAULT_WEBRTC_GAINCTL_ENABLE).toBool();
preprocessor.webrtc.gaincontroller2.fixeddigital.fGainDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_GAINDB, DEFAULT_WEBRTC_GAINDB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.bEnable = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_SAT_PROT_ENABLE, DEFAULT_WEBRTC_SAT_PROT_ENABLE).toBool();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialSaturationMarginDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_INIT_SAT_MARGIN_DB, DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fExtraSaturationMarginDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_EXTRA_SAT_MARGIN_DB, DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fHeadRoomDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_HEADROOM_DB, DEFAULT_WEBRTC_HEADROOM_DB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DB, DEFAULT_WEBRTC_MAXGAIN_DB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialGainDB = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_INITGAIN_DB, DEFAULT_WEBRTC_INITIAL_GAIN_DB).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainChangeDBPerSecond = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DBSEC, DEFAULT_WEBRTC_MAXGAIN_DBSEC).toFloat();
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxOutputNoiseLevelDBFS = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_MAX_OUT_NOISE, DEFAULT_WEBRTC_MAX_OUT_NOISE).toFloat();
preprocessor.webrtc.noisesuppression.bEnable = ttSettings->value(SETTINGS_STREAMMEDIA_WEBRTC_NOISESUPPRESS_ENABLE, DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE).toBool();
Expand All @@ -380,9 +382,10 @@ void saveAudioPreprocessor(const AudioPreprocessor& preprocessor)
ttSettings->setValue(SETTINGS_STREAMMEDIA_AUDIOPREPROCESSOR, preprocessor.nPreprocessor);
switch (preprocessor.nPreprocessor)
{
case NO_AUDIOPREPROCESSOR:
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
break;
case SPEEXDSP_AUDIOPREPROCESSOR:
case SPEEXDSP_AUDIOPREPROCESSOR :
ttSettings->setValue(SETTINGS_STREAMMEDIA_SPX_AGC_ENABLE, preprocessor.speexdsp.bEnableAGC);
ttSettings->setValue(SETTINGS_STREAMMEDIA_SPX_AGC_GAINLEVEL, preprocessor.speexdsp.nGainLevel);
ttSettings->setValue(SETTINGS_STREAMMEDIA_SPX_AGC_INC_MAXDB, preprocessor.speexdsp.nMaxIncDBSec);
Expand All @@ -391,7 +394,7 @@ void saveAudioPreprocessor(const AudioPreprocessor& preprocessor)
ttSettings->setValue(SETTINGS_STREAMMEDIA_SPX_DENOISE_ENABLE, preprocessor.speexdsp.bEnableDenoise);
ttSettings->setValue(SETTINGS_STREAMMEDIA_SPX_DENOISE_SUPPRESS, preprocessor.speexdsp.nMaxNoiseSuppressDB);
break;
case TEAMTALK_AUDIOPREPROCESSOR:
case TEAMTALK_AUDIOPREPROCESSOR :
ttSettings->setValue(SETTINGS_STREAMMEDIA_TTAP_MUTELEFT, preprocessor.ttpreprocessor.bMuteLeftSpeaker);
ttSettings->setValue(SETTINGS_STREAMMEDIA_TTAP_MUTERIGHT, preprocessor.ttpreprocessor.bMuteRightSpeaker);
ttSettings->setValue(SETTINGS_STREAMMEDIA_TTAP_GAINLEVEL, preprocessor.ttpreprocessor.nGainLevel);
Expand All @@ -400,8 +403,9 @@ void saveAudioPreprocessor(const AudioPreprocessor& preprocessor)
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_GAINCTL_ENABLE, preprocessor.webrtc.gaincontroller2.bEnable);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_GAINDB, preprocessor.webrtc.gaincontroller2.fixeddigital.fGainDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_SAT_PROT_ENABLE, preprocessor.webrtc.gaincontroller2.adaptivedigital.bEnable );
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_INIT_SAT_MARGIN_DB, preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialSaturationMarginDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_EXTRA_SAT_MARGIN_DB, preprocessor.webrtc.gaincontroller2.adaptivedigital.fExtraSaturationMarginDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_HEADROOM_DB, preprocessor.webrtc.gaincontroller2.adaptivedigital.fHeadRoomDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DB, preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_INITGAIN_DB, preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialGainDB);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DBSEC, preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainChangeDBPerSecond);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_MAX_OUT_NOISE, preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxOutputNoiseLevelDBFS);
ttSettings->setValue(SETTINGS_STREAMMEDIA_WEBRTC_NOISESUPPRESS_ENABLE, preprocessor.webrtc.noisesuppression.bEnable);
Expand Down
3 changes: 3 additions & 0 deletions Client/qtTeamTalk/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5522,6 +5522,7 @@ void MainWindow::changeMediaFileVolume(int pos)
m_mfp.audioPreprocessor.speexdsp.nGainLevel = pos;
break;
case WEBRTC_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
case NO_AUDIOPREPROCESSOR :
return;
}
Expand Down Expand Up @@ -6452,6 +6453,7 @@ void MainWindow::slotUpdateMediaTabUI()
break;
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
ui.mediaVolumeSlider->setEnabled(false);
ui.mediaVolumeSlider->setValue(0);
ui.mediaVolumeLabel->setText(tr("%1 %").arg(100));
Expand Down Expand Up @@ -7457,6 +7459,7 @@ void MainWindow::slotMicrophoneGainChanged(int value)
switch (preprocessor.nPreprocessor)
{
case NO_AUDIOPREPROCESSOR :
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
preprocessor = initDefaultAudioPreprocessor(NO_AUDIOPREPROCESSOR);
TT_SetSoundInputPreprocessEx(ttInst, &preprocessor);
TT_SetSoundInputGainLevel(ttInst, refGain(value));
Expand Down
11 changes: 6 additions & 5 deletions Client/qtTeamTalk/settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -507,11 +507,12 @@
#define SETTINGS_STREAMMEDIA_SPX_AGC_GAINMAXDB "stream-media/spxaudiopreprocessor/agc-gainmaxdb"
#define SETTINGS_STREAMMEDIA_SPX_DENOISE_ENABLE "stream-media/spxaudiopreprocessor/denoise-enable"
#define SETTINGS_STREAMMEDIA_SPX_DENOISE_SUPPRESS "stream-media/spxaudiopreprocessor/denoise-suppress"
#define SETTINGS_STREAMMEDIA_WEBRTC_GAINCTL_ENABLE "stream-media/webrtcaudiopreprocessor/gain-enable"
#define SETTINGS_STREAMMEDIA_WEBRTC_GAINDB "stream-media/webrtcaudiopreprocessor/gain-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_SAT_PROT_ENABLE "stream-media/webrtcaudiopreprocessor/sat-protection-enable"
#define SETTINGS_STREAMMEDIA_WEBRTC_INIT_SAT_MARGIN_DB "stream-media/webrtcaudiopreprocessor/init-sat-margin-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_EXTRA_SAT_MARGIN_DB "stream-media/webrtcaudiopreprocessor/extra-sat-margin-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_GAINCTL_ENABLE "stream-media/webrtcaudiopreprocessor/gain-enable"
#define SETTINGS_STREAMMEDIA_WEBRTC_GAINDB "stream-media/webrtcaudiopreprocessor/gain-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_SAT_PROT_ENABLE "stream-media/webrtcaudiopreprocessor/sat-protection-enable"
#define SETTINGS_STREAMMEDIA_WEBRTC_HEADROOM_DB "stream-media/webrtcaudiopreprocessor/headroom-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DB "stream-media/webrtcaudiopreprocessor/maxgain-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_INITGAIN_DB "stream-media/webrtcaudiopreprocessor/initial-gain-db"
#define SETTINGS_STREAMMEDIA_WEBRTC_MAXGAIN_DBSEC "stream-media/webrtcaudiopreprocessor/maxgain-dbsec"
#define SETTINGS_STREAMMEDIA_WEBRTC_MAX_OUT_NOISE "stream-media/webrtcaudiopreprocessor/max-out-noise"
#define SETTINGS_STREAMMEDIA_WEBRTC_NOISESUPPRESS_ENABLE "stream-media/webrtcaudiopreprocessor/noise-suppress-enable"
Expand Down
9 changes: 5 additions & 4 deletions Client/qtTeamTalk/utiltt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -200,16 +200,17 @@ AudioPreprocessor initDefaultAudioPreprocessor(AudioPreprocessorType preprocesso
preprocessor.ttpreprocessor.bMuteLeftSpeaker = DEFAULT_TEAMTALK_MUTELEFT;
preprocessor.ttpreprocessor.bMuteRightSpeaker = DEFAULT_TEAMTALK_MUTERIGHT;
break;
case WEBRTC_AUDIOPREPROCESSOR_OBSOLETE_R4332 :
break;
case WEBRTC_AUDIOPREPROCESSOR :
preprocessor.webrtc.preamplifier.bEnable = DEFAULT_WEBRTC_PREAMPLIFIER_ENABLE;
preprocessor.webrtc.preamplifier.fFixedGainFactor = DEFAULT_WEBRTC_PREAMPLIFIER_GAINFACTOR;
preprocessor.webrtc.levelestimation.bEnable = DEFAULT_WEBRTC_LEVELESTIMATION_ENABLE;
preprocessor.webrtc.voicedetection.bEnable = DEFAULT_WEBRTC_VAD_ENABLE;
preprocessor.webrtc.gaincontroller2.bEnable = DEFAULT_WEBRTC_GAINCTL_ENABLE;
preprocessor.webrtc.gaincontroller2.fixeddigital.fGainDB = DEFAULT_WEBRTC_GAINDB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.bEnable = DEFAULT_WEBRTC_SAT_PROT_ENABLE;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialSaturationMarginDB = DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fExtraSaturationMarginDB = DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fHeadRoomDB = DEFAULT_WEBRTC_HEADROOM_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fInitialGainDB = DEFAULT_WEBRTC_INITIAL_GAIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainDB = DEFAULT_WEBRTC_MAXGAIN_DB;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxGainChangeDBPerSecond = DEFAULT_WEBRTC_MAXGAIN_DBSEC;
preprocessor.webrtc.gaincontroller2.adaptivedigital.fMaxOutputNoiseLevelDBFS = DEFAULT_WEBRTC_MAX_OUT_NOISE;
preprocessor.webrtc.noisesuppression.bEnable = DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE;
Expand Down
17 changes: 10 additions & 7 deletions Client/qtTeamTalk/utiltt.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,18 @@ do { \

#define DEFAULT_WEBRTC_PREAMPLIFIER_ENABLE FALSE
#define DEFAULT_WEBRTC_PREAMPLIFIER_GAINFACTOR 1.0f
#define DEFAULT_WEBRTC_VAD_ENABLE FALSE
#define DEFAULT_WEBRTC_LEVELESTIMATION_ENABLE FALSE
/* gain controller 2 */
#define DEFAULT_WEBRTC_GAINCTL_ENABLE DEFAULT_AGC_ENABLE
#define DEFAULT_WEBRTC_GAINDB 15
/* gain controller 2 - fixed digital */
#define DEFAULT_WEBRTC_GAINDB 0.0f
/* gain controller 2 - adaptive digital */
#define DEFAULT_WEBRTC_SAT_PROT_ENABLE TRUE
#define DEFAULT_WEBRTC_INIT_SAT_MARGIN_DB 20
#define DEFAULT_WEBRTC_EXTRA_SAT_MARGIN_DB 2
#define DEFAULT_WEBRTC_MAXGAIN_DBSEC 3
#define DEFAULT_WEBRTC_MAX_OUT_NOISE -50
#define DEFAULT_WEBRTC_HEADROOM_DB 5.0f
#define DEFAULT_WEBRTC_MAXGAIN_DB 50.0f
#define DEFAULT_WEBRTC_INITIAL_GAIN_DB 15.0f
#define DEFAULT_WEBRTC_MAXGAIN_DBSEC 6.0f
#define DEFAULT_WEBRTC_MAX_OUT_NOISE -50.0f
/* noise suppression */
#define DEFAULT_WEBRTC_NOISESUPPRESS_ENABLE DEFAULT_DENOISE_ENABLE
#define DEFAULT_WEBRTC_NOISESUPPRESS_LEVEL 2
#define DEFAULT_WEBRTC_ECHO_CANCEL_ENABLE FALSE /* requires duplex mode */
Expand Down
Loading

0 comments on commit 97908aa

Please sign in to comment.