[Core, mod_conference] Fixed oscillation in conference AGC processing. Especially during volume reduction processing (#1064)

* Fixed oscillation in conference AGC processing. Especially during volume reduction processing

* Re-scaled granular volume to +/- 50 dB level change. 10 = double loudness, -10 = half loudness, 0 = no change

Co-authored-by: Chris Rienzo <chris@signalwire.com>
This commit is contained in:
figaro2015
2021-04-02 12:18:16 -07:00
committed by GitHub
parent 67cec5c3e8
commit ec1a0215fe
4 changed files with 35 additions and 22 deletions
+4 -3
View File
@@ -1,6 +1,6 @@
/*
* FreeSWITCH Modular Media Switching Software Library / Soft-Switch Application
* Copyright (C) 2005-2014, Anthony Minessale II <anthm@freeswitch.org>
* Copyright (C) 2005-2021, Anthony Minessale II <anthm@freeswitch.org>
*
* Version: MPL 1.1
*
@@ -26,7 +26,7 @@
* Anthony Minessale II <anthm@freeswitch.org>
*
*
* switch_caller.h -- Caller Identification
* switch_resample.h
*
*/
/*! \file switch_resample.h
@@ -39,7 +39,8 @@
*/
#define switch_normalize_volume(x) if (x > 4) x = 4; if (x < -4) x = -4;
#define switch_normalize_volume_granular(x) if (x > 13) x = 13; if (x < -13) x = -13;
#define SWITCH_GRANULAR_VOLUME_MAX 50
#define switch_normalize_volume_granular(x) if (x > SWITCH_GRANULAR_VOLUME_MAX) x = SWITCH_GRANULAR_VOLUME_MAX; if (x < -SWITCH_GRANULAR_VOLUME_MAX) x = -SWITCH_GRANULAR_VOLUME_MAX;
#ifndef SWITCH_RESAMPLE_H
#define SWITCH_RESAMPLE_H