25
我正在使用文本到我的android應用程序中的語音。它與Google TTs和espeak工作良好,但是當我與三星TTS一起使用時,它給出以下異常。IllegalArgumentException:無效int:「操作系統」與三星tts
java.lang.IllegalArgumentException: Invalid int: "OS"
at android.os.Parcel.readException(Parcel.java:1429)
at android.os.Parcel.readException(Parcel.java:1379)
at android.speech.tts.ITextToSpeechService$Stub$Proxy.isLanguageAvailable(ITextToSpeechService.java:482)
at android.speech.tts.TextToSpeech$10.run(TextToSpeech.java:1084)
at android.speech.tts.TextToSpeech$10.run(TextToSpeech.java:1081)
at android.speech.tts.TextToSpeech$Connection.runAction(TextToSpeech.java:1329)
at android.speech.tts.TextToSpeech.runAction(TextToSpeech.java:570)
at android.speech.tts.TextToSpeech.runAction(TextToSpeech.java:561)
at android.speech.tts.TextToSpeech.isLanguageAvailable(TextToSpeech.java:1081)
對我來說,三星的設備返回true上isLanguageAvailable但在後來失敗,正是這種例外setLanguage() – 2017-02-20 07:17:25
@MartinVysny找到解決方法的任何運氣?我遇到了與setLanguage(...)相同的問題。 – Dogcat 2017-04-16 17:26:18
不好意思,對不起。我所想到的只是向用戶傳播,以便向三星發送垃圾郵件來解決這個問題;) – 2017-04-18 06:04:50