From 87f1b4252ec2d342a153e49aac19455cb91655d1 Mon Sep 17 00:00:00 2001 From: tonihei Date: Thu, 5 Oct 2023 04:30:38 -0700 Subject: [PATCH] Update documentation wrongly referencing the decode-only flag #minor-release PiperOrigin-RevId: 570973457 --- .../java/androidx/media3/decoder/SimpleDecoder.java | 10 +++++----- .../exoplayer/mediacodec/MediaCodecRenderer.java | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/libraries/decoder/src/main/java/androidx/media3/decoder/SimpleDecoder.java b/libraries/decoder/src/main/java/androidx/media3/decoder/SimpleDecoder.java index 557c66cd8f..3f19b844b5 100644 --- a/libraries/decoder/src/main/java/androidx/media3/decoder/SimpleDecoder.java +++ b/libraries/decoder/src/main/java/androidx/media3/decoder/SimpleDecoder.java @@ -338,11 +338,11 @@ public abstract class SimpleDecoder< * Decodes the {@code inputBuffer} and stores any decoded output in {@code outputBuffer}. * * @param inputBuffer The buffer to decode. - * @param outputBuffer The output buffer to store decoded data. The flag {@link - * C#BUFFER_FLAG_DECODE_ONLY} will be set if the same flag is set on {@code inputBuffer}, but - * may be set/unset as required. If the flag is set when the call returns then the output - * buffer will not be made available to dequeue. The output buffer may not have been populated - * in this case. + * @param outputBuffer The output buffer to store decoded data. The output buffer will not be made + * available to dequeue if its {@link DecoderOutputBuffer#timeUs} is not {@linkplain + * #isAtLeastOutputStartTimeUs at least the output start time} or when it's marked with {@link + * DecoderOutputBuffer#shouldBeSkipped}. The output buffer may not have been populated in + * these cases. * @param reset Whether the decoder must be reset before decoding. * @return A decoder exception if an error occurred, or null if decoding was successful. */ diff --git a/libraries/exoplayer/src/main/java/androidx/media3/exoplayer/mediacodec/MediaCodecRenderer.java b/libraries/exoplayer/src/main/java/androidx/media3/exoplayer/mediacodec/MediaCodecRenderer.java index c8e0570ee2..16a62ded06 100644 --- a/libraries/exoplayer/src/main/java/androidx/media3/exoplayer/mediacodec/MediaCodecRenderer.java +++ b/libraries/exoplayer/src/main/java/androidx/media3/exoplayer/mediacodec/MediaCodecRenderer.java @@ -2054,8 +2054,8 @@ public abstract class MediaCodecRenderer extends BaseRenderer { * @param sampleCount The number of samples extracted from the sample queue in the buffer. This * allows handling multiple samples as a batch for efficiency. * @param bufferPresentationTimeUs The presentation time of the output buffer in microseconds. - * @param isDecodeOnlyBuffer Whether the buffer was marked with {@link C#BUFFER_FLAG_DECODE_ONLY} - * by the source. + * @param isDecodeOnlyBuffer Whether the buffer timestamp is less than the intended playback start + * position. * @param isLastBuffer Whether the buffer is known to contain the last sample of the current * stream. This flag is set on a best effort basis, and any logic relying on it should degrade * gracefully to handle cases where it's not set.