Zum Inhalt springen

Empfohlene Beiträge

Geschrieben

Wer ein wenig "Herumspielen" möchte:

Ich habe, basierend auf den SPO256A-AL2 Speech Synthesizer Chip einen "kleinen" Sprachsynthesizer programmiert.

Dieser verwendet fertige Samples, benötigt KEINE zusätzlichen Libraries und ist (abgesehen von den Sprachsamples) recht klein.

Testen könnt Ihr ihn hier:

JaSPO-256

Download auf Anfrage. (Ihr könnt auch im Quelltext herausfinden, wie die .jar Datei heisst) ;)

Viel Spass damit.

Geschrieben
Funktioniert nicht: NoClassFound-Exception

Seltsam... !??

Welchen Browser verwendest Du?

bei mir funzt das Applet im Firefox, IE8 und Safari.

Ich hab mal eben fix den "codebase" geändert. 1x aktualisieren bitte.

Geschrieben

Ich benutze OSX und kein Windows und gerade wenn Du Java Applets oder Java Tools veröffentlichst, solltest Du auf passende Kompatibilität achten

Meldung: java.lang.NoClassDefFoundError: java/swing/GroupLayout$Group

Geschrieben
Ich benutze OSX und kein Windows und gerade wenn Du Java Applets oder Java Tools veröffentlichst, solltest Du auf passende Kompatibilität achten

Meldung: java.lang.NoClassDefFoundError: java/swing/GroupLayout$Group

Schaue ich mir morgen mal an.

Komisch, unter Linux geht es seltsamerweise...

Ich schmeiss morgen mal die Layouts raus und ersetze sie gegen Standard-Layouts.

Geschrieben
<APPLET codebase="/" archive="JaSPO256.jar" code="MainApplet.class" width=612 height=295></APPLET>

Der Fehler liegt darin, dass einige Browser explizit auch die Felder als param name erwarten.

<APPLET codebase="/" archive="JaSPO256.jar" code="MainApplet.class" width=612 height=295>

<param name="codebase" value="/">

<param name="archive" value="JaSPO256.jar">

<param name="code" value="MainApplet.class">

<param name="width" value="612">

<param name="height" value="295">

</APPLET>

Da gibt es noch einige Stolpersteine bei Applet Programmierung, ganz besonders was IE8 angeht..

Ich denke, nach dieser Änderung sollte auch OSx Applet laden können, ansonsten auf meiner Win Kiste läuft es 1A, nur zu dumm, dass es kein richtiges Deutsch kann.

Geschrieben (bearbeitet)
nur zu dumm, dass es kein richtiges Deutsch kann.

Interesse, eine "Deutsche" Konvertierung zu programmieren dafür?

Hier der code für die Englische Umwandlung:

(Recht simpel, sicherlich verbesserungsbedürftig)

/*

 * To change this template, choose Tools | Templates

 * and open the template in the editor.

 */


/**

 *

 * @author Markus

 */

import java.util.*;


public class Converter {


    public Converter() {

    }


    public Vector getWords(String s) {

        Vector vector = new Vector();

        for (StringTokenizer stringtokenizer = new StringTokenizer(s, "()'\"\\!?{}/-"); stringtokenizer.hasMoreElements(); vector.addElement(stringtokenizer.nextToken().toLowerCase())) {

        }

        return vector;

    }


