[FFmpeg-cvslog] sonicenc: dont put multiple assignments per line

Michael Niedermayer git at videolan.org
Wed Jun 19 10:39:51 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Jun 19 10:06:10 2013 +0200| [694c2d1ab3a870b2a27aaab526f0040f1119c235] | committer: Michael Niedermayer

sonicenc: dont put multiple assignments per line

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=694c2d1ab3a870b2a27aaab526f0040f1119c235
---

 libavcodec/sonic.c |   15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/libavcodec/sonic.c b/libavcodec/sonic.c
index a8cd93a..512e89e 100644
--- a/libavcodec/sonic.c
+++ b/libavcodec/sonic.c
@@ -427,18 +427,21 @@ static void modified_levinson_durbin(int *window, int window_entries,
         int step = (i+1)*channels, k, j;
         double xx = 0.0, xy = 0.0;
 #if 1
-        int *x_ptr = &(window[step]), *state_ptr = &(state[0]);
+        int *x_ptr = &(window[step]);
+        int *state_ptr = &(state[0]);
         j = window_entries - step;
         for (;j>=0;j--,x_ptr++,state_ptr++)
         {
-            double x_value = *x_ptr, state_value = *state_ptr;
+            double x_value = *x_ptr;
+            double state_value = *state_ptr;
             xx += state_value*state_value;
             xy += x_value*state_value;
         }
 #else
         for (j = 0; j <= (window_entries - step); j++);
         {
-            double stepval = window[step+j], stateval = window[j];
+            double stepval = window[step+j];
+            double stateval = window[j];
 //            xx += (double)window[j]*(double)window[j];
 //            xy += (double)window[step+j]*(double)window[j];
             xx += stateval*stateval;
@@ -464,14 +467,16 @@ static void modified_levinson_durbin(int *window, int window_entries,
         j = window_entries - step;
         for (;j>=0;j--,x_ptr++,state_ptr++)
         {
-            int x_value = *x_ptr, state_value = *state_ptr;
+            int x_value = *x_ptr;
+            int state_value = *state_ptr;
             *x_ptr = x_value + shift_down(k*state_value,LATTICE_SHIFT);
             *state_ptr = state_value + shift_down(k*x_value, LATTICE_SHIFT);
         }
 #else
         for (j=0; j <= (window_entries - step); j++)
         {
-            int stepval = window[step+j], stateval=state[j];
+            int stepval = window[step+j];
+            int stateval=state[j];
             window[step+j] += shift_down(k * stateval, LATTICE_SHIFT);
             state[j] += shift_down(k * stepval, LATTICE_SHIFT);
         }



More information about the ffmpeg-cvslog mailing list