Interface SynthesisBackend.Sink

Enclosing interface:
SynthesisBackend

public static interface SynthesisBackend.Sink
Where synthesized PCM goes. pushAudio() may be called from any backend thread.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    end()
    Clean end of the utterance's audio.
    void
    error(String reason)
    Terminal failure; the reason reaches the log at the playback loop.
    boolean
    True once the component no longer wants the audio; producers should bail out early.
    void
    pushAudio(byte[] pcm)
    Append PCM at getSampleRate().
  • Method Details

    • pushAudio

      void pushAudio(byte[] pcm)
      Append PCM at getSampleRate(). Need not be frame aligned; zero-length arrays are ignored.
    • end

      void end()
      Clean end of the utterance's audio. Terminal.
    • error

      void error(String reason)
      Terminal failure; the reason reaches the log at the playback loop.
    • isAborted

      boolean isAborted()
      True once the component no longer wants the audio; producers should bail out early.