| 1 | /* TextGrid_Sound.h |
| 2 | * |
| 3 | * Copyright (C) 1992-2019,2025,2026 Paul Boersma |
| 4 | * |
| 5 | * This code is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 3 of the License, or (at |
| 8 | * your option) any later version. |
| 9 | * |
| 10 | * This code is distributed in the hope that it will be useful, but |
| 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 13 | * See the GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this work. If not, see <http://www.gnu.org/licenses/>. |
| 17 | */ |
| 18 | |
| 19 | #include "TextGrid.h" |
| 20 | #include "Sound.h" |
| 21 | #include "Pitch.h" |
| 22 | |
| 23 | void TextGrid_Sound_draw (TextGrid me, Sound sound, Graphics g, double tmin, double tmax, |
| 24 | bool showBoundaries, bool useTextStyles, bool garnish); |
| 25 | |
| 26 | autoSoundList TextGrid_Sound_extractAllIntervals (TextGrid me, Sound sound, integer tierNumber, bool preserveTimes); |
| 27 | autoSoundList TextGrid_Sound_extractNonemptyIntervals (TextGrid me, Sound sound, integer tierNumber, bool preserveTimes); |
| 28 | autoSoundList TextGrid_Sound_extractIntervalsWhere (TextGrid me, Sound sound, |
| 29 | integer tierNumber, kMelder_string which, conststring32 text, bool preserveTimes); |
| 30 | |
| 31 | void TextGrid_Pitch_draw (TextGrid grid, Pitch pitch, Graphics g, |
| 32 | integer tierNumber, double tmin, double tmax, double fmin, double fmax, |
| 33 | double fontSize, bool useTextStyles, int horizontalAlignment, bool garnish, bool speckle, kPitch_unit unit); |
| 34 | void TextGrid_Pitch_drawSeparately (TextGrid grid, Pitch pitch, Graphics g, double tmin, double tmax, |
| 35 | double fmin, double fmax, bool showBoundaries, bool useTextStyles, bool garnish, bool speckle, kPitch_unit unit); |
| 36 | |
| 37 | void TextGrid_anySound_alignInterval (TextGrid me, Function anySound, integer tierNumber, integer intervalNumber, |
| 38 | conststring32 languageName, bool includeWords, bool includePhonemes); |
| 39 | |
| 40 | struct SpeechSegment; |
| 41 | void splitIntervalIntoWhisperSegments (IntervalTier tier, integer tierNumber, |
| 42 | double originalTmin, double originalTmax, autovector<SpeechSegment> const& segments); |
| 43 | void TextGrid_Sound_transcribeInterval (TextGrid me, Sound sound, integer tierNumber, integer intervalNumber, |
| 44 | conststring32 modelName, conststring32 languageName, bool includeWords, bool useVad, |
| 45 | double speechProbabilityThreshold, double minNonSpeechDuration, double minSpeechDuration, double speechPad, |
| 46 | bool includeDiarization, integer maxNumSpeakers, bool allowSpeakersOverlap, |
| 47 | double clusterThreshold, double segmentationStep |
| 48 | ); |
| 49 | void TextGrid_Sound_diarizeInterval (TextGrid me, Sound sound, integer tierNumber, integer intervalNumber, |
| 50 | integer maxNumSpeakers, bool allowSpeakersOverlap, conststring32 nonSpeechLabel, conststring32 speechLabel, |
| 51 | double clusterThreshold, double segmentationStep |
| 52 | ); |
| 53 | |
| 54 | autoSound Sound_readWithAdjacentAnnotationFiles_buckeye (conststring32 soundFileName, autoTextGrid *out_textgrid); |
| 55 | autoSound Sound_readWithAdjacentAnnotationFiles_timit (conststring32 soundFileName, autoTextGrid *out_textgrid); |
| 56 | autoTextGrid TextGrid_Sound_readFromCorpusGesprokenNederlands (conststring32 soundFileName, autoSound *out_Sound); |
| 57 | |
| 58 | /* End of file TextGrid_Sound.h */ |