Browse Source

obs-ffmpeg: Always fully restart remote media sources

When a media source is set to use a URL, always fully shut down the
media when stopped. This ensures that the media will do a full
reconnect after having been stopped.
Meng Li 5 years ago
parent
commit
96c7790d80
1 changed files with 1 additions and 1 deletions
  1. 1 1
      plugins/obs-ffmpeg/obs-ffmpeg-source.c

+ 1 - 1
plugins/obs-ffmpeg/obs-ffmpeg-source.c

@@ -284,7 +284,7 @@ static void media_stopped(void *opaque)
 		obs_source_output_video(s->source, NULL);
 	}
 
-	if (s->close_when_inactive && s->media_valid)
+	if ((s->close_when_inactive || !s->is_local_file) && s->media_valid)
 		s->destroy_media = true;
 
 	set_media_state(s, OBS_MEDIA_STATE_ENDED);