pub struct SpeechConfig {
pub voice_config: Option<VoiceConfig>,
pub multi_speaker_voice_config: Option<MultiSpeakerVoiceConfig>,
}
Expand description
Configuration for speech generation (text-to-speech)
Fields§
§voice_config: Option<VoiceConfig>
Single voice configuration
multi_speaker_voice_config: Option<MultiSpeakerVoiceConfig>
Multi-speaker voice configuration
Implementations§
Source§impl SpeechConfig
impl SpeechConfig
Sourcepub fn single_voice(voice_name: impl Into<String>) -> Self
pub fn single_voice(voice_name: impl Into<String>) -> Self
Create a new speech config with a single voice
Sourcepub fn multi_speaker(speakers: Vec<SpeakerVoiceConfig>) -> Self
pub fn multi_speaker(speakers: Vec<SpeakerVoiceConfig>) -> Self
Create a new speech config with multiple speakers
Trait Implementations§
Source§impl Clone for SpeechConfig
impl Clone for SpeechConfig
Source§fn clone(&self) -> SpeechConfig
fn clone(&self) -> SpeechConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SpeechConfig
impl Debug for SpeechConfig
Source§impl<'de> Deserialize<'de> for SpeechConfig
impl<'de> Deserialize<'de> for SpeechConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for SpeechConfig
impl PartialEq for SpeechConfig
Source§impl Serialize for SpeechConfig
impl Serialize for SpeechConfig
impl StructuralPartialEq for SpeechConfig
Auto Trait Implementations§
impl Freeze for SpeechConfig
impl RefUnwindSafe for SpeechConfig
impl Send for SpeechConfig
impl Sync for SpeechConfig
impl Unpin for SpeechConfig
impl UnwindSafe for SpeechConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more