зеркало из https://github.com/mozilla/gecko-dev.git
Bug 813190 - Stop media streams from hanging onto the last played media frame indefinitely. r=roc
This commit is contained in:
Родитель
9b5d35c82d
Коммит
6cfb1a6c03
|
@ -833,6 +833,7 @@ MediaStreamGraphImpl::UpdateCurrentTime()
|
|||
if (stream->mFinished && !stream->mNotifiedFinished &&
|
||||
stream->mBufferStartTime + stream->GetBufferEnd() <= nextCurrentTime) {
|
||||
stream->mNotifiedFinished = true;
|
||||
stream->mLastPlayedVideoFrame.SetNull();
|
||||
for (uint32_t j = 0; j < stream->mListeners.Length(); ++j) {
|
||||
MediaStreamListener* l = stream->mListeners[j];
|
||||
l->NotifyFinished(this);
|
||||
|
@ -1296,7 +1297,9 @@ MediaStreamGraphImpl::PlayVideo(MediaStream* aStream)
|
|||
NS_NewRunnableMethod(output, &VideoFrameContainer::Invalidate);
|
||||
NS_DispatchToMainThread(event, NS_DISPATCH_NORMAL);
|
||||
}
|
||||
aStream->mLastPlayedVideoFrame = *frame;
|
||||
if (!aStream->mNotifiedFinished) {
|
||||
aStream->mLastPlayedVideoFrame = *frame;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
|
Загрузка…
Ссылка в новой задаче