[SCM] calf/master: Merge branch 'line-graph' into analyzer

js at users.alioth.debian.org js at users.alioth.debian.org
Tue May 7 15:41:02 UTC 2013


all get_graph with mode
Merge branch 'analyzer' of boomshop.net:/home/calf/calf into line-graph
some bugfixes
Merge branch 'analyzer' into line-graph
no hold with stgereo image
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
X-Git-Refname: refs/heads/master
X-Git-Reftype: branch
X-Git-Oldrev: d6a3c1a63a147948535a50da009275278ad5e6a3
X-Git-Newrev: 34569260c452f0fa4c543155ebba174a42a343dc

The following commit has been merged in the master branch:
commit 0cf88b195a52e685775e2ae2887e7d2aabfef9b1
Merge: 7e2509c3f88a85ee36a08467c6ceff5f8edf6b19 642407621aa132f98e938f842322ca292861c167
Author: Christian Holschuh <chrisch.holli at gmx.de>
Date:   Tue Mar 6 13:37:30 2012 +0100

    Merge branch 'line-graph' into analyzer

diff --combined src/modules.cpp
index f49607e,952776f..1b7af4a
--- a/src/modules.cpp
+++ b/src/modules.cpp
@@@ -306,7 -306,7 +306,7 @@@ uint32_t vintage_delay_audio_module::pr
  
  ///////////////////////////////////////////////////////////////////////////////////////////////
  
- bool filter_audio_module::get_graph(int index, int subindex, float *data, int points, cairo_iface *context) const
+ bool filter_audio_module::get_graph(int index, int subindex, float *data, int points, cairo_iface *context, int *mode) const
  {
      if (!is_active)
          return false;
@@@ -436,7 -436,7 +436,7 @@@ void filterclavier_audio_module::adjust
      }
  }
  
- bool filterclavier_audio_module::get_graph(int index, int subindex, float *data, int points, cairo_iface *context) const
+ bool filterclavier_audio_module::get_graph(int index, int subindex, float *data, int points, cairo_iface *context, int *mode) const
  {
      if (!is_active || index != par_mode) {
          return false;
@@@ -1065,6 -1065,15 +1065,6 @@@ bool analyzer_audio_module::get_graph(i
                      fft_hold[i] = fft_out[i];
                  }
              }
 -            for(int k = 0; k < 1; true) {
 -                //hier auf richtigen plan prüfen
 -                if(true) {
 -                    break;
 -                }
 -                // recreate fftw plan
 -                rfftw_destroy_plan (fft_plan);
 -                fft_plan = rfftw_create_plan(_accuracy, FFTW_FORWARD, 0);
 -            }            
              
              // run fft
              // this takes our latest buffer and returns an array with
@@@ -1121,10 -1130,6 +1121,10 @@@
                      break;
                      case 2:
                          for(int k = 0; k < std::max(10 , std::min(400 , (int)(2.f*(float)((_iter - iter))))); k++) {
 +                            
 +                            //collect amplitudes in the environment of _iter to
 +                            //be able to erase them from signal and leave just
 +                            //the peaks
                              if(_iter - k > 0) {
                                  var1 += fabs(fft_out[_iter - k]);
                                  n++;
@@@ -1134,21 -1139,18 +1134,21 @@@
                              else var1 += fabs(fft_out[_iter]);
                              n++;
                          }
 +                        //do not forget fft_out[_iter] for the next time
                          lastout = fft_out[_iter];
 +                        //pumping up actual signal an erase surrounding sounds
                          fft_out[_iter] = std::max(n * fabs(fft_out[_iter]) - var1 , 1e-20);
                      break;
                      case 3:
                          if(fftdone and i) {
 -                            // if fft was renewed, recalc the absolute values if frequencies
 -                            // are skipped
 +                            // if fft was renewed, recalc the absolute values in left and right 
 +                            // if frequencies are skipped
                              for(int j = iter + 1; j < _iter; j++) {
                                  fft_out[_iter] += fabs(fft_out[j]);
                                  fft_outR[_iter] += fabs(fft_outR[j]);
                              }
                          }
 +                        //calculate difference between left an right channel                        
                          float diff_fft;
                          diff_fft = fabs(fft_out[_iter]) - fabs(fft_outR[_iter]);
                          posneg = fabs(diff_fft) / diff_fft;
@@@ -1194,7 -1196,6 +1194,7 @@@
                  // fill freeze buffer
                  fft_freeze[iter] = val;
              }
 +            //send values to painting
              data[i] = dB_grid(fabs(val) / _accuracy * 2.f + 1e-20, pow(64, *params[param_analyzer_level]), 0.5f);
              if(*params[param_analyzer_mode] == 3) {
                  if(i) {

-- 
calf audio plugins packaging



More information about the pkg-multimedia-commits mailing list