shithub: aubio

Download patch

ref: 27f2c08efb7176c7f9417c1be3d17a8d3fe3fd6f
parent: de92b1cf0ccedab2abe1d802acf67a36da4a48b1
author: Paul Brossier <piem@altern.org>
date: Thu Dec 22 11:34:14 EST 2005

adds peakpick_pimrt_getval and beattracking functions
adds peakpick_pimrt_getval and beattracking functions


--- a/python/aubio/aubioclass.py
+++ b/python/aubio/aubioclass.py
@@ -70,6 +70,8 @@
         self.pp = new_aubio_peakpicker(threshold)
     def do(self,fv):
         return aubio_peakpick_pimrt(fv(),self.pp)
+    def getval(self):
+        return aubio_peakpick_pimrt_getval(self.pp)
     def __del__(self):
         del_aubio_peakpicker(self.pp)
 
@@ -126,3 +128,13 @@
         pass
     def __call__(self,myvec):
         aubio_filter_do(self.filter,myvec())
+
+class beattracking:
+    """ class for aubio_beattracking """
+    def __init__(self,winlen,channels):
+        self.p = new_aubio_beattracking(winlen,channels)
+    def do(self,dfframe,out):
+        return aubio_beattracking_do(self.p,dfframe(),out())
+    def __del__(self):
+        del_aubio_beattracking(self.p)
+