MediaPipeTasksAudio Framework Reference

Structures

The following declarations are available globally.

  • Incremental mono PCM audio chunk emitted by TextToSpeech.synthesizeStream(_:options:).

    Declaration

    Swift

    struct AudioChunk: Sendable, Equatable
  • Self-contained mono PCM audio buffer returned by TextToSpeech.synthesize(_:options:).

    Declaration

    Swift

    struct AudioResult: Sendable, Equatable
  • Per-utterance synthesis overrides passed to TextToSpeech.synthesize(_:options:) and TextToSpeech.synthesizeStream(_:options:). Both fields default to nil so non-English voices (e.g. "ef_dora", "zf_xiaobei") automatically infer their native language from the voice metadata.

    Declaration

    Swift

    struct SynthesisOptions: Sendable, Equatable
  • MediaPipe Tasks-harmonized base options for .litertlm model loading and hardware delegation.

    Declaration

    Swift

    struct TTSBaseOptions: Sendable, Equatable
  • Task initialization options for TextToSpeech (backed by LiteRT-LM Omni Kokoro-82M).

    Declaration

    Swift

    struct TextToSpeechOptions: Sendable, Equatable
  • Voice metadata descriptor returned by TextToSpeech.listVoices().

    Declaration

    Swift

    struct VoiceInfo: Sendable, Equatable
  • Word-level timing alignment mapping an input word to audio seconds.

    Declaration

    Swift

    struct WordTimestamp: Sendable, Equatable