    public String getPhoneWord(String s) {


        s = replace(s, "*JASPO*", "JH|AA|SS|PP|OW");

        s = replace(s, "*jaspo*", "JH|AA|SS|PP|OW");

        s = replace(s, "*256*", "TT2|UW2|HH1|AA|NN1|DD1|RR2|EH|DD1|FF|IH|FF|TT2|IY|SS|IH|PA3|KK1|SS");

        s = replace(s, "*A*", "EY|PA3");

        s = replace(s, "*B*", "BB2|IY|PA3");

        s = replace(s, "*C*", "SS|IY|PA3");

        s = replace(s, "*D*", "DD1|IY|PA3");

        s = replace(s, "*E*", "IY|PA3");

        s = replace(s, "*F*", "EH|FF|PA3");

        s = replace(s, "*G*", "JH|IY|PA3");

        s = replace(s, "*H*", "EY|CH|PA3");

        s = replace(s, "*I*", "AY|PA3");

        s = replace(s, "*J*", "JH|EY|PA3");

        s = replace(s, "*K*", "KK1|EY|PA3");

        s = replace(s, "*L*", "EH|LL|PA3");

        s = replace(s, "*M*", "EH|MM|PA3");

        s = replace(s, "*N*", "EH|NG|PA3");

        s = replace(s, "*O*", "OW|PA3");

        s = replace(s, "*P*", "PP|IY|PA3");

        s = replace(s, "*Q*", "KK1|YY2|UW2|PA3");

        s = replace(s, "*R*", "AR|PA3");

        s = replace(s, "*S*", "EH|SS|PA3");

        s = replace(s, "*T*", "TT2|IY|PA3");

        s = replace(s, "*U*", "YY1|UW2|PA3");

        s = replace(s, "*V*", "VV|IY|PA3");

        s = replace(s, "*W*", "DD1|AA|PA2|BB2|EL|YY1|UW2|PA3");

        s = replace(s, "*X*", "EH|KK1|SS|PA3");

        s = replace(s, "*Y*", "WW|AY|PA3");

        s = replace(s, "*Z*", "ZZ|EH|PA2|DD2|PA3");


        s = replace(s, "*while*", "WW|AY|LL");

        s = replace(s, "*whil*", "WW|IH|LL");

        s = replace(s, "*because*", "BB2|IY|KK3|OR|SS");

        s = replace(s, "*1*", "WW|AO|NN1");

        s = replace(s, "*2*", "TT2|UW2");

        s = replace(s, "*3*", "FF|RR1|IY");

        s = replace(s, "*4*", "FF|OR");

        s = replace(s, "*5*", "FF|AY|PA3|VV");

        s = replace(s, "*6*", "SS|IH|PA3|KK1|SS");

        s = replace(s, "*7*", "SS|EH|PA3|VV|NN1");

        s = replace(s, "*8*", "EY|PA3|TT2");

        s = replace(s, "*9*", "NN2|AY|NN1");

        s = replace(s, "*0*", "ZZ|IH|RR2|OW");

        s = replace(s, "*their*", "TH|EH|ER2");

        s = replace(s, "*you*", "YY1|UW2");

        s = replace(s, "*measure*", "MM|EY|SH|OR");

        s = replace(s, "*measur*", "MM|EY|SS|OR");

        s = replace(s, "*human*", "HH1|IY|UW2|MM|AA|NN1");

        s = replace(s, "*world*", "WW|OR|LL|DD1");

        s = replace(s, "*year*", "YY1|IY|XR");

        s = replace(s, "*cent*", "SS|EH|NN1|TT2");

        s = replace(s, "*being*", "BB2|IH|IH|NG");

        s = replace(s, "*ever*", "EH|PA3|VV|ER2");

        s = replace(s, "*application*", "AA|PP|LL|IH|KK3|EY|SH|AX|NN1");

        s = replace(s, "*evel*", "IY|PA3|VV|EH|LL");

        s = replace(s, "*evil*", "IY|PA3|VV|IH|LL");

        s = replace(s, "*ted*", "TT2|EH|DD1");

        s = replace(s, "*want*", "WW|AA|NN1|TT2");

        s = replace(s, "*charac*", "KK1|AE|RR2|AA|KK3");

        s = replace(s, "*chine*", "CH|AY|NN1");

        s = replace(s, "*have*", "HH1|AE|PA3|VV");

        s = replace(s, "*over*", "OW|PA3|VV|ER2");

        s = replace(s, "*ing*", "IH|NG");

        s = replace(s, "*ince*", "IH|NN1|SS");

        s = replace(s, "*nce*", "NN1|SS");

        s = replace(s, "*ed", "EH|DD1");

        s = replace(s, "*thought*", "TH|OW|TT2");

        s = replace(s, "*though*", "TH|OW");

        s = replace(s, "*through*", "TH|RR2|UW2");

        s = replace(s, "*drought*", "DD2|RR2|OR|TT2");

        s = replace(s, "*brought*", "BB2|RR2|OR|TT2");

        s = replace(s, "*rough*", "|RR2|AX|FF");

        s = replace(s, "*ough*", "AW|PA1|HH1");

        s = replace(s, "*mould*", "MM|UH|PA2|DD2");

        s = replace(s, "*ould*", "UH|PA2|DD2");

        s = replace(s, "*uild*", "UW2|LL|DD1");

        s = replace(s, "*eicest*", "SS|EH|SS|TT2");

        s = replace(s, "*icest*", "AY|SS|EH|SS|TT2");

        s = replace(s, "*igh*", "AY");

        s = replace(s, "*cause*", "KK3|OR|SS");

        s = replace(s, "*aus*", "OR|SS");

        s = replace(s, "*cial*", "SS|AY|LL");

        s = replace(s, "*tia*", "TT2|YR");

        s = replace(s, "*tio*", "TT2|AY");

        s = replace(s, "*one*", "WW|AO|NN1");

        s = replace(s, "*lly*", "LL|IY");

        s = replace(s, "*dis*", "DD1|IH|SS");

        s = replace(s, "*que*", "KK2|WW");

        s = replace(s, "*qu*", "KK2|WW");

        s = replace(s, "*sky*", "SS|KK2|AY");

        s = replace(s, "*fly*", "FF|LL|AY");

        s = replace(s, "*ly*", "LL|IY");

        s = replace(s, "*than*", "TH|AA|NN1");

        s = replace(s, "*that*", "TH|AA|TT2");

        s = replace(s, "*thee*", "TH|IY");

        s = replace(s, "*the*", "TH|AX");

        s = replace(s, "*them*", "TH|EH|MM");

        s = replace(s, "*thence*", "TH|EH|NN1|SS");

        s = replace(s, "*then*", "TH|EH|NN1");

        s = replace(s, "*there*", "TH|XR");

        s = replace(s, "*they*", "TH|AY");

        s = replace(s, "*this*", "TH|IH|SS");

        s = replace(s, "*thus*", "TH|AX|SS");

        s = replace(s, "*abe*", "EY|BB1");

        s = replace(s, "*ace*", "EY|PA2|SS");

        s = replace(s, "*ade*", "EY|DD1");

        s = replace(s, "*afe*", "EY|FF");

        s = replace(s, "*age*", "EY|PA2|JH");

        s = replace(s, "*ake*", "EY|PA3|KK1");

        s = replace(s, "*ale*", "EY|LL");

        s = replace(s, "*ame*", "EY|MM");

        s = replace(s, "*ane*", "EY|NN1");

        s = replace(s, "*ape*", "EY|PP");

        s = replace(s, "*ase*", "EY|SS");

        s = replace(s, "*aze*", "EY|ZZ");

        s = replace(s, "*ate*", "EY|TT2|PA1");

        s = replace(s, "*ave*", "EY|PA3|VV");

        s = replace(s, "*azy*", "AA|ZZ|IY");

        s = replace(s, "*ede*", "IY|DD1");

        s = replace(s, "*eke*", "IY|PA3|KK1");

        s = replace(s, "*eme*", "IY|MM");

        s = replace(s, "*ere*", "IY|RR2");

        s = replace(s, "*ese*", "IY|SS");

        s = replace(s, "*ete*", "IY|TT2");

        s = replace(s, "*iev*", "IH|EH|PA3|VV");

        s = replace(s, "*eve*", "IY|PA3|VV");

        s = replace(s, "*eze*", "IY|ZZ");

        s = replace(s, "*ibe*", "AY|PA2|BB2");

        s = replace(s, "*ice*", "AY|SS|SS");

        s = replace(s, "*ide*", "AY|DD1");

        s = replace(s, "*ife*", "AY|FF");

        s = replace(s, "*ige*", "IH|PA3|GG3");

        s = replace(s, "*ike*", "AY|KK2");

        s = replace(s, "*ile*", "AY|LL");

        s = replace(s, "*ime*", "AY|MM");

        s = replace(s, "*ine*", "AY|NN1");

        s = replace(s, "*ipe*", "AY|PP");

        s = replace(s, "*ire*", "AY|RR2");

        s = replace(s, "*ise*", "AY|SS");

        s = replace(s, "*ite*", "AY|TT2");

        s = replace(s, "*usive*", "UW1|SS|IH|PA3|VV");

        s = replace(s, "*asive*", "EY|SS|IH|PA3|VV");

        s = replace(s, "*ive*", "AY|PA3|VV");

        s = replace(s, "*ize*", "AY|ZZ");

        s = replace(s, "*obe*", "OW|PA2|BB2");

        s = replace(s, "*ode*", "OW|DD1");

        s = replace(s, "*oke*", "OW|PA2|KK1");

        s = replace(s, "*ole*", "OW|LL");

        s = replace(s, "*ome*", "OW|MM");

        s = replace(s, "*one*", "OW|NN1");

        s = replace(s, "*ope*", "OW|PP");

        s = replace(s, "*ore*", "OR");

        s = replace(s, "*pn*", "NN1");

        s = replace(s, "*kn*", "NN1");

        s = replace(s, "*th*", "TH");

        s = replace(s, "*ch*", "CH");

        s = replace(s, "*sh*", "SH");

        s = replace(s, "*ck*", "KK2");

        s = replace(s, "*or*", "OR");

        s = replace(s, "*ose*", "OW|SS");

        s = replace(s, "*ote*", "OW|TT2");

        s = replace(s, "*ove*", "OW|PA3|VV");

        s = replace(s, "*owe*", "OW");

        s = replace(s, "*oze*", "OW|ZZ");

        s = replace(s, "*ube*", "UW1|PA2|BB2");

        s = replace(s, "*uce*", "UW1|SS|SS");

        s = replace(s, "*ude*", "UW1|DD1");

        s = replace(s, "*uge*", "UW1|PA2|JH");

        s = replace(s, "*uke*", "UW1|PA3|KK1");

        s = replace(s, "*ule*", "UW1|LL");

        s = replace(s, "*ume*", "UW1|MM");

        s = replace(s, "*une*", "UW1|NN1");

        s = replace(s, "*upe*", "UW1|PP");

        s = replace(s, "*ure*", "UW1|RR2");

        s = replace(s, "*usa*", "AX|SS|AA");

        s = replace(s, "use*", "YY1|UW2|SS");

        s = replace(s, "*use*", "UW1|SS");

        s = replace(s, "usu*", "YY1|UW2|SS|YY1|UH");

        s = replace(s, "*ute*", "UW1|TT2");

        s = replace(s, "*uze*", "UW1|ZZ");

        s = replace(s, "*air*", "EH|XR");

        s = replace(s, "*all *", "OR|LL|PA4");

        s = replace(s, "*all*", "AA|LL");

        s = replace(s, "*aria*", "EY|RR2|YR");

        s = replace(s, "*imple*", "IH|MM|PP|LL");

        s = replace(s, "*ear*", "IY|XR");

        s = replace(s, "*eat*", "EY|TT2");

        s = replace(s, "*ar*", "AR");

        s = replace(s, "*ic*", "IH|KK3");

        s = replace(s, "*er*", "ER2");

        s = replace(s, "*ew*", "YY1|UW2");

        s = replace(s, "*ind*", "IH|NN1|DD1");

        s = replace(s, "*ow*", "OW");

        s = replace(s, "*aa*", "AA|AR");

        s = replace(s, "*ae*", "AA|AE");

        s = replace(s, "*ai*", "EY");

        s = replace(s, "*au*", "OR");

        s = replace(s, "*ea*", "IY|AA");

        s = replace(s, "*ee*", "IY");

        s = replace(s, "*ei*", "EH|IH");

        s = replace(s, "*eo*", "EH|OW");

        s = replace(s, "*eu*", "YY1|UW2");

        s = replace(s, "*ia*", "YR");

        s = replace(s, "*ie*", "IY");

        s = replace(s, "*is*", "IH|SS");

        s = replace(s, "*io*", "ee|oo");

        s = replace(s, "*oa*", "OW");

        s = replace(s, "*oe*", "OW");

        s = replace(s, "*oi*", "OY");

        s = replace(s, "*oo*", "UW2");

        s = replace(s, "*ou*", "AW");

        s = replace(s, "*ua*", "AX|AE");

        s = replace(s, "*ue*", "UW2");

        s = replace(s, "*ui*", "UW2");

        s = replace(s, "*bb*", "BB2");

        s = replace(s, "*cc*", "KK1|SS");

        s = replace(s, "*dd*", "DD");

        s = replace(s, "*ff*", "FF");

        s = replace(s, "*gg*", "GG1");

        s = replace(s, "*ll*", "LL");

        s = replace(s, "*mm*", "MM");

        s = replace(s, "*nn*", "NN1");

        s = replace(s, "*pp*", "PP");

        s = replace(s, "*ss*", "SS");

        s = replace(s, "*tt*", "TT1");

        s = replace(s, "*zz*", "ZZ");

        s = replace(s, "*my*", "MM|AY");

        s = replace(s, "*we*", "WW|IY");

        s = replace(s, "*to*", "TT2|UW2");

        s = replace(s, "*or*", "OR");

        s = replace(s, "ok", "OW|KK1|EY");

        s = replace(s, "* ok *", "OW|KK1|EY");

        s = replace(s, "* ok", "OW|KK1|EY");

        s = replace(s, "*y*", "YY1");

        s = replace(s, "*a*", "AA");

        s = replace(s, "*e", "PA3");

        s = replace(s, "*e*", "EH");

        s = replace(s, "i*", "AY|PA3");

        s = replace(s, "* i *", "PA4|AY|PA4");

        s = replace(s, "*i*", "IH");

        s = replace(s, "*o*", "OW");

        s = replace(s, "*q*", "KK2|WW");

        s = replace(s, "*u*", "UH");

        s = replace(s, "*b*", "BB2");

        s = replace(s, "c*", "KK2");

        s = replace(s, "*c*", "SS");

        s = replace(s, "d*", "DD1");

        s = replace(s, "*d", "DD1");

        s = replace(s, "*ds", "d|z");

        s = replace(s, "*d*", "DD1");

        s = replace(s, "*f*", "FF");

        s = replace(s, "*g*", "GG1");

        s = replace(s, "*h*", "HH1");

        s = replace(s, "*j*", "JH");

        s = replace(s, "*k*", "KK1");

        s = replace(s, "l*", "LL");

        s = replace(s, "*l*", "LL");

        s = replace(s, "*m*", "MM");

        s = replace(s, "*n*", "NN1");

        s = replace(s, "*p*", "PP");

        s = replace(s, "*r*", "RR2");

        s = replace(s, "*s*", "SS");

        s = replace(s, "*t*", "TT1");

        s = replace(s, "*v*", "VV");

        s = replace(s, "*w*", "WW");

        s = replace(s, "*x*", "KK3|SS");

        s = replace(s, "*z*", "ZZ");

        s = replace(s, "* *", "PA4");

        s = replace(s, "*.*", "PA4");

        s = replace(s, "*,*", "PA4");

        s = replace(s, "*;*", "PA4");

        s = replace(s, "*:*", "PA4");

        s = replace(s, "*-*", "PA3");

        String s1 = "";

        for (StringTokenizer stringtokenizer = new StringTokenizer(s, "[]"); stringtokenizer.hasMoreTokens() {

            s1 = s1 + stringtokenizer.nextToken();

            if (stringtokenizer.hasMoreTokens()) {

                s1 = s1 + "|";

            }

        }


        return s1+"|PA4|PA4|PA4|PA4|PA4|PA4|PA4|PA4";

    }


    private String replace(String s, String s1, String s2) {

        String s3 = s;

        if (s1.startsWith("*") && s1.endsWith("*")) {

            boolean flag = false;

            s1 = s1.substring(1, s1.length() - 1);

            int i = 0;

            boolean flag1 = true;

            while (flag1) {

                int j = s.indexOf(s1, i);

                if (j >= 0) {

                    boolean flag2 = true;

                    for (int k = j; k >= 0; k--) {

                        String s4 = s.substring(k, k + 1);

                        if (s4.equals("[")) {

                            flag2 = false;

                            break;

                        }

                        if (s4.equals("]")) {

                            break;

                        }

                    }


                    if (flag2) {

                        s3 = "";

                        if (j > 0) {

                            s3 = s3 + s.substring(0, j);

                        }

                        s3 = s3 + "[" + s2 + "]";

                        if (j + s1.length() < s.length()) {

                            s3 = s3 + s.substring(j + s1.length(), s.length());

                        }

                        flag1 = false;

                        flag = true;

                    } else {

                        i = j + 1;

                    }

                } else {

                    flag1 = false;

                }

            }

            if (flag) {

                s3 = replace(s3, "*" + s1 + "*", s2);

            }

        } else if (s1.endsWith("*")) {

            s1 = s1.substring(0, s1.length() - 1);

            if (s.startsWith(s1)) {

                s3 = "[" + s2 + "]" + s.substring(s1.length(), s.length());

            }

        } else if (s1.startsWith("*")) {

            s1 = s1.substring(1, s1.length());

            if (s.endsWith(s1)) {

                s3 = s.substring(0, s.length() - s1.length()) + "[" + s2 + "]";

            }

        } else if (s.equals(s1)) {

            s3 = "[" + s2 + "]";

        }

        return s3;

    }

}


[/code]

Bearbeitet von Devilmarkus
Geschrieben

Funktionieren tut es jetzt, aber der ausgegebene Text ist so gut wie nicht verständlich (egal ob Englisch oder Deutsch).

Mehr als ein Gimmick ist das aber nicht. Es ist halt nicht mehr als ein Replace des eingegebenen Textes in entsprechende Units, die dann aus fertigen Sounddateien zusammengesetzt werden. Du macht, wie im Code zu sehen, ist ein einfaches Replacing, eine Qualitätssteigerung wäre es schon, wenn Du

wie unter Sprachsynthese ? Wikipedia beschrieben einen gewichteten Entscheidungsbaum verwendet hättest.

Was möchtest Du denn mit dem Thread wissen? Es ist kein Problem genannt

Geschrieben

@flashpixx:

Wissen möchte ich eigentlich garnichts.

Ich wollte nur mal diese "Spielerei" verbreiten.

- Wegen des "Verstehens":

Die Replacements sind annähernd wie die des Dk'tronics Sprachsynthesizers.

Ich habe diesen Sprachsynthesizer auch in meinem CPC-Emulator, wo halt die Hardware angesteuert werden kann.

Ein Beispiel:

Dabei klingt die emulierte Sprachausgabe exakt dem Original.

Geschrieben

- Wegen des "Verstehens"

Aber dann wäre zurecht der Einwand, warum beschränkst Du Dich auf ein System das ~40 Jahre alt ist. Vor allein ein gewichteter Decision Tree ist

kein Problem in der Umsetzung.

Niemand wird heute einen Compiler vollständig eigenständig entwerfen, Parser und Scanner können direkt aus cf-Grammatiken effizient generiert werden oder ein OS in Assembler programmieren

Geschrieben (bearbeitet)

Wie gesagt dieses Programm ist nur Spielerei.

In dem Sprachsynthesizer, welchen ich in meinem Emulator verwende, benötige ich keinen "Converter" dort kann ich gezielt die 64 Phonemes einsetzen, da die Hardware ansich den Wert des abzuspielenden Phonemes an einen Port sendet.

Dort verwende ich dann nur einen Code wie Diesen:

