Commit 63966a37 by WeiChungChang

Fix the issue when the sequence of PTS is out of order by bidirectional…

Fix the issue when the sequence of PTS is out of order by bidirectional prediction for skipToKeyframeBefore()
parent e4bafd96
......@@ -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