浏览代码

libobs: Mark last video ts even when buffering off

Ensures that the system always has a record of when the last video frame
was played.
jp9000 8 年之前
父节点
当前提交
d60d222d71
共有 2 个文件被更改,包括 2 次插入0 次删除
  1. 1 0
      libobs/obs-source-deinterlace.c
  2. 1 0
      libobs/obs-source.c

+ 1 - 0
libobs/obs-source-deinterlace.c

@@ -37,6 +37,7 @@ static bool ready_deinterlace_frames(obs_source_t *source, uint64_t sys_time)
 		if (source->async_frames.num == 2)
 		if (source->async_frames.num == 2)
 			source->async_frames.array[0]->prev_frame = true;
 			source->async_frames.array[0]->prev_frame = true;
 		source->deinterlace_offset = 0;
 		source->deinterlace_offset = 0;
+		source->last_frame_ts = next_frame->timestamp;
 		return true;
 		return true;
 	}
 	}
 
 

+ 1 - 0
libobs/obs-source.c

@@ -2513,6 +2513,7 @@ static bool ready_async_frame(obs_source_t *source, uint64_t sys_time)
 			next_frame = source->async_frames.array[0];
 			next_frame = source->async_frames.array[0];
 		}
 		}
 
 
+		source->last_frame_ts = next_frame->timestamp;
 		return true;
 		return true;
 	}
 	}