Changeset e4f142c for src/onset


Ignore:
Timestamp:
Oct 16, 2009, 9:56:26 PM (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:
7778f39
Parents:
d25bd12
Message:

src/onset/: use samplerate

Location:
src/onset
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/onset/onset.c

    rd25bd12 re4f142c  
    3838  uint_t minioi;                /**< minimum inter onset interval */
    3939  uint_t wasonset;              /**< number of frames since last onset */
     40  uint_t samplerate;            /**< sampling rate of the input signal */
    4041};
    4142
     
    9091/* Allocate memory for an onset detection */
    9192aubio_onset_t * new_aubio_onset (char_t * onset_mode,
    92     uint_t buf_size, uint_t hop_size, uint_t channels)
     93    uint_t buf_size, uint_t hop_size, uint_t channels, uint_t samplerate)
    9394{
    9495  aubio_onset_t * o = AUBIO_NEW(aubio_onset_t);
     
    9899  o->silence   = -70;
    99100  o->wasonset  = 0;
     101  o->samplerate = samplerate;
    100102  o->pv = new_aubio_pvoc(buf_size, hop_size, channels);
    101103  o->pp = new_aubio_peakpicker(o->threshold);
  • src/onset/onset.h

    rd25bd12 re4f142c  
    5353*/
    5454aubio_onset_t * new_aubio_onset (char_t * onset_mode,
    55     uint_t buf_size, uint_t hop_size, uint_t channels);
     55    uint_t buf_size, uint_t hop_size, uint_t channels, uint_t samplerate);
    5656
    5757/** execute onset detection
Note: See TracChangeset for help on using the changeset viewer.