changeset 4361:3cd896ac4d49

indentation to stop eyes from bleeding
author mf0102 <0102@gmx.at>
date Tue, 18 Mar 2008 15:05:34 +0100
parents 313dd79a2d24
children 0ea092cbb49f
files src/audacious/visualization.c
diffstat 1 files changed, 40 insertions(+), 38 deletions(-) [+]
line wrap: on
line diff
--- a/src/audacious/visualization.c	Tue Mar 18 14:57:10 2008 +0100
+++ b/src/audacious/visualization.c	Tue Mar 18 15:05:34 2008 +0100
@@ -74,10 +74,10 @@
     for (node = vp_data.enabled_list; node; node = g_list_next(node)) {
         vp = node->data;
         if (vp->playback_start)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->playback_start();
-	}
+        }
     }
     vp_data.playback_started = TRUE;
 }
@@ -94,10 +94,10 @@
     for (node = vp_data.enabled_list; node; node = g_list_next(node)) {
         vp = node->data;
         if (vp->playback_stop)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->playback_stop();
-	}
+        }
     }
     vp_data.playback_started = FALSE;
 }
@@ -115,28 +115,28 @@
     if (enable && !vp->enabled) {
         vp_data.enabled_list = g_list_append(vp_data.enabled_list, vp);
         if (vp->init)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->init();
-	}
+        }
         if (playback_get_playing() && vp->playback_start)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->playback_start();
-	}
+        }
     }
     else if (!enable && vp->enabled) {
         vp_data.enabled_list = g_list_remove(vp_data.enabled_list, vp);
         if (playback_get_playing() && vp->playback_stop)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->playback_stop();
-	}
+        }
         if (vp->cleanup)
-	{
+        {
             plugin_set_current((Plugin *)vp);
             vp->cleanup();
-	}
+        }
     }
 
     vp->enabled = enable;
@@ -180,15 +180,15 @@
                 vp_data.enabled_list =
                     g_list_append(vp_data.enabled_list, vp);
                 if (vp->init)
-		{
+                {
                     plugin_set_current((Plugin *)vp);
                     vp->init();
-		}
+                }
                 if (playback_get_playing() && vp->playback_start)
-		{
+                {
                     plugin_set_current((Plugin *)vp);
                     vp->playback_start();
-		}
+                }
                 vp->enabled = TRUE;
             }
             g_free(base);
@@ -301,7 +301,7 @@
                     calc_mono_pcm(mono_pcm, pcm_data, nch);
                     mono_pcm_calced = TRUE;
                 }
-		plugin_set_current((Plugin *)vp);
+                plugin_set_current((Plugin *)vp);
                 vp->render_pcm(mono_pcm);
             }
             else {
@@ -309,7 +309,7 @@
                     calc_stereo_pcm(stereo_pcm, pcm_data, nch);
                     stereo_pcm_calced = TRUE;
                 }
-		plugin_set_current((Plugin *)vp);
+                plugin_set_current((Plugin *)vp);
                 vp->render_pcm(stereo_pcm);
             }
         }
@@ -319,7 +319,7 @@
                     calc_mono_freq(mono_freq, pcm_data, nch);
                     mono_freq_calced = TRUE;
                 }
-		plugin_set_current((Plugin *)vp);
+                plugin_set_current((Plugin *)vp);
                 vp->render_freq(mono_freq);
             }
             else {
@@ -327,7 +327,7 @@
                     calc_stereo_freq(stereo_freq, pcm_data, nch);
                     stereo_freq_calced = TRUE;
                 }
-		plugin_set_current((Plugin *)vp);
+                plugin_set_current((Plugin *)vp);
                 vp->render_freq(stereo_freq);
             }
         }
@@ -430,24 +430,26 @@
             else
                 intern_vis_data[1] = intern_vis_data[0];
         }
-	else{ /*Voiceprint*/
-	  if (!mono_freq_calced)
-	    calc_mono_freq(mono_freq, pcm_data, nch);
-	  memset(intern_vis_data, 0, 256);
-	  /* For the values [0-16] we use the frequency that's 3/2 as much.
-	  If we assume the 512 values calculated by calc_mono_freq to cover 0-22kHz linearly
-	  we get a range of [0-16] * 3/2 * 22000/512 = [0-1,031] Hz.
-	  Most stuff above that is harmonics and we want to utilize the 16 samples we have
-	  to the max[tm]
-	  */
-	  for(i = 0; i < 50 ; i+=3){
-	    intern_vis_data[i/3] += (mono_freq[0][i/2] >> 5);
-	    
-	    /*Boost frequencies above 257Hz a little*/
-	    //if(i > 4 * 3)
-	    //  intern_vis_data[i/3] += 8;
-	  }
-	}
+        else { /*Voiceprint*/
+            if (!mono_freq_calced)
+                calc_mono_freq(mono_freq, pcm_data, nch);
+            memset(intern_vis_data, 0, 256);
+
+            /* For the values [0-16] we use the frequency that's 3/2 as much.
+               If we assume the 512 values calculated by calc_mono_freq to
+               cover 0-22kHz linearly we get a range of
+               [0-16] * 3/2 * 22000/512 = [0-1,031] Hz.
+               Most stuff above that is harmonics and we want to utilize the
+               16 samples we have to the max[tm]
+               */
+            for (i = 0; i < 50 ; i+=3){
+                intern_vis_data[i/3] += (mono_freq[0][i/2] >> 5);
+
+                /*Boost frequencies above 257Hz a little*/
+                //if(i > 4 * 3)
+                //  intern_vis_data[i/3] += 8;
+            }
+        }
     }
     else { /* (cfg.vis_type == VIS_SCOPE) */