From 66aa54d319755589e846efe53f917d2667219e1a Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 6 Oct 2015 19:59:02 +0200 Subject: audio: re-probe spdif if AO is reloaded Makes the spdif automagic work better on audio hotplugging. --- player/audio.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'player') diff --git a/player/audio.c b/player/audio.c index 4bcf69a00f..9ff253ae92 100644 --- a/player/audio.c +++ b/player/audio.c @@ -473,8 +473,10 @@ void fill_audio_out_buffers(struct MPContext *mpctx, double endpts) if (mpctx->ao && ao_query_and_reset_events(mpctx->ao, AO_EVENT_RELOAD)) { ao_reset(mpctx->ao); uninit_audio_out(mpctx); - if (d_audio) + if (d_audio) { + mpctx->d_audio->spdif_passthrough = true; mpctx->audio_status = STATUS_SYNCING; + } } if (!d_audio) -- cgit v1.2.3