From 836ea71ea1659699524649fab91aed7579cac672 Mon Sep 17 00:00:00 2001 From: "Ronald S. Bultje" Date: Sun, 28 Nov 2004 19:22:07 +0000 Subject: [PATCH] gst/audioconvert/gstchannelmix.c: Normalize using absolute values. Original commit message from CVS: * gst/audioconvert/gstchannelmix.c: (gst_audio_convert_fill_normalize): Normalize using absolute values. --- ChangeLog | 6 ++++++ gst/audioconvert/gstchannelmix.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 1d88d9300e..070ab4ad12 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-11-28 Ronald S. Bultje + + * gst/audioconvert/gstchannelmix.c: + (gst_audio_convert_fill_normalize): + Normalize using absolute values. + 2004-11-28 Julien MOUTTE * configure.ac: diff --git a/gst/audioconvert/gstchannelmix.c b/gst/audioconvert/gstchannelmix.c index 705cfad587..f78acf2d78 100644 --- a/gst/audioconvert/gstchannelmix.c +++ b/gst/audioconvert/gstchannelmix.c @@ -438,7 +438,7 @@ gst_audio_convert_fill_normalize (GstAudioConvert * this) /* calculate sum */ sum = 0.0; for (i = 0; i < this->sinkcaps.channels; i++) { - sum += this->matrix[i][j]; + sum += fabs (this->matrix[i][j]); } if (sum > top) { top = sum;