Sound_and_Spectrogram_extensions.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. #ifndef _Sound_and_Spectrogram_extensions_h_
  2. #define _Sound_and_Spectrogram_extensions_h_
  3. /* Sound_and_Spectrogram_extensions.h
  4. *
  5. * Copyright (C) 2014-2015 David Weenink
  6. *
  7. * This code is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License as published by
  9. * the Free Software Foundation; either version 2 of the License, or (at
  10. * your option) any later version.
  11. *
  12. * This code is distributed in the hope that it will be useful, but
  13. * WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  15. * General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this work. If not, see <http://www.gnu.org/licenses/>.
  19. */
  20. /*
  21. djmw 20140914
  22. */
  23. #include "Spectrogram_extensions.h"
  24. #include "Pitch.h"
  25. #include "Sound.h"
  26. autoBarkSpectrogram Sound_to_BarkSpectrogram (Sound me, double analysisWidth, double dt,
  27. double f1_bark, double fmax_bark, double df_bark);
  28. /*
  29. Filtering with filters on a Bark scale as defined by
  30. Andrew Sekey & Brian Hanson (1984), "Improved 1-Bark bandwidth
  31. "auditory filter", Jasa 75, 1902-1904.
  32. Although not explicitely stated the filter function is defined in the
  33. power domain.
  34. 10 log F(z) = 15.8 + 7.5(z + 0.5) - 17.5 * sqrt(1 + (z + 0.5)^2)
  35. */
  36. autoMelSpectrogram Sound_to_MelSpectrogram (Sound me, double analysisWidth, double dt,
  37. double f1_mel, double fmax_mel, double df_mel);
  38. autoSpectrogram Sound_to_Spectrogram_pitchDependent (Sound me, double analysisWidth,
  39. double dt, double f1_hz, double fmax_hz, double df_hz, double relative_bw,
  40. double minimumPitch, double maximumPitch);
  41. autoSpectrogram Sound_Pitch_to_Spectrogram (Sound me, Pitch thee,
  42. double analysisWidth, double dt, double f1_hz, double fmax_hz,
  43. double df_hz, double relative_bw);
  44. autoSound BandFilterSpectrograms_crossCorrelate (BandFilterSpectrogram me, BandFilterSpectrogram thee, enum kSounds_convolve_scaling scaling, enum kSounds_convolve_signalOutsideTimeDomain signalOutsideTimeDomain);
  45. autoSound BandFilterSpectrograms_convolve (BandFilterSpectrogram me, BandFilterSpectrogram thee, enum kSounds_convolve_scaling scaling, enum kSounds_convolve_signalOutsideTimeDomain signalOutsideTimeDomain);
  46. #endif /* _Sound_and_Spectrogram_extensions_h_ */