Class TeeAudioProcessor

  • All Implemented Interfaces:

    public final class TeeAudioProcessor
    extends BaseAudioProcessor
    Deprecated. is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.
    Audio processor that outputs its input unmodified and also outputs its input to a given sink. This is intended to be used for diagnostics and debugging.

    This audio processor can be inserted into the audio processor chain to access audio data before/after particular processing steps have been applied. For example, to get audio output after playback speed adjustment and silence skipping have been applied it is necessary to pass a custom AudioProcessorChain when creating the audio sink, and include this audio processor after all other audio processors.

    • Constructor Detail

    • Method Detail

      • queueInput

        public void queueInput​(ByteBuffer inputBuffer)
        Description copied from interface: AudioProcessor
        Queues audio data between the position and limit of the inputBuffer for processing. After calling this method, processed output may be available via AudioProcessor.getOutput(). Calling queueInput(ByteBuffer) again invalidates any pending output.
        inputBuffer - The input buffer to process. It must be a direct byte buffer with native byte order. Its contents are treated as read-only. Its position will be advanced by the number of bytes consumed (which may be zero). The caller retains ownership of the provided buffer.
      • onFlush

        protected void onFlush()
        Description copied from class: BaseAudioProcessor
        Called when the processor is flushed, directly or as part of resetting.
        onFlush in class BaseAudioProcessor