    public  String Translate(String input){

        String out="";

        if (DEBUG)

            System.out.println("input:"+input);

        int len = input.length()/3;

        Phoneme = new String[len];

        bytes = new int[len];

        for (int i = 0; i < len; i++) {

            String got = input;

            Phoneme[i] = got.substring(0,2);

            input = input.substring(3);

        }

        for (int i = 0; i < len; i++){

            try{

                switch (hexValue(Phoneme[i])){

                    case 0: Phoneme[i] = "PA1"; break;

                    case 1: Phoneme[i] = "PA2"; break;

                    case 2: Phoneme[i] = "PA3"; break;

                    case 3: Phoneme[i] = "PA4"; break;

                    case 4: Phoneme[i] = "PA5"; break;

                    case 5: Phoneme[i] = "OY"; break;

                    case 6: Phoneme[i] = "AY"; break;

                    case 7: Phoneme[i] = "EH"; break;

                    case 8: Phoneme[i] = "KK3"; break;

                    case 9: Phoneme[i] = "PP"; break;

                    case 10: Phoneme[i] = "JH"; break;

                    case 11: Phoneme[i] = "NN1"; break;

                    case 12: Phoneme[i] = "IH"; break;

                    case 13: Phoneme[i] = "TT2"; break;

                    case 14: Phoneme[i] = "RR1"; break;

                    case 15: Phoneme[i] = "AX"; break;

                    case 16: Phoneme[i] = "MM"; break;

                    case 17: Phoneme[i] = "TT1"; break;

                    case 18: Phoneme[i] = "DH1"; break;

                    case 19: Phoneme[i] = "IY"; break;

                    case 20: Phoneme[i] = "EY"; break;

                    case 21: Phoneme[i] = "DD1"; break;

                    case 22: Phoneme[i] = "UW1"; break;

                    case 23: Phoneme[i] = "AO"; break;

                    case 24: Phoneme[i] = "AA"; break;

                    case 25: Phoneme[i] = "YY2"; break;

                    case 26: Phoneme[i] = "AE"; break;

                    case 27: Phoneme[i] = "HH1"; break;

                    case 28: Phoneme[i] = "BB1"; break;

                    case 29: Phoneme[i] = "TH"; break;

                    case 30: Phoneme[i] = "UH"; break;

                    case 31: Phoneme[i] = "UW2"; break;

                    case 32: Phoneme[i] = "AW"; break;

                    case 33: Phoneme[i] = "DD2"; break;

                    case 34: Phoneme[i] = "GG3"; break;

                    case 35: Phoneme[i] = "VV"; break;

                    case 36: Phoneme[i] = "GG1"; break;

                    case 37: Phoneme[i] = "SH"; break;

                    case 38: Phoneme[i] = "ZH"; break;

                    case 39: Phoneme[i] = "RR2"; break;

                    case 40: Phoneme[i] = "FF"; break;

                    case 41: Phoneme[i] = "KK2"; break;

                    case 42: Phoneme[i] = "KK1"; break;

                    case 43: Phoneme[i] = "ZZ"; break;

                    case 44: Phoneme[i] = "NG"; break;

                    case 45: Phoneme[i] = "LL"; break;

                    case 46: Phoneme[i] = "WW"; break;

                    case 47: Phoneme[i] = "XR"; break;

                    case 48: Phoneme[i] = "WH"; break;

                    case 49: Phoneme[i] = "YY1"; break;

                    case 50: Phoneme[i] = "CH"; break;

                    case 51: Phoneme[i] = "ER1"; break;

                    case 52: Phoneme[i] = "ER2"; break;

                    case 53: Phoneme[i] = "OW"; break;

                    case 54: Phoneme[i] = "DH2"; break;

                    case 55: Phoneme[i] = "SS"; break;

                    case 56: Phoneme[i] = "NN2"; break;

                    case 57: Phoneme[i] = "HH2"; break;

                    case 58: Phoneme[i] = "OR"; break;

                    case 59: Phoneme[i] = "AR"; break;

                    case 60: Phoneme[i] = "YR"; break;

                    case 61: Phoneme[i] = "GG2"; break;

                    case 62: Phoneme[i] = "EL"; break;

                    case 63: Phoneme[i] = "BB2"; break;

                    default: Phoneme[i]="ignore"; break;

                }

            } catch (Exception e){}

        }


        SpeechByte = "";

        out="|";

        for (int i = 0; i < len; i++)

            if (!Phoneme[i].equals("ignore")){

                out+=Phoneme[i]+"|";

            }

        say (out);

        return out;

    }

Bearbeitet von Devilmarkus

Dein Kommentar

Du kannst jetzt schreiben und Dich später registrieren. Wenn Du ein Konto hast, melde Dich jetzt an, um unter Deinem Benutzernamen zu schreiben.

Gast
Auf dieses Thema antworten...

×   Du hast formatierten Text eingefügt.   Formatierung wiederherstellen

  Nur 75 Emojis sind erlaubt.

×   Dein Link wurde automatisch eingebettet.   Einbetten rückgängig machen und als Link darstellen

×   Dein vorheriger Inhalt wurde wiederhergestellt.   Editor leeren

×   Du kannst Bilder nicht direkt einfügen. Lade Bilder hoch oder lade sie von einer URL.

Fachinformatiker.de, 2024 by SE Internet Services

fidelogo_small.png

Schicke uns eine Nachricht!

Fachinformatiker.de ist die größte IT-Community
rund um Ausbildung, Job, Weiterbildung für IT-Fachkräfte.

Fachinformatiker.de App

Download on the App Store
Get it on Google Play

Kontakt

Hier werben?
Oder sende eine E-Mail an

Social media u. feeds

Jobboard für Fachinformatiker und IT-Fachkräfte

×
×
  • Neu erstellen...