PitchTier.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. #ifndef _PitchTier_h_
  2. #define _PitchTier_h_
  3. /* PitchTier.h
  4. *
  5. * Copyright (C) 1992-2011,2015,2017 Paul Boersma
  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.
  15. * See the GNU 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. #include "RealTier.h"
  21. #include "Graphics.h"
  22. #include "Sound.h"
  23. #include "Pitch.h"
  24. /********** class PitchTier **********/
  25. Thing_define (PitchTier, RealTier) {
  26. void v_info ()
  27. override;
  28. int v_domainQuantity ()
  29. override { return MelderQuantity_TIME_SECONDS; }
  30. };
  31. autoPitchTier PitchTier_create (double tmin, double tmax);
  32. /*
  33. Postconditions:
  34. result -> xmin == tmin;
  35. result -> xmax == tmax;
  36. result -> points.size == 0;
  37. */
  38. void PitchTier_shiftFrequencies (PitchTier me, double tmin, double tmax, double shift, kPitch_unit units);
  39. void PitchTier_multiplyFrequencies (PitchTier me, double tmin, double tmax, double factor);
  40. void PitchTier_draw (PitchTier me, Graphics g, double tmin, double tmax,
  41. double fmin, double fmax, bool garnish, conststring32 method);
  42. autoPitchTier PointProcess_upto_PitchTier (PointProcess me, double frequency);
  43. void PitchTier_stylize (PitchTier me, double frequencyResolution, bool useSemitones);
  44. void PitchTier_writeToPitchTierSpreadsheetFile (PitchTier me, MelderFile file);
  45. void PitchTier_writeToHeaderlessSpreadsheetFile (PitchTier me, MelderFile file);
  46. /* End of file PitchTier.h */
  47. #endif