Class AudioTrack

java.lang.Object
com.twilio.video.AudioTrack
All Implemented Interfaces:
Track
Direct Known Subclasses:
LocalAudioTrack, RemoteAudioTrack

public abstract class AudioTrack extends Object implements Track
  • Field Details

    • audioSinks

      protected final HashMap<AudioSink,com.twilio.video.AudioSinkProxy> audioSinks
  • Method Details

    • isEnabled

      public boolean isEnabled()
      Check if this audio track is enabled.
      Specified by:
      isEnabled in interface Track
      Returns:
      true if track is enabled.
    • getName

      @NonNull public String getName()
      Returns the audio track name. A pseudo random string is returned if no track name was specified.
      Specified by:
      getName in interface Track
    • addSink

      public void addSink(@NonNull AudioSink audioSink)
      Adds a sink to the Track. Sinks consume raw audio samples for further processing or storage.
    • removeSink

      public void removeSink(@NonNull AudioSink audioSink)
      Removes a sink from the Track.
      Parameters:
      audioSink - An object that implements the `AudioSink` interface.