зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1386478 - don't cap the return value of GetEndTime(). r=jya
A chained ogg file contains multiple streams and timestamps will not monolithically increase. The current code will cap AudioEndTime() to the end time of the 1st stream and currentTime won't be updated correctly when playback position reaches the 2nd stream or later ones. http://searchfox.org/mozilla-central/rev/bbc1c59e460a27b20929b56489e2e55438de81fa/dom/media/MediaDecoderStateMachine.cpp#3636-3637 MozReview-Commit-ID: DbIspYmEjVv --HG-- extra : rebase_source : 20004ae6c6d4e15dc8aeebf646efc62342514d24
This commit is contained in:
Родитель
7c6e2bd80c
Коммит
108a5c3b92
|
@ -233,9 +233,7 @@ AudioSink::GetEndTime() const
|
|||
NS_WARNING("Int overflow calculating audio end time");
|
||||
return TimeUnit::Zero();
|
||||
}
|
||||
// As we may be resampling, rounding errors may occur. Ensure we never get
|
||||
// past the original end time.
|
||||
return std::min(mLastEndTime, played);
|
||||
return played;
|
||||
}
|
||||
|
||||
UniquePtr<AudioStream::Chunk>
|
||||
|
|
Загрузка…
Ссылка в новой задаче