Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mathutils.h

    r0683ee2 r6f42c16  
    2828 */
    2929
    30 #ifndef _AUBIO_MATHUTILS_H
    31 #define _AUBIO_MATHUTILS_H
     30#ifndef AUBIO_MATHUTILS_H
     31#define AUBIO_MATHUTILS_H
    3232
    3333#include "fvec.h"
     
    9999*/
    100100void fvec_shift (fvec_t * v);
     101
     102/** swap the left and right halves of a vector
     103
     104  This function swaps the left part of the signal with the right part of the
     105signal. Therefore
     106
     107  \f$ a[0], a[1], ..., a[\frac{N}{2}], a[\frac{N}{2}+1], ..., a[N-1], a[N] \f$
     108
     109  becomes
     110
     111  \f$ a[\frac{N}{2}+1], ..., a[N-1], a[N], a[0], a[1], ..., a[\frac{N}{2}] \f$
     112
     113  This operation, known as 'ifftshift' in the Matlab Signal Processing Toolbox,
     114can be used after computing the inverse FFT to simplify the phase relationship
     115of the resulting spectrum. See Amalia de Götzen's paper referred to above.
     116
     117*/
     118void fvec_ishift (fvec_t * v);
    101119
    102120/** compute the sum of all elements of a vector
     
    233251
    234252*/
    235 smpl_t fvec_quadratic_peak_pos (fvec_t * x, uint_t p);
     253smpl_t fvec_quadratic_peak_pos (const fvec_t * x, uint_t p);
    236254
    237255/** finds magnitude of peak by quadratic interpolation
     
    276294
    277295*/
    278 uint_t fvec_peakpick (fvec_t * v, uint_t p);
     296uint_t fvec_peakpick (const fvec_t * v, uint_t p);
    279297
    280298/** return 1 if a is a power of 2, 0 otherwise */
     
    290308
    291309*/
    292 void aubio_autocorr (fvec_t * input, fvec_t * output);
     310void aubio_autocorr (const fvec_t * input, fvec_t * output);
    293311
    294312#ifdef __cplusplus
     
    296314#endif
    297315
    298 #endif /* _AUBIO_MATHUTILS_H */
     316#endif /* AUBIO_MATHUTILS_H */
Note: See TracChangeset for help on using the changeset viewer.