Commit fefef0f9 by ojw28 Committed by GitHub

Merge pull request #2183 from WeiChungChang/proposal-fix

Fix the issue when the sequence of PTS is out of order by bidirectional prediction for skipToKeyframeBefore()
parents 42c7ea42 63966a37
......@@ -786,9 +786,7 @@ public final class DefaultTrackOutput implements TrackOutput {
return C.POSITION_UNSET;
}
int lastWriteIndex = (relativeWriteIndex == 0 ? capacity : relativeWriteIndex) - 1;
long lastTimeUs = timesUs[lastWriteIndex];
if (timeUs > lastTimeUs) {
if (timeUs > largestQueuedTimestampUs) {
return C.POSITION_UNSET;
}
......
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