[Libxtract-commits] SF.net SVN: libxtract: [102] trunk
Status: Alpha
Brought to you by:
postlude
From: <pos...@us...> - 2007-10-08 10:32:17
|
Revision: 102 http://libxtract.svn.sourceforge.net/libxtract/?rev=102&view=rev Author: postlude Date: 2007-10-08 03:32:16 -0700 (Mon, 08 Oct 2007) Log Message: ----------- Committed missing files needed for new out-of-place fftw plan creation Added Paths: ----------- trunk/examples/puredata/xtract/a_blockswap~.pd trunk/src/fini.c trunk/src/xtract_globals_private.h Added: trunk/examples/puredata/xtract/a_blockswap~.pd =================================================================== --- trunk/examples/puredata/xtract/a_blockswap~.pd (rev 0) +++ trunk/examples/puredata/xtract/a_blockswap~.pd 2007-10-08 10:32:16 UTC (rev 102) @@ -0,0 +1,29 @@ +#N canvas 670 208 475 328 10; +#X obj 70 159 samplerate~; +#X obj 70 223 phasor~; +#X msg 163 159 0.5; +#X obj 23 10 inlet~; +#X obj 23 34 tabsend~ input; +#X obj 385 4 table input; +#X obj 76 272 tabread~ input; +#X obj 75 299 outlet~; +#X obj 70 194 / \$1; +#X obj 141 78 loadbang; +#X text 232 72 Clone of zexy blockswap~; +#X text 232 90 First argument gives block size; +#X msg 209 158 \; input resize \$1; +#X obj 141 109 t b b b; +#X obj 75 249 *~ \$1; +#X obj 209 135 f \$1; +#X connect 0 0 8 0; +#X connect 1 0 14 0; +#X connect 2 0 1 1; +#X connect 3 0 4 0; +#X connect 6 0 7 0; +#X connect 8 0 1 0; +#X connect 9 0 13 0; +#X connect 13 0 0 0; +#X connect 13 1 2 0; +#X connect 13 2 15 0; +#X connect 14 0 6 0; +#X connect 15 0 12 0; Added: trunk/src/fini.c =================================================================== --- trunk/src/fini.c (rev 0) +++ trunk/src/fini.c 2007-10-08 10:32:16 UTC (rev 102) @@ -0,0 +1,48 @@ +/* libxtract feature extraction library + * + * Copyright (C) 2006 Jamie Bullock + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + * USA. + */ + +/* fini.c: Contains library destructor routine */ + +#ifdef XTRACT_FFT +#include <fftw3.h> +#include "xtract_globals_private.h" +#endif + +#ifdef __GNUC__ +__attribute__((destructor)) void fini() +#else +void _fini() +#endif +{ +#ifdef XTRACT_FFT + if(spectrum_plan != NULL) + fftwf_destroy_plan(spectrum_plan); + if(autocorrelation_fft_plan_1 != NULL) + fftwf_destroy_plan(autocorrelation_fft_plan_1); + if(autocorrelation_fft_plan_2 != NULL) + fftwf_destroy_plan(autocorrelation_fft_plan_2); + if(dct_plan != NULL) + fftwf_destroy_plan(dct_plan); + fftwf_cleanup(); +#endif +} + + + Added: trunk/src/xtract_globals_private.h =================================================================== --- trunk/src/xtract_globals_private.h (rev 0) +++ trunk/src/xtract_globals_private.h 2007-10-08 10:32:16 UTC (rev 102) @@ -0,0 +1,36 @@ +/* libxtract feature extraction library + * + * Copyright (C) 2006 Jamie Bullock + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + * USA. + */ + +/* xtract_globals_private.h: declares private global variables */ + +#ifndef XTRACT_GLOBALS_PRIVATE_H +#define XTRACT_GLOBALS_PRIVATE_H + +#ifdef XTRACT_FFT +#include <fftw3.h> + +fftwf_plan spectrum_plan, + autocorrelation_fft_plan_1, + autocorrelation_fft_plan_2, + dct_plan; +#endif + +#endif + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |