Add flag to obs_source_frame for unbuffered video

Add 'flags' member variable to obs_source_frame structure.

The OBS_VIDEO_UNBUFFERED flags causes the video to play back as soon as
it's received (in the next frame playback), causing it to disregard the
timestamp value for the sake of video playback (however, note that the
video timestamp is still used for audio synchronization if audio is
present on the source as well).

This is partly a convenience feature, and partly a necessity for certain
plugins (such as the linux v4l plugin) where timestamp information for
the video frames can sometimes be unreliable.
This commit is contained in:
jp9000
2014-10-19 07:26:53 -07:00
parent 2c3f9c47d1
commit c3f4b0f018
6 changed files with 20 additions and 1 deletions

View File

@@ -75,7 +75,7 @@ static inline void capture_frame(struct window_capture *wc)
.height = height,
.data[0] = data,
.linesize[0] = width * 4,
.timestamp = ts,
.timestamp = ts
};
obs_source_output_video(wc->source, &frame);