Changeset c0b295c


Ignore:
Timestamp:
Oct 2, 2009, 2:05:23 AM (14 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
Children:
acf7d30
Parents:
38e9732
Message:

src/mathutils.c: rename fvec_dc_removal to fvec_min_removal

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/mathutils.c

    r38e9732 rc0b295c  
    181181}
    182182
    183 void fvec_dc_removal(fvec_t * mag) {
    184     smpl_t mini = 0.;
    185     uint_t length = mag->length, i=0, j;
    186     mini = fvec_min(mag);
    187     for (j=0;j<length;j++) {
     183void
     184fvec_min_removal (fvec_t * o)
     185{
     186  uint_t i, j;
     187  smpl_t mini = fvec_min (mag);
     188  for (i = 0; i < o->channels; i++) {
     189    for (j = 0; j < o->length; j++) {
    188190      mag->data[i][j] -= mini;
    189191    }
     192  }
    190193}
    191194
  • src/mathutils.h

    r38e9732 rc0b295c  
    120120 */
    121121smpl_t fvec_alpha_norm(fvec_t * DF, smpl_t alpha);
    122 /**  dc(min) removal */
    123 void fvec_dc_removal(fvec_t * mag);
     122/**  min removal */
     123void fvec_min_removal(fvec_t * mag);
    124124/**  alpha normalisation */
    125125void fvec_alpha_normalise(fvec_t * mag, uint_t alpha);
  • src/pitch/pitchmcomb.c

    r38e9732 rc0b295c  
    159159    mag->data[i][j] = newmag->data[i][j];
    160160  }
    161   fvec_dc_removal(mag);               /* dc removal           */
     161  fvec_min_removal(mag);              /* min removal          */
    162162  fvec_alpha_normalise(mag,p->alpha); /* alpha normalisation  */
    163   /* skipped */                      /* low pass filtering   */
     163  /* skipped */                       /* low pass filtering   */
    164164  /** \bug fvec_moving_thres may write out of bounds */
    165165  fvec_adapt_thres(mag,tmp,p->win_post,p->win_pre); /* adaptative threshold */
  • swig/aubio.i

    r38e9732 rc0b295c  
    140140smpl_t fvec_local_hfc(fvec_t * f);
    141141smpl_t fvec_alpha_norm(fvec_t * DF, smpl_t alpha);
    142 void fvec_dc_removal(fvec_t * mag);
     142void fvec_min_removal(fvec_t * mag);
    143143void fvec_alpha_normalise(fvec_t * mag, uint_t alpha);
    144144void fvec_add(fvec_t * mag, smpl_t threshold);
Note: See TracChangeset for help on using the changeset viewer.