source: src/spectral/specdesc.h @ 554e286

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5pitchshiftsamplertimestretchyinfft+
Last change on this file since 554e286 was bf2e7a7, checked in by Paul Brossier <piem@piem.org>, 15 years ago

src/spectral/specdesc.h: improve documentation

  • Property mode set to 100644
File size: 4.2 KB
Line 
1/*
2  Copyright (C) 2003-2009 Paul Brossier <piem@aubio.org>
3
4  This file is part of aubio.
5
6  aubio is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10
11  aubio is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  GNU General Public License for more details.
15
16  You should have received a copy of the GNU General Public License
17  along with aubio.  If not, see <http://www.gnu.org/licenses/>.
18
19*/
20
21/** \file
22 
23  Spectral description functions
24 
25  All of the following spectral description functions take as arguments the FFT
26  of a windowed signal (as created with aubio_pvoc). They output one smpl_t per
27  buffer and per channel (stored in a vector of size [channels]x[1]).
28 
29  The following spectral description methods are available:
30
31  \b \p energy : Energy based onset detection function
32 
33  This function calculates the local energy of the input spectral frame.
34 
35  \b \p hfc : High Frequency Content onset detection function
36 
37  This method computes the High Frequency Content (HFC) of the input spectral
38  frame. The resulting function is efficient at detecting percussive onsets.
39
40  Paul Masri. Computer modeling of Sound for Transformation and Synthesis of
41  Musical Signal. PhD dissertation, University of Bristol, UK, 1996.
42
43  \b \p complex : Complex Domain Method onset detection function
44 
45  Christopher Duxbury, Mike E. Davies, and Mark B. Sandler. Complex domain
46  onset detection for musical signals. In Proceedings of the Digital Audio
47  Effects Conference, DAFx-03, pages 90-93, London, UK, 2003.
48
49  \b \p phase : Phase Based Method onset detection function
50
51  Juan-Pablo Bello, Mike P. Davies, and Mark B. Sandler. Phase-based note onset
52  detection for music signals. In Proceedings of the IEEE International
53  Conference on Acoustics Speech and Signal Processing, pages 441­444,
54  Hong-Kong, 2003.
55
56  \b \p specdiff : Spectral difference method onset detection function
57
58  Jonhatan Foote and Shingo Uchihashi. The beat spectrum: a new approach to
59  rhythm analysis. In IEEE International Conference on Multimedia and Expo
60  (ICME 2001), pages 881­884, Tokyo, Japan, August 2001.
61
62  \b \p kl : Kullback-Liebler onset detection function
63 
64  Stephen Hainsworth and Malcom Macleod. Onset detection in music audio
65  signals. In Proceedings of the International Computer Music Conference
66  (ICMC), Singapore, 2003.
67
68  \b \p mkl : Modified Kullback-Liebler onset detection function
69
70  Paul Brossier, ``Automatic annotation of musical audio for interactive
71  systems'', Chapter 2, Temporal segmentation, PhD thesis, Centre for Digital
72  music, Queen Mary University of London, London, UK, 2006.
73
74  \b \p specflux : Spectral Flux
75
76  Simon Dixon, Onset Detection Revisited, in ``Proceedings of the 9th
77  International Conference on Digital Audio Effects'' (DAFx-06), Montreal,
78  Canada, 2006.
79 
80*/
81
82
83#ifndef ONSETDETECTION_H
84#define ONSETDETECTION_H
85
86#ifdef __cplusplus
87extern "C" {
88#endif
89
90/** spectral description structure */
91typedef struct _aubio_specdesc_t aubio_specdesc_t;
92
93/** execute spectral description function on a spectral frame
94
95  Generic function to compute spectral detescription.
96 
97  \param o spectral description object as returned by new_aubio_specdesc()
98  \param fftgrain input signal spectrum as computed by aubio_pvoc_do
99  \param desc output vector (one sample long, to send to the peak picking)
100
101*/
102void aubio_specdesc_do (aubio_specdesc_t * o, cvec_t * fftgrain,
103    fvec_t * desc);
104
105/** creation of a spectral description object
106
107  \param method spectral description method
108  \param buf_size length of the input spectrum frame
109  \param channels number of input channels
110
111*/
112aubio_specdesc_t *new_aubio_specdesc (char_t * method, uint_t buf_size,
113    uint_t channels);
114
115/** deletion of a spectral descriptor
116
117  \param o spectral descriptor object as returned by new_aubio_specdesc()
118
119*/
120void del_aubio_specdesc (aubio_specdesc_t * o);
121
122#ifdef __cplusplus
123}
124#endif
125
126#endif /* ONSETDETECTION_H */
Note: See TracBrowser for help on using the repository browser.