1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-19 05:15:12 +00:00

audio/filter: actually set fmt_in/fmt_out fields

This commit is contained in:
wm4 2015-01-14 22:15:51 +01:00
parent f6a0a1554c
commit 9c974b2a1b

View File

@ -531,6 +531,7 @@ static int af_reinit(struct af_stream *s)
if (!mp_audio_config_valid(&in))
goto error;
af->fmt_in = in;
int rv = af->control(af, AF_CONTROL_REINIT, &in);
if (rv == AF_OK && !mp_audio_config_equals(&in, af->prev->data))
rv = AF_FALSE; // conversion filter needed
@ -538,6 +539,7 @@ static int af_reinit(struct af_stream *s)
case AF_OK:
if (!mp_audio_config_valid(af->data))
goto error;
af->fmt_out = *af->data;
af = af->next;
break;
case AF_FALSE: { // Configuration filter is needed