Commit 3e6efe7e by samrobinson Committed by Oliver Woodman

Fix outputFormat not being assigned after position is reset.

PiperOrigin-RevId: 292350437
parent ffabb9f6
......@@ -667,6 +667,12 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
outputStreamEnded = false;
pendingOutputEndOfStream = false;
flushOrReinitializeCodec();
// If there is a format change on the input side still pending propagation to the output, we
// need to queue a format next time a buffer is read. This is because we may not read a new
// input format after the position reset.
if (formatQueue.size() > 0) {
waitingForFirstSampleInFormat = true;
}
formatQueue.clear();
}
......
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