obs-ffmpeg: Remove unbuffered mode from media source

Unbuffered mode is causing the frames of media sources to potentially
have some slight jitter in playback, so instead of using unbuffered mode
with media sources, just leave buffering on.  There may be a frame or so
of latency, but it shouldn't be noticeable to most users.
This commit is contained in:
jp9000
2019-10-05 15:40:12 -07:00
parent e023060afa
commit 89586ef441

View File

@@ -318,16 +318,12 @@ static void ffmpeg_source_update(void *data, obs_data_t *settings)
s->is_looping = obs_data_get_bool(settings, "looping");
s->close_when_inactive =
obs_data_get_bool(settings, "close_when_inactive");
obs_source_set_async_unbuffered(s->source, true);
} else {
input = (char *)obs_data_get_string(settings, "input");
input_format =
(char *)obs_data_get_string(settings, "input_format");
s->is_looping = false;
s->close_when_inactive = true;
obs_source_set_async_unbuffered(s->source, false);
}
s->input = input ? bstrdup(input) : NULL;