# Cloud Text-to-Speech V1 Client - Class MultiSpeakerVoiceConfig (2.8.0)

2.8.0 (latest) 2.7.0 2.6.0 2.5.1 2.4.0 2.3.0 2.2.2 2.0.1 1.12.2 1.11.0 1.10.0 1.9.1 1.8.5 1.7.2 1.6.1 1.5.6 1.4.5 Reference documentation and code samples for the Cloud Text-to-Speech V1 Client class MultiSpeakerVoiceConfig.

Configuration for a multi-speaker text-to-speech setup. Enables the use of up
to two distinct voices in a single synthesis request.

Generated from protobuf message `google.cloud.texttospeech.v1.MultiSpeakerVoiceConfig`

## Namespace

Google \\ Cloud \\ TextToSpeech \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ speaker_voice_configs` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-text-to-speech/latest/V1.MultispeakerPrebuiltVoice>` Required. A list of configurations for the voices of the speakers. Exactly two speaker voice configurations must be provided. |

### getSpeakerVoiceConfigs

Required. A list of configurations for the voices of the speakers. Exactly
two speaker voice configurations must be provided.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-text-to-speech/latest/V1.MultispeakerPrebuiltVoice>` |   |

### setSpeakerVoiceConfigs

Required. A list of configurations for the voices of the speakers. Exactly
two speaker voice configurations must be provided.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-text-to-speech/latest/V1.MultispeakerPrebuiltVoice>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |