æè¿ã®Chrome, Safariã®JavaScriptã«ã¯é³å£°åæAPIãå ¥ã£ã¦ãã¾ãã 使ãæ¹ã¯ç°¡åã§ãJavaScriptã³ã³ã½ã¼ã«ç㧠var msg = new SpeechSynthesisUtterance('ããã«ã¡ã¯!'); msg.lang = "ja-JP"; // è¨èªæå® window.speechSynthesis.speak(msg); ã®ããã«ããã ãã§åã£ã¦ããã¾ãã é³å£°ã¨ã³ã¸ã³ãå¤ãããã¨ãå¯è½ã§ãã使ããé³å£°ã®ä¸è¦§ã var voices = speechSynthesis.getVoices(); ã§åå¾ããã¨ãvoicesã«é³å£°ãªãã¸ã§ã¯ãã®ãªã¹ããè¿ã£ã¦ããã®ã§ããã®ä¸ã®langãnameãè¦ã¦ä½¿ããããã®ã msg.voice = voices[3]; ãªã©ã¨SpeechSynthesisUtteranceãªãã¸ã§ã¯ãã®voiceå±æ§ã«æå®ã
{{#tags}}- {{label}}
{{/tags}}