mirror of
https://github.com/samsonjs/media.git
synced 2026-03-29 10:05:48 +00:00
Sanity check current position <= written frame position
This avoids spurious position reports following an underrun. Github: #1874 ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=170344399
This commit is contained in:
parent
7665571ff9
commit
a3a9c0f3b0
1 changed files with 1 additions and 0 deletions
|
|
@ -332,6 +332,7 @@ public final class DefaultAudioSink implements AudioSink {
|
|||
}
|
||||
}
|
||||
|
||||
positionUs = Math.min(positionUs, framesToDurationUs(getWrittenFrames()));
|
||||
return startMediaTimeUs + applySpeedup(positionUs);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue