Skip to content

Commit

Permalink
CC + ValidateAlias refinement
Browse files Browse the repository at this point in the history
  • Loading branch information
lottev1991 authored Jul 11, 2023
1 parent c2110b0 commit 612fa89
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions OpenUtau.Plugin.Builtin/ENDeltaPhonemizer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ protected override List<string> ProcessSyllable(Syllable syllable) {
// try RCC
for (var i = cc.Length; i > 1; i--) {
if (TryAddPhoneme(phonemes, syllable.tone, $"- {string.Join("", cc.Take(i))}")) {
firstC = i;
firstC = i - 1;
break;
}
}
Expand Down Expand Up @@ -551,12 +551,12 @@ protected override string ValidateAlias(string alias) {
}
foreach (var consonant in new[] { "b" }) {
foreach (var vowel in new[] { "V" } ) {
alias = alias.Replace(consonant + vowel, consonant + "A");
alias = alias.Replace(consonant + vowel, consonant + "@");
}
}
foreach (var vowel in new[] { "V " }) {
foreach (var vowel in new[] { "@ " }) {
foreach (var consonant in new[] { "b" } ) {
alias = alias.Replace("V " + consonant, "A " + consonant);
alias = alias.Replace("@ " + consonant, "@ " + consonant);
}
}
foreach (var vowel in new[] { "a" }) {
Expand Down Expand Up @@ -618,7 +618,7 @@ protected override string ValidateAlias(string alias) {
alias = alias.Replace(consonant, "3 ");
}
foreach (var vowel in new[] { "V" }) {
alias = alias.Replace(vowel, "A");
alias = alias.Replace(vowel, "@");
}
foreach (var CC in new[] { "T " }) {
alias = alias.Replace(CC, "f ");
Expand Down

0 comments on commit 612fa89

Please sign in to comment.