FragmentState 构造函数
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
构造一个新实例 FragmentState。
public:
FragmentState(System::Speech::Synthesis::TtsEngine::TtsEngineAction action, int langId, int emphasis, int duration, System::Speech::Synthesis::TtsEngine::SayAs ^ sayAs, System::Speech::Synthesis::TtsEngine::Prosody ^ prosody, cli::array <char> ^ phonemes);
public FragmentState(System.Speech.Synthesis.TtsEngine.TtsEngineAction action, int langId, int emphasis, int duration, System.Speech.Synthesis.TtsEngine.SayAs? sayAs, System.Speech.Synthesis.TtsEngine.Prosody? prosody, char[] phonemes);
public FragmentState(System.Speech.Synthesis.TtsEngine.TtsEngineAction action, int langId, int emphasis, int duration, System.Speech.Synthesis.TtsEngine.SayAs sayAs, System.Speech.Synthesis.TtsEngine.Prosody prosody, char[] phonemes);
new System.Speech.Synthesis.TtsEngine.FragmentState : System.Speech.Synthesis.TtsEngine.TtsEngineAction * int * int * int * System.Speech.Synthesis.TtsEngine.SayAs * System.Speech.Synthesis.TtsEngine.Prosody * char[] -> System.Speech.Synthesis.TtsEngine.FragmentState
Public Sub New (action As TtsEngineAction, langId As Integer, emphasis As Integer, duration As Integer, sayAs As SayAs, prosody As Prosody, phonemes As Char())
参数
- action
- TtsEngineAction
指定语音合成操作的 TtsEngineAction 枚举的成员。
- langId
- Int32
正在使用的语言的 ID。 对应于 XML xml:lang 属性。
- emphasis
- Int32
要应用于语音输出或暂停的强调。
- duration
- Int32
分配用来说文本 TextFragment的时间。
- sayAs
- SayAs
类的成员 SayAs ,指示准确呈现包含文本所需的文本 TextFragment 类型和详细信息级别。
对应于 <say-as> SSML 规范中的 XML 标记
参数可以是 null.
- phonemes
- Char[]
一个 char 对象数组,使用国际拼音字母表(IPA)规范为包含 TextFragment的文本提供拼音发音。
对应于 <phoneme> SSML 规范中的 XML 标记。
此参数可以是 null.
注解
通常,应用程序不直接构造 FragmentState 对象。 FragmentState而是使用名称空间的成员System.Speech.Synthesis的应用程序创建实例。
TtsEngineAction如果参数Silence指定的action值为,则emphasis由该参数提供的值是:
如果为正值,则暂停的时间(以毫秒为单位)
如果为枚举成员的 EmphasisBreak 负数
TtsEngineAction如果参数指定的action值不是Silence,则emphasis参数的类型必须为 。EmphasisWord
如果自变量的值duration和属性或Prosody由该参数指定的prosody对象不同,则使用对象Prosody上的Duration值。