From 23f4d17d415809642b38e4cf46c3711b0f1beae2 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Mon, 25 Jan 2016 03:56:03 -0800 Subject: [PATCH] libobs/media-io: Fix bug (skipped frames including lagged frames) The skipped frame count (dropped frames due to encoding being overloaded) would erroneously include lagged frames (dropped frames due to render stalls). This will make diagnosing actual issues a user might be having a bit easier. --- libobs/media-io/video-io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libobs/media-io/video-io.c b/libobs/media-io/video-io.c index a89c0d463..63de9dffb 100644 --- a/libobs/media-io/video-io.c +++ b/libobs/media-io/video-io.c @@ -176,7 +176,6 @@ static void *video_thread(void *param) profile_start(video_thread_name); while (!video->stop && !video_output_cur_frame(video)) { video->total_frames++; - video->skipped_frames++; } video->total_frames++; @@ -404,6 +403,7 @@ bool video_output_lock_frame(video_t *video, struct video_frame *frame, pthread_mutex_lock(&video->data_mutex); if (video->available_frames == 0) { + video->skipped_frames += count; video->cache[video->last_added].count += count; locked = false;