(no commit message)
authorPaul Brossier <piem@altern.org>
Fri, 3 Dec 2004 17:50:04 +0000 (17:50 +0000)
committerPaul Brossier <piem@altern.org>
Fri, 3 Dec 2004 17:50:04 +0000 (17:50 +0000)
12 files changed:
ChangeLog
configure
configure.ac
plugins/Makefile.am
plugins/Makefile.in
plugins/puredata/Makefile.am [new file with mode: 0644]
plugins/puredata/Makefile.in [new file with mode: 0644]
plugins/puredata/aubioonset~.c [new file with mode: 0644]
plugins/puredata/help-aubioonset~.pd [new file with mode: 0644]
plugins/puredata/libtoolkludge [new file with mode: 0644]
src/mathutils.h
src/pitchyin.h

index 08dc5fc..40f661c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,8 @@
-2004-11-39  Paul Brossier <piem@altern.org>
+2004-12-03  Paul Brossier <piem@altern.org>
+       * src/{mathutils,pitchyin}.h: got rid of some shadowed declarations
+       * plugins/puredata: first puredata plugin attempt added
+
+2004-11-30  Paul Brossier <piem@altern.org>
        * configure.ac: added -lmx on macosx
        * python/aubiocut: seeks for local minima before peak
                           added zero crossing search
index 6f0ba82..1a9dc0e 100755 (executable)
--- a/configure
+++ b/configure
@@ -21053,7 +21053,7 @@ echo "${ECHO_T}$am_cv_python_pyexecdir" >&6
 
 
 
-                                                                                                                        ac_config_files="$ac_config_files Makefile src/Makefile examples/Makefile sounds/Makefile doc/Makefile python/Makefile python/aubio/Makefile plugins/Makefile plugins/audacity/Makefile plugins/audacity/plug-ins/Makefile plugins/wavesurfer/Makefile swig/Makefile"
+                                                                                                                                  ac_config_files="$ac_config_files Makefile src/Makefile examples/Makefile sounds/Makefile doc/Makefile python/Makefile python/aubio/Makefile plugins/Makefile plugins/audacity/Makefile plugins/audacity/plug-ins/Makefile plugins/wavesurfer/Makefile plugins/puredata/Makefile swig/Makefile"
 cat >confcache <<\_ACEOF
 # This file is a shell script that caches the results of configure
 # tests run on this system so they can be shared between configure
@@ -21622,6 +21622,7 @@ do
   "plugins/audacity/Makefile" ) CONFIG_FILES="$CONFIG_FILES plugins/audacity/Makefile" ;;
   "plugins/audacity/plug-ins/Makefile" ) CONFIG_FILES="$CONFIG_FILES plugins/audacity/plug-ins/Makefile" ;;
   "plugins/wavesurfer/Makefile" ) CONFIG_FILES="$CONFIG_FILES plugins/wavesurfer/Makefile" ;;
+  "plugins/puredata/Makefile" ) CONFIG_FILES="$CONFIG_FILES plugins/puredata/Makefile" ;;
   "swig/Makefile" ) CONFIG_FILES="$CONFIG_FILES swig/Makefile" ;;
   "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
   "src/config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;;
index 1557cb4..17320be 100644 (file)
@@ -159,6 +159,7 @@ AC_OUTPUT([
                plugins/audacity/Makefile
                plugins/audacity/plug-ins/Makefile
                plugins/wavesurfer/Makefile
+               plugins/puredata/Makefile
                swig/Makefile
        ])
 
index ec677ac..9c3bd09 100644 (file)
@@ -1 +1 @@
-SUBDIRS = wavesurfer audacity
+SUBDIRS = wavesurfer audacity puredata
index d125e14..ba0def8 100644 (file)
@@ -151,7 +151,7 @@ sbindir = @sbindir@
 sharedstatedir = @sharedstatedir@
 sysconfdir = @sysconfdir@
 target_alias = @target_alias@
