To specify any of the other speech synthesis (text-to-speech) voices installed on the user's system, use the Voice method (to find out which voices are installed on the system, call AllVoices). Each voice generates synthesized speech in a single language, as spoken in a specific country/region.īy default, a new SpeechSynthesizer object uses the current system voice (call DefaultVoice to find out what the default voice is). Only Microsoft-signed voices installed on the system can be used to generate speech with a SpeechSynthesizer. Stream = await synthesizer.SynthesizeTextToStreamAsync(text) ).FirstOrDefault() ? SpeechSynthesizer.DefaultVoice using (SpeechSynthesizer synthesizer = new SpeechSynthesizer())įrom voice in SpeechSynthesizer.AllVoices Here, we show how to select a gender for the voice ( VoiceInformation.Gender) by using either the first female voice ( VoiceGender) found, or just the default system voice ( SpeechSynthesizer.DefaultVoice), if no female voice is found. The default value is the current system voice.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |