mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 23:35:34 +00:00
Bug 1481397 - P1. Properly recalculate highest start timestamp when samples are removed. r=bryce
Summary: When removing frames from the trackbuffer we may remove frames outside the original removal interval as we must remove all frames depending on the removed frames. Differential Revision: https://phabricator.services.mozilla.com/D2837
This commit is contained in:
parent
f3e5678c1a
commit
5e17996c2a
@ -2105,7 +2105,8 @@ TrackBuffersManager::RemoveFrames(const TimeIntervals& aIntervals,
|
|||||||
data.RemoveElementsAt(firstRemovedIndex.ref(),
|
data.RemoveElementsAt(firstRemovedIndex.ref(),
|
||||||
lastRemovedIndex - firstRemovedIndex.ref() + 1);
|
lastRemovedIndex - firstRemovedIndex.ref() + 1);
|
||||||
|
|
||||||
if (aIntervals.GetEnd() >= aTrackData.mHighestStartTimestamp) {
|
if (removedIntervals.GetEnd() >= aTrackData.mHighestStartTimestamp &&
|
||||||
|
removedIntervals.GetStart() <= aTrackData.mHighestStartTimestamp) {
|
||||||
// The sample with the highest presentation time got removed.
|
// The sample with the highest presentation time got removed.
|
||||||
// Rescan the trackbuffer to determine the new one.
|
// Rescan the trackbuffer to determine the new one.
|
||||||
TimeUnit highestStartTime;
|
TimeUnit highestStartTime;
|
||||||
|
Loading…
Reference in New Issue
Block a user