Browse Source

Prevent the currently displayed video frame from changing if the video is paused

If you'd seek while the video was paused, you'd see the next frame of the video.
Bart van Strien 6 years ago
parent
commit
7b7d03721c
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/modules/video/theora/TheoraVideoStream.cpp

+ 3 - 0
src/modules/video/theora/TheoraVideoStream.cpp

@@ -293,6 +293,9 @@ bool TheoraVideoStream::swapBuffers()
 	if (demuxer.isEos())
 	if (demuxer.isEos())
 		return false;
 		return false;
 
 
+	if (!frameSync->isPlaying())
+		return false;
+
 	love::thread::Lock l(bufferMutex);
 	love::thread::Lock l(bufferMutex);
 	if (!frameReady)
 	if (!frameReady)
 		return false;
 		return false;