Commit 0901fe6e by olly Committed by Ian Baker

Remove internal renderer audio session ID propagation

Overriding this method will never be necessary or advisable once we
improve routing of audio session IDs

Issue: #8190
PiperOrigin-RevId: 350146302
parent 6d2d2e31
......@@ -20,7 +20,6 @@ import static com.google.android.exoplayer2.decoder.DecoderReuseEvaluation.DISCA
import static com.google.android.exoplayer2.decoder.DecoderReuseEvaluation.REUSE_RESULT_NO;
import static java.lang.Math.max;
import android.media.audiofx.Virtualizer;
import android.os.Handler;
import android.os.SystemClock;
import androidx.annotation.CallSuper;
......@@ -313,18 +312,6 @@ public abstract class DecoderAudioRenderer<
}
}
/**
* Called when the audio session id becomes known. The default implementation is a no-op. One
* reason for overriding this method would be to instantiate and enable a {@link Virtualizer} in
* order to spatialize the audio channels. For this use case, any {@link Virtualizer} instances
* should be released in {@link #onDisabled()} (if not before).
*
* <p>See {@link AudioSink.Listener#onAudioSessionId(int)}.
*/
protected void onAudioSessionId(int audioSessionId) {
// Do nothing.
}
/** See {@link AudioSink.Listener#onPositionDiscontinuity()}. */
@CallSuper
protected void onPositionDiscontinuity() {
......@@ -730,7 +717,6 @@ public abstract class DecoderAudioRenderer<
@Override
public void onAudioSessionId(int audioSessionId) {
eventDispatcher.audioSessionId(audioSessionId);
DecoderAudioRenderer.this.onAudioSessionId(audioSessionId);
}
@Override
......
......@@ -26,7 +26,6 @@ import android.media.AudioFormat;
import android.media.MediaCodec;
import android.media.MediaCrypto;
import android.media.MediaFormat;
import android.media.audiofx.Virtualizer;
import android.os.Handler;
import androidx.annotation.CallSuper;
import androidx.annotation.Nullable;
......@@ -475,18 +474,6 @@ public class MediaCodecAudioRenderer extends MediaCodecRenderer implements Media
}
}
/**
* Called when the audio session id becomes known. The default implementation is a no-op. One
* reason for overriding this method would be to instantiate and enable a {@link Virtualizer} in
* order to spatialize the audio channels. For this use case, any {@link Virtualizer} instances
* should be released in {@link #onDisabled()} (if not before).
*
* <p>See {@link AudioSink.Listener#onAudioSessionId(int)}.
*/
protected void onAudioSessionId(int audioSessionId) {
// Do nothing.
}
/** See {@link AudioSink.Listener#onPositionDiscontinuity()}. */
@CallSuper
protected void onPositionDiscontinuity() {
......@@ -829,7 +816,6 @@ public class MediaCodecAudioRenderer extends MediaCodecRenderer implements Media
@Override
public void onAudioSessionId(int audioSessionId) {
eventDispatcher.audioSessionId(audioSessionId);
MediaCodecAudioRenderer.this.onAudioSessionId(audioSessionId);
}
@Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment