getSpeechRate()? (或如何分辨什么TTS率目前定为)目前、getSpeechRate、TTS

2023-09-07 13:06:52 作者:- 爱已成碍。

TextToSpeech 有一种方法来设置语速: setSpeechRate()。但它不具有查询当前速度的相对方法

TextToSpeech has a way to set the speech rate: setSpeechRate(). But it doesn't have an opposite method of querying the current speed.

有没有一种方法来查询系统该值?

Is there a way to query the system for that value?

推荐答案

您可能会得到默认的TTS语音率

You may get default TTS speech rate

Settings.Secure.getInt(getContentResolver(), Settings.Secure.TTS_DEFAULT_RATE, 100) / 100f;