-SUBDIRS = wavesurfer audacity
+SUBDIRS = wavesurfer audacity puredata
 subdir = plugins
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff --git a/plugins/puredata/Makefile.am b/plugins/puredata/Makefile.am
new file mode 100644 (file)
index 0000000..615a68f
--- /dev/null
@@ -0,0 +1,41 @@
+## Process this file with automake to produce Makefile.in. -*-Makefile-*-
+# inspired from Guenter Geiger's Makefile.am for plugin 
+# pure-data/externals/plugin~/Makefile.am -- rev 1.1
+
+SUFFIXES = .pd_linux
+PDDIR = $(prefix)/lib/pd
+pddir = $(PDDIR)
+#SUBDIRS = ladspa vst win
+
+## Make and install the shared library.
+pdinstalldir = $(pddir)/extra/aubio
+
+# Automake won't accept something ending in ".pd_linux" as a library
+pdinstall_PROGRAMS = aubioonset~.pd_linux
+
+aubioonset__pd_linux_SOURCES = \
+       aubioonset~.c
+
+pdincludedir = $(pddir)/src
+
+LIBTOOL=$(SHELL) ./libtoolkludge
+
+INCLUDES = -I$(top_srcdir) -I$(pdincludedir)
+
+AM_CFLAGS = -I../../src \
+    -DPD -O2 -funroll-loops -fomit-frame-pointer \
+    -Wall -W -Wshadow -Wstrict-prototypes -Werror \
+    -Wno-unused -Wno-parentheses -Wno-switch
+AM_LDFLAGS = -L../../src/.libs -laubio -export_dynamic -shared 
+
+## Install the documentation.
+
+pdinstall_DATA = \
+       help-aubioonset~.pd
+
+
+## My kludge
+noinst_SCRIPTS = libtoolkludge
+
+## version.h is there for the Windows platform (no autoconf)
+EXTRA_DIST = $(pdinstall_DATA) $(noinst_SCRIPTS) version.h
diff --git a/plugins/puredata/Makefile.in b/plugins/puredata/Makefile.in
new file mode 100644 (file)
index 0000000..7656ecd
--- /dev/null
@@ -0,0 +1,515 @@
+# Makefile.in generated by automake 1.7.9 from Makefile.am.
+# @configure_input@
+
+# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
+# Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# inspired from Guenter Geiger's Makefile.am for plugin 
+# pure-data/externals/plugin~/Makefile.am -- rev 1.1
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+top_builddir = ../..
+
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+INSTALL = @INSTALL@
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+host_triplet = @host@
+ACLOCAL = @ACLOCAL@
+ALSA_CFLAGS = @ALSA_CFLAGS@
+ALSA_LIBS = @ALSA_LIBS@
+AMDEP_FALSE = @AMDEP_FALSE@
+AMDEP_TRUE = @AMDEP_TRUE@
+AMTAR = @AMTAR@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CXX = @CXX@
+CXXCPP = @CXXCPP@
+CXXDEPMODE = @CXXDEPMODE@
+CXXFLAGS = @CXXFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO = @ECHO@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+F77 = @F77@
+FFLAGS = @FFLAGS@
+FFTWLIB_CFLAGS = @FFTWLIB_CFLAGS@
+FFTWLIB_LIBS = @FFTWLIB_LIBS@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+JACK_CFLAGS = @JACK_CFLAGS@
+JACK_LIBS = @JACK_LIBS@
+LADCCA_CFLAGS = @LADCCA_CFLAGS@
+LADCCA_LIBS = @LADCCA_LIBS@
+LDFLAGS = @LDFLAGS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+
+LIBTOOL = $(SHELL) ./libtoolkludge
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAKEINFO = @MAKEINFO@
+OBJEXT = @OBJEXT@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PYTHON = @PYTHON@
+PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
+PYTHON_PLATFORM = @PYTHON_PLATFORM@
+PYTHON_PREFIX = @PYTHON_PREFIX@
+PYTHON_VERSION = @PYTHON_VERSION@
+RANLIB = @RANLIB@
+SAMPLERATE_CFLAGS = @SAMPLERATE_CFLAGS@
+SAMPLERATE_LIBS = @SAMPLERATE_LIBS@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SNDLIB_CFLAGS = @SNDLIB_CFLAGS@
+SNDLIB_LIBS = @SNDLIB_LIBS@
+STRIP = @STRIP@
+VERSION = @VERSION@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_CXX = @ac_ct_CXX@
+ac_ct_F77 = @ac_ct_F77@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_STRIP = @ac_ct_STRIP@
+am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
+am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
+am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
+am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+datadir = @datadir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+oldincludedir = @oldincludedir@
+pkgpyexecdir = @pkgpyexecdir@
+pkgpythondir = @pkgpythondir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+pyexecdir = @pyexecdir@
+pythondir = @pythondir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+
+SUFFIXES = .pd_linux
+PDDIR = $(prefix)/lib/pd
+pddir = $(PDDIR)
+
+#SUBDIRS = ladspa vst win
+pdinstalldir = $(pddir)/extra/aubio
+
+# Automake won't accept something ending in ".pd_linux" as a library
+pdinstall_PROGRAMS = aubioonset~.pd_linux
+
+aubioonset__pd_linux_SOURCES = \
+       aubioonset~.c
+
+
+pdincludedir = $(pddir)/src
+
+INCLUDES = -I$(top_srcdir) -I$(pdincludedir)
+
+AM_CFLAGS = -I../../src \
+    -DPD -O2 -funroll-loops -fomit-frame-pointer \
+    -Wall -W -Wshadow -Wstrict-prototypes -Werror \
+    -Wno-unused -Wno-parentheses -Wno-switch
+
+AM_LDFLAGS = -L../../src/.libs -laubio -export_dynamic -shared 
+
+pdinstall_DATA = \
+       help-aubioonset~.pd
+
+
+noinst_SCRIPTS = libtoolkludge
+
+EXTRA_DIST = $(pdinstall_DATA) $(noinst_SCRIPTS) version.h
+subdir = plugins/puredata
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
+CONFIG_HEADER = $(top_builddir)/src/config.h
+CONFIG_CLEAN_FILES =
+pdinstall_PROGRAMS = aubioonset~.pd_linux$(EXEEXT)
+PROGRAMS = $(pdinstall_PROGRAMS)
+
+am_aubioonset__pd_linux_OBJECTS = aubioonset~.$(OBJEXT)
+aubioonset__pd_linux_OBJECTS = $(am_aubioonset__pd_linux_OBJECTS)
+aubioonset__pd_linux_LDADD = $(LDADD)
+aubioonset__pd_linux_DEPENDENCIES =
+aubioonset__pd_linux_LDFLAGS =
+SCRIPTS = $(noinst_SCRIPTS)
+
+
+DEFAULT_INCLUDES =  -I. -I$(srcdir) -I$(top_builddir)/src
+depcomp = $(SHELL) $(top_srcdir)/depcomp
+am__depfiles_maybe = depfiles
+@AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/aubioonset~.Po
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+       $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \
+       $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+CCLD = $(CC)
+LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+       $(AM_LDFLAGS) $(LDFLAGS) -o $@
+DIST_SOURCES = $(aubioonset__pd_linux_SOURCES)
+DATA = $(pdinstall_DATA)
+
+DIST_COMMON = $(srcdir)/Makefile.in Makefile.am
+SOURCES = $(aubioonset__pd_linux_SOURCES)
+
+all: all-am
+
+.SUFFIXES:
+.SUFFIXES: .pd_linux .c .lo .o .obj
+$(srcdir)/Makefile.in:  Makefile.am  $(top_srcdir)/configure.ac $(ACLOCAL_M4)
+       cd $(top_srcdir) && \
+         $(AUTOMAKE) --gnu  plugins/puredata/Makefile
+Makefile:  $(srcdir)/Makefile.in  $(top_builddir)/config.status
+       cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)
+pdinstallPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
+install-pdinstallPROGRAMS: $(pdinstall_PROGRAMS)
+       @$(NORMAL_INSTALL)
+       $(mkinstalldirs) $(DESTDIR)$(pdinstalldir)
+       @list='$(pdinstall_PROGRAMS)'; for p in $$list; do \
+         p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
+         if test -f $$p \
+            || test -f $$p1 \
+         ; then \
+           f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
+          echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(pdinstallPROGRAMS_INSTALL) $$p $(DESTDIR)$(pdinstalldir)/$$f"; \
+          $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(pdinstallPROGRAMS_INSTALL) $$p $(DESTDIR)$(pdinstalldir)/$$f || exit 1; \
+         else :; fi; \
+       done
+
+uninstall-pdinstallPROGRAMS:
+       @$(NORMAL_UNINSTALL)
+       @list='$(pdinstall_PROGRAMS)'; for p in $$list; do \
+         f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
+         echo " rm -f $(DESTDIR)$(pdinstalldir)/$$f"; \
+         rm -f $(DESTDIR)$(pdinstalldir)/$$f; \
+       done
+
+clean-pdinstallPROGRAMS:
+       @list='$(pdinstall_PROGRAMS)'; for p in $$list; do \
+         f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
+         echo " rm -f $$p $$f"; \
+         rm -f $$p $$f ; \
+       done
+aubioonset~.pd_linux$(EXEEXT): $(aubioonset__pd_linux_OBJECTS) $(aubioonset__pd_linux_DEPENDENCIES) 
+       @rm -f aubioonset~.pd_linux$(EXEEXT)
+       $(LINK) $(aubioonset__pd_linux_LDFLAGS) $(aubioonset__pd_linux_OBJECTS) $(aubioonset__pd_linux_LDADD) $(LIBS)
+
+mostlyclean-compile:
+       -rm -f *.$(OBJEXT) core *.core
+
+distclean-compile:
+       -rm -f *.tab.c
+
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aubioonset~.Po@am__quote@
+
+.c.o:
+@am__fastdepCC_TRUE@   if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \
+@am__fastdepCC_TRUE@     -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \
+@am__fastdepCC_TRUE@   then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \
+@am__fastdepCC_TRUE@   else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \
+@am__fastdepCC_TRUE@   fi
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$<
+
+.c.obj:
+@am__fastdepCC_TRUE@   if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \
+@am__fastdepCC_TRUE@     -c -o $@ `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`; \
+@am__fastdepCC_TRUE@   then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \
+@am__fastdepCC_TRUE@   else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \
+@am__fastdepCC_TRUE@   fi
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(COMPILE) -c `if test -f '$<'; then $(CYGPATH_W) '$<'; else $(CYGPATH_W) '$(srcdir)/$<'; fi`
+
+.c.lo:
+@am__fastdepCC_TRUE@   if $(LTCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \
+@am__fastdepCC_TRUE@     -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<; \
+@am__fastdepCC_TRUE@   then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; \
+@am__fastdepCC_TRUE@   else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; \
+@am__fastdepCC_TRUE@   fi
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@      $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@  $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$<
+
+mostlyclean-libtool:
+       -rm -f *.lo
+
+clean-libtool:
+       -rm -rf .libs _libs
+
+distclean-libtool:
+       -rm -f libtool
+uninstall-info-am:
+pdinstallDATA_INSTALL = $(INSTALL_DATA)
+install-pdinstallDATA: $(pdinstall_DATA)
+       @$(NORMAL_INSTALL)
+       $(mkinstalldirs) $(DESTDIR)$(pdinstalldir)
+       @list='$(pdinstall_DATA)'; for p in $$list; do \
+         if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+         f="`echo $$p | sed -e 's|^.*/||'`"; \
+         echo " $(pdinstallDATA_INSTALL) $$d$$p $(DESTDIR)$(pdinstalldir)/$$f"; \
+         $(pdinstallDATA_INSTALL) $$d$$p $(DESTDIR)$(pdinstalldir)/$$f; \
+       done
+
+uninstall-pdinstallDATA:
+       @$(NORMAL_UNINSTALL)
+       @list='$(pdinstall_DATA)'; for p in $$list; do \
+         f="`echo $$p | sed -e 's|^.*/||'`"; \
+         echo " rm -f $(DESTDIR)$(pdinstalldir)/$$f"; \
+         rm -f $(DESTDIR)$(pdinstalldir)/$$f; \
+       done
+
+ETAGS = etags
+ETAGSFLAGS =
+
+CTAGS = ctags
+CTAGSFLAGS =
+
+tags: TAGS
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+       list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+       unique=`for i in $$list; do \
+           if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+         done | \
+         $(AWK) '    { files[$$0] = 1; } \
+              END { for (i in files) print i; }'`; \
+       mkid -fID $$unique
+
+TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
+               $(TAGS_FILES) $(LISP)
+       tags=; \
+       here=`pwd`; \
+       list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
+       unique=`for i in $$list; do \
+           if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+         done | \
+         $(AWK) '    { files[$$0] = 1; } \
+              END { for (i in files) print i; }'`; \
+       test -z "$(ETAGS_ARGS)$$tags$$unique" \
+         || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+            $$tags $$unique
+
+ctags: CTAGS
+CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
+               $(TAGS_FILES) $(LISP)
+       tags=; \
+       here=`pwd`; \
+       list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
+       unique=`for i in $$list; do \
+           if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+         done | \
+         $(AWK) '    { files[$$0] = 1; } \
+              END { for (i in files) print i; }'`; \
+       test -z "$(CTAGS_ARGS)$$tags$$unique" \
+         || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+            $$tags $$unique
+
+GTAGS:
+       here=`$(am__cd) $(top_builddir) && pwd` \
+         && cd $(top_srcdir) \
+         && gtags -i $(GTAGS_ARGS) $$here
+
+distclean-tags:
+       -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+
+top_distdir = ../..
+distdir = $(top_distdir)/$(PACKAGE)-$(VERSION)
+
+distdir: $(DISTFILES)
+       @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+       topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
+       list='$(DISTFILES)'; for file in $$list; do \
+         case $$file in \
+           $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+           $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
+         esac; \
+         if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+         dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
+         if test "$$dir" != "$$file" && test "$$dir" != "."; then \
+           dir="/$$dir"; \
+           $(mkinstalldirs) "$(distdir)$$dir"; \
+         else \
+           dir=''; \
+         fi; \
+         if test -d $$d/$$file; then \
+           if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+             cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+           fi; \
+           cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+         else \
+           test -f $(distdir)/$$file \
+           || cp -p $$d/$$file $(distdir)/$$file \
+           || exit 1; \
+         fi; \
+       done
+check-am: all-am
+check: check-am
+all-am: Makefile $(PROGRAMS) $(SCRIPTS) $(DATA)
+
+installdirs:
+       $(mkinstalldirs) $(DESTDIR)$(pdinstalldir) $(DESTDIR)$(pdinstalldir)
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+       @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+       $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+         install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+         `test -z '$(STRIP)' || \
+           echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+       -rm -f $(CONFIG_CLEAN_FILES)
+
+maintainer-clean-generic:
+       @echo "This command is intended for maintainers to use"
+       @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool clean-pdinstallPROGRAMS \
+       mostlyclean-am
+
+distclean: distclean-am
+       -rm -rf ./$(DEPDIR)
+       -rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+       distclean-libtool distclean-tags
+
+dvi: dvi-am
+
+dvi-am:
+
+info: info-am
+
+info-am:
+
+install-data-am: install-pdinstallDATA install-pdinstallPROGRAMS
+
+install-exec-am:
+
+install-info: install-info-am
+
+install-man:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+       -rm -rf ./$(DEPDIR)
+       -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+       mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am: uninstall-info-am uninstall-pdinstallDATA \
+       uninstall-pdinstallPROGRAMS
+
+.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
+       clean-libtool clean-pdinstallPROGRAMS ctags distclean \
+       distclean-compile distclean-generic distclean-libtool \
+       distclean-tags distdir dvi dvi-am info info-am install \
+       install-am install-data install-data-am install-exec \
+       install-exec-am install-info install-info-am install-man \
+       install-pdinstallDATA install-pdinstallPROGRAMS install-strip \
+       installcheck installcheck-am installdirs maintainer-clean \
+       maintainer-clean-generic mostlyclean mostlyclean-compile \
+       mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+       tags uninstall uninstall-am uninstall-info-am \
+       uninstall-pdinstallDATA uninstall-pdinstallPROGRAMS
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/plugins/puredata/aubioonset~.c b/plugins/puredata/aubioonset~.c
new file mode 100644 (file)
index 0000000..16b001f
--- /dev/null
@@ -0,0 +1,102 @@
+/**
+ *
+ * a puredata wrapper for aubio onset detection functions 
+ *
+ * Thanks to Johannes M Zmolnig for writing the excellent HOWTO:
+ *       http://iem.kug.ac.at/pd/externals-HOWTO/  
+ *
+ * */
+
+#include <m_pd.h>
+#include <aubio.h>
+
+char aubioonset_version[] = "aubioonset~ version 0.1";
+
+static t_class *aubioonset_tilde_class;
+
+void aubioonset_tilde_setup (void);
+
+typedef struct _aubioonset_tilde 
+{
+       t_object x_obj;
+       t_float threshold;      
+       t_int bufsize;
+       t_int hopsize;
+       aubio_onsetdetection_t *o;
+       aubio_pvoc_t * pv;
+       fvec_t *vec;
+       fvec_t *onset;
+       cvec_t *fftgrain;
+       t_outlet *onsetval;
+} t_aubioonset_tilde;
+
+static t_int *aubioonset_tilde_perform(t_int *w) 
+{
+       t_aubioonset_tilde *x = (t_aubioonset_tilde *)(w[1]);
+       t_sample *in          = (t_sample *)(w[2]);
+       int n                 = (int)(w[3]);
+       //t_sample f = (x->threshold < 0.) ? 0.2 : 
+       //      (x->threshold > 10.) ? 10. : x->threshold;
+       while (n--) //*(x->vec->data[0])++ = (*in++);
+               x->vec->data[0][n] = in[n];
+       aubio_pvoc_do (x->pv, x->vec, x->fftgrain);
+       aubio_onsetdetection(x->o, x->fftgrain, x->onset);
+       outlet_float(x->onsetval, x->onset->data[0][0]);
+       return (w+4);
+}
+
+static void aubioonset_tilde_dsp(t_aubioonset_tilde *x, t_signal **sp)
+{
+       dsp_add(aubioonset_tilde_perform, 3, x, sp[0]->s_vec, sp[0]->s_n);
+}
+
+static void aubioonset_tilde_debug(t_aubioonset_tilde *x)
+{
+       post("aubioonset~ bufsize:\t%d", x->bufsize);
+       post("aubioonset~ hopsize:\t%d", x->hopsize);
+       post("aubioonset~ threshold:\t%f", x->threshold);
+       post("aubioonset~ audio in:\t%f", x->vec->data[0][0]);
+       post("aubioonset~ onset:\t%f", x->onset->data[0][0]);
+       outlet_float(x->onsetval, x->threshold);
+}
+
+static void *aubioonset_tilde_new (t_floatarg f)
+{
+       t_aubioonset_tilde *x = 
+               (t_aubioonset_tilde *)pd_new(aubioonset_tilde_class);
+
+       x->threshold = (f < 1e-5) ? 0.1 : (f > 10.) ? 10. : f;
+       /* should get from block~ size */
+       x->bufsize   = 1024;
+       x->hopsize   = x->bufsize / 2;
+
+       x->o = new_aubio_onsetdetection(complexdomain, x->bufsize, 1);
+       x->vec = (fvec_t *)new_fvec(x->hopsize,1);
+       x->pv = new_aubio_pvoc(x->bufsize, x->hopsize, 1);
+       x->fftgrain  = new_cvec(x->bufsize,1);
+       x->onset = (fvec_t *)new_fvec(1,1);
+
+       floatinlet_new (&x->x_obj, &x->threshold);
+       x->onsetval = outlet_new (&x->x_obj, &s_float);
+       return (void *)x;
+}
+
+void aubioonset_tilde_setup (void)
+{
+       aubioonset_tilde_class = class_new (gensym ("aubioonset~"),
+                       (t_newmethod)aubioonset_tilde_new,
+                       0, sizeof (t_aubioonset_tilde),
+                       CLASS_DEFAULT, A_DEFFLOAT, 0);
+       class_addmethod(aubioonset_tilde_class, 
+                       (t_method)aubioonset_tilde_dsp, 
+                       gensym("dsp"), 0);
+       class_addmethod(aubioonset_tilde_class, 
+                       (t_method)aubioonset_tilde_debug,
+                       gensym("debug"), 0);
+       class_sethelpsymbol(aubioonset_tilde_class, 
+                       gensym("help-aubioonset~.pd"));
+       CLASS_MAINSIGNALIN(aubioonset_tilde_class, 
+                       t_aubioonset_tilde, threshold);
+       post("aubioonset~ v0.1 for puredata");
+}
+
diff --git a/plugins/puredata/help-aubioonset~.pd b/plugins/puredata/help-aubioonset~.pd
new file mode 100644 (file)
index 0000000..8385974
--- /dev/null
@@ -0,0 +1,24 @@
+#N canvas 27 302 238 292 10;
+#X obj 50 33 adc~;
+#X obj 59 137 vu 15 120 empty empty -1 -8 0 8 -66577 -1 1 0;
+#X obj 58 109 scale 0 2000 -100 12;
+#N canvas 270 196 450 300 aubioonset 1;
+#X text 71 130 set blocksize to 1024 with 50% overlap;
+#X obj 56 90 outlet;
+#X obj 57 41 inlet~;
+#X obj 55 64 aubioonset~ 0.1;
+#X text 29 141 ugly. not required \, but should give better results
+;
+#X obj 200 95 block~ 1024 2 1;
+#X text 129 22 aubioonset~ takes an input signal and outputs the value
+of the value of the onset detection function;
+#X connect 2 0 3 0;
+#X connect 3 0 1 0;
+#X restore 58 78 pd aubioonset;
+#X obj 108 141 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -6 0 10
+-262144 -1 -1 1310.81 256;
+#X connect 0 0 3 0;
+#X connect 0 1 3 0;
+#X connect 2 0 1 0;
+#X connect 3 0 2 0;
+#X connect 3 0 4 0;
diff --git a/plugins/puredata/libtoolkludge b/plugins/puredata/libtoolkludge
new file mode 100644 (file)
index 0000000..47d3224
--- /dev/null
@@ -0,0 +1,11 @@
+#! /bin/sh
+
+if test \( $# -gt 1 \) -a \( $1 = "--mode=link" \); then
+  shift;
+  echo " libtoolkludge running \"$*\""
+  $*
+  exit 0
+else
+  echo "Libtoolkludge is a kludge for libtool --mode=install only.  Die!" >&2
+  exit 1
+fi
index e32bd03..1742743 100644 (file)
@@ -177,7 +177,7 @@ void vec_alpha_normalise(fvec_t * mag, uint_t alpha);
 void vec_add(fvec_t * mag, smpl_t threshold);
 
 void vec_adapt_thres(fvec_t * vec, fvec_t * tmp, 
-    uint_t post, uint_t pre);
+    uint_t win_post, uint_t win_pre);
 /**  adaptative thresholding 
  *
  * y=fn_thresh(fn,x,post,pre)
@@ -198,7 +198,7 @@ void vec_adapt_thres(fvec_t * vec, fvec_t * tmp,
  * see SPARMS for explanation of post and pre
  */
 smpl_t vec_moving_thres(fvec_t * vec, fvec_t * tmp, 
-    uint_t post, uint_t pre, uint_t pos);
+    uint_t win_post, uint_t win_pre, uint_t win_pos);
 
 /** returns the median of the vector 
  *
index 2d2af50..653631e 100644 (file)
 extern "C" {
 #endif
 
-void aubio_pitchyin_diff(fvec_t * input, fvec_t * yin);
+void aubio_pitchyin_diff(fvec_t * input, fvec_t * yinbuf);
 
-void aubio_pitchyin_getcum(fvec_t * yin);
+void aubio_pitchyin_getcum(fvec_t * yinbuf);
 
-uint_t aubio_pitchyin_getpitch(fvec_t *yin);
+uint_t aubio_pitchyin_getpitch(fvec_t *yinbuf);
 
-uint_t aubio_pitchyin_getpitchfast(fvec_t * input, fvec_t *yin);
+uint_t aubio_pitchyin_getpitchfast(fvec_t * input, fvec_t *yinbuf);
 
 #ifdef __cplusplus
 }