diff --git a/es-core/src/components/VideoFFmpegComponent.cpp b/es-core/src/components/VideoFFmpegComponent.cpp index d59d5bf74..3cbf4bbf0 100644 --- a/es-core/src/components/VideoFFmpegComponent.cpp +++ b/es-core/src/components/VideoFFmpegComponent.cpp @@ -264,7 +264,11 @@ void VideoFFmpegComponent::frameProcessing() while (mIsPlaying && !mPause && videoFilter && (!mAudioCodecContext || audioFilter)) { readFrames(); + if (!mIsPlaying) + break; getProcessedFrames(); + if (!mIsPlaying) + break; outputFrames(); // This 1 ms wait makes sure that the thread does not consume all available CPU cycles.