Commit b76cf6a5 authored by aymeric's avatar aymeric
Browse files

keep more history in value

let the user choose between linear and db for energy

git-svn-id: svn+ssh:// 3f6dc0c8-ddfe-455d-9043-3cd528dc4637
parent 89d2e587
......@@ -43,7 +43,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
static const float max_e=(float)32767*32767;
static const float coef=(float)0.1;
static const float coef=(float)0.01;
typedef struct Channel{
MSBufferizer buff;
......@@ -400,7 +400,7 @@ static void conf_sum(MSFilter *f, ConfState *s){
en=(s*s*coef) + ((float)1.0-coef)*en;
chan->energy=en; = 10*log10f(chan->energy/max_e); = chan->energy; //10*log10f(chan->energy/max_e); = i;
ms_filter_notify(f, MS_CONF_CHANNEL_VOLUME, (void*)&vol);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment