Documentation

​
​

Development

User Acquisition

Monetization

Industry

Vivox Unity SDK

Vivox Unity SDK

Vivox
​
​
Vivox Unity SDK
  • Overview
  • Get started
  • Release notes
  • Developer guide
    • Set up your project
    • Create voice and text channels
    • Messaging
    • Player management
    • Device management
    • Audio management
    • Mobile development
    • Text-to-speech
      • Text-to-speech voice options
      • Text-to-speech destinations
      • Inject a text-to-speech message
      • Queue a text-to-speech message
      • Cancel a text-to-speech message
    • Speech-to-text
    • Real-time recording
    • Server-side-recording
    • Troubleshooting
  • Tutorials
  • Reference
  1. Vivox Unity SDK documentation
  2. Vivox Unity Developer Guide
  3. Speech-to-text audio transcription

Queue a text-to-speech message

Queue a text-to-speech message for audio output.
Read time 1 minute
Last updated 8 months ago

Some destinations offer a built-in queuing system. When a new message is injected and there is an ongoing message playing, then the new message is put into a queue. After the ongoing message finishes playing, the next message in the queue automatically starts to play.
// Start playing speech as soon as it is synthesized.VivoxService.Instance.TextToSpeechSendMessage("1st Message.", TextToSpeechMessageType.QueuedLocalPlayback);// After the first message finishes playback, this message starts.VivoxService.Instance.TextToSpeechSendMessage("2nd Message.", TextToSpeechMessageType.QueuedLocalPlayback);
A queue is shared between
TextToSpeechMessageType.QueuedRemoteTransmission
and
TextToSpeechMessageType.QueuedRemoteTransmissionWithLocalPlayback
. The destination
TextToSpeechMessageType.QueuedLocalPlayback
has its own queue.
A destination queue can hold up to 10 enqueued messages in addition to the message that is actively playing. If a message is added when a destination queue is full, the Vivox SDK discards the message and raises an InvalidOperationException (
VxErrorTTSDestinationQueueIsFull
). In this case, no text-to-speech related events are raised.

Copyright © 2026 Unity Technologies
LegalPrivacy PolicyCookiesDocumentation Terms of UseDo Not Sell or Share My Personal InformationYour Privacy Choices (Cookie Settings)

"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S and elsewhere (more info here). Other names or brands are trademarks of their respective owners.

Some pages are machine-translated for convenience, and may contain inaccuracies. In the event of conflicting information, the English version is authoritative.


    Report a problem with this page