Reference documentation and code samples for the Cloud Text-to-Speech V1 Client class SynthesizeSpeechRequest.
The top-level message sent by the client for the SynthesizeSpeech method.
Generated from protobuf message google.cloud.texttospeech.v1.SynthesizeSpeechRequest
Namespace
Google \ Cloud \ TextToSpeech \ V1Methods
__construct
Constructor.
| Parameters | |
|---|---|
| Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ input |
SynthesisInput
Required. The Synthesizer requires either plain text or SSML as input. |
↳ voice |
VoiceSelectionParams
Required. The desired voice of the synthesized audio. |
↳ audio_config |
AudioConfig
Required. The configuration of the synthesized audio. |
↳ advanced_voice_options |
AdvancedVoiceOptions
Advanced voice options. |
getInput
Required. The Synthesizer requires either plain text or SSML as input.
| Returns | |
|---|---|
| Type | Description |
SynthesisInput|null |
|
hasInput
clearInput
setInput
Required. The Synthesizer requires either plain text or SSML as input.
| Parameter | |
|---|---|
| Name | Description |
var |
SynthesisInput
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getVoice
Required. The desired voice of the synthesized audio.
| Returns | |
|---|---|
| Type | Description |
VoiceSelectionParams|null |
|
hasVoice
clearVoice
setVoice
Required. The desired voice of the synthesized audio.
| Parameter | |
|---|---|
| Name | Description |
var |
VoiceSelectionParams
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getAudioConfig
Required. The configuration of the synthesized audio.
| Returns | |
|---|---|
| Type | Description |
AudioConfig|null |
|
hasAudioConfig
clearAudioConfig
setAudioConfig
Required. The configuration of the synthesized audio.
| Parameter | |
|---|---|
| Name | Description |
var |
AudioConfig
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
getAdvancedVoiceOptions
Advanced voice options.
| Returns | |
|---|---|
| Type | Description |
AdvancedVoiceOptions|null |
|
hasAdvancedVoiceOptions
clearAdvancedVoiceOptions
setAdvancedVoiceOptions
Advanced voice options.
| Parameter | |
|---|---|
| Name | Description |
var |
AdvancedVoiceOptions
|
| Returns | |
|---|---|
| Type | Description |
$this |
|
static::build
| Parameters | |
|---|---|
| Name | Description |
input |
SynthesisInput
Required. The Synthesizer requires either plain text or SSML as input. |
voice |
VoiceSelectionParams
Required. The desired voice of the synthesized audio. |
audioConfig |
AudioConfig
Required. The configuration of the synthesized audio. |
| Returns | |
|---|---|
| Type | Description |
SynthesizeSpeechRequest |
|