return (p->pickerfn)(onset_peek,1);
}
+/** this method returns the current value in the pick peaking buffer
+ * after smoothing
+ */
+smpl_t aubio_peakpick_pimrt_getval(aubio_pickpeak_t * p)
+{
+ uint_t i = 0;
+ return p->onset_peek->data[i][1];
+}
+
/** function added by Miguel Ramirez to return the onset detection amplitude in peakval */
uint_t aubio_peakpick_pimrt_wt(fvec_t * onset, aubio_pickpeak_t * p, smpl_t* peakval)
{
- uint_t i = 0, isonset = 0;
+ uint_t isonset = 0;
isonset = aubio_peakpick_pimrt(onset,p);
//if ( isonset && peakval != NULL )
if ( peakval != NULL )
- *peakval = p->onset_peek->data[i][1];
+ *peakval = aubio_peakpick_pimrt_getval(p);
return isonset;
}
uint_t aubio_peakpick_pimrt(fvec_t * DF, aubio_pickpeak_t * p);
/** function added by Miguel Ramirez to return the onset detection amplitude in peakval */
uint_t aubio_peakpick_pimrt_wt( fvec_t* DF, aubio_pickpeak_t* p, smpl_t* peakval );
+smpl_t aubio_peakpick_pimrt_getval(aubio_pickpeak_t * p);
void del_aubio_peakpicker(aubio_pickpeak_t * p);
void aubio_peakpicker_set_threshold(aubio_pickpeak_t * p, smpl_t threshold);