From 6d7093656fba3acdcd14d58be2ff7ca3f18c7662 Mon Sep 17 00:00:00 2001 From: "A. Skrobov" Date: Sat, 25 Apr 2020 22:30:16 +0200 Subject: [PATCH 1/3] Bug in debug output: was skipping every other phoneme --- src/parser/parser.es6 | 1 - 1 file changed, 1 deletion(-) diff --git a/src/parser/parser.es6 b/src/parser/parser.es6 index 1dd12f16..291d17f5 100644 --- a/src/parser/parser.es6 +++ b/src/parser/parser.es6 @@ -168,7 +168,6 @@ function PrintPhonemes (phonemeindex, phonemeLength, stress) { pad(phonemeLength[i]), pad(stress[i]) ); - i++; } console.log('=================================='); } From 6f9f3d9fdec623199dcf17854db67989ddbaf20c Mon Sep 17 00:00:00 2001 From: "A. Skrobov" Date: Sat, 25 Apr 2020 22:30:41 +0200 Subject: [PATCH 2/3] Typo in a comment --- src/parser/parse1.es6 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/parser/parse1.es6 b/src/parser/parse1.es6 index 94cc1bba..b2d4a719 100644 --- a/src/parser/parse1.es6 +++ b/src/parser/parse1.es6 @@ -67,7 +67,7 @@ function wild_match (sign1) { * * input holds the string of phonemes, each two bytes wide * signInputTable1[] holds the first character of each phoneme - * signInputTable2[] holds te second character of each phoneme + * signInputTable2[] holds the second character of each phoneme * phonemeIndex[] holds the indexes of the phonemes after parsing input[] * * The parser scans through the input[], finding the names of the phonemes From 889297c9ad148be9d9da980dc2ca96d25dbe4492 Mon Sep 17 00:00:00 2001 From: "A. Skrobov" Date: Sun, 26 Apr 2020 01:30:09 +0200 Subject: [PATCH 3/3] The names RISING_INFLECTION and FALLING_INFLECTION were wrong way around --- src/renderer/create-frames.es6 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/renderer/create-frames.es6 b/src/renderer/create-frames.es6 index f6ed75c7..2aec9c11 100644 --- a/src/renderer/create-frames.es6 +++ b/src/renderer/create-frames.es6 @@ -5,8 +5,8 @@ import { } from './tables.es6'; import {PHONEME_PERIOD, PHONEME_QUESTION} from '../parser/constants.es6'; -const RISING_INFLECTION = 1; -const FALLING_INFLECTION = 255; +const RISING_INFLECTION = 255; +const FALLING_INFLECTION = 1; /** * Create a rising or falling inflection 30 frames prior to index X. @@ -75,9 +75,9 @@ export default function CreateFrames ( // get the phoneme at the index let phoneme = tuples[i][0]; if (phoneme === PHONEME_PERIOD) { - AddInflection(RISING_INFLECTION, X, pitches); - } else if (phoneme === PHONEME_QUESTION) { AddInflection(FALLING_INFLECTION, X, pitches); + } else if (phoneme === PHONEME_QUESTION) { + AddInflection(RISING_INFLECTION, X, pitches); } // get the stress amount (more stress = higher pitch)