From cd526805853c1bf65b604baf16d38b9ef9dcbd2f Mon Sep 17 00:00:00 2001 From: Rob van Son Date: Thu, 19 Apr 2012 10:44:48 +0200 Subject: [PATCH] Unfinished work on eSpeak alignment --- InitialiseSGC2.praat | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/InitialiseSGC2.praat b/InitialiseSGC2.praat index 735d926..38b1ce4 100644 --- a/InitialiseSGC2.praat +++ b/InitialiseSGC2.praat @@ -542,6 +542,12 @@ endproc procedure align_recordedSound .pinyin$ .command$ = "" if 0 and sgc2.synthesizer > 0 and recordedSound$ <> "" + # Get synthesizer settings rate and change the settings + select sgc2.synthesizer + .synthesizerSettings$ = Info + .wordRate = extractNumber(.synthesizerSettings$, "Speeking rate: ") + Set speaking rate... 100 + select Sound 'recordedSound$' .recordedTextGrid = To TextGrid... pinyin Set interval text... 1 1 '.pinyin$' @@ -549,8 +555,12 @@ procedure align_recordedSound .pinyin$ plus Sound 'recordedSound$' plus .recordedTextGrid sgc2.alignedTextGrid = nowarn noprogress To TextGrid (align)... 1 1 1 -35 0.1 0.1 - Rename AlignedTextGrid + Rename... AlignedTextGrid select .recordedTextGrid Remove + + # Reset synthesizer + select sgc2.synthesizer + Set speaking rate... '.wordRate' endif endproc -- 2.11.4.GIT