From d9582ad0a41ed5452ad29bf8511e8c6a3bdbe6f8 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 9 May 2013 12:09:23 +0200 Subject: audio/filters: add af_force Its main purpose is for testing in case channel layout stuff breaks, in particular in connection with old audio filters. --- audio/audio.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'audio/audio.c') diff --git a/audio/audio.c b/audio/audio.c index 248f16790f..8af6a20a1f 100644 --- a/audio/audio.c +++ b/audio/audio.c @@ -56,6 +56,12 @@ void mp_audio_copy_config(struct mp_audio *dst, const struct mp_audio *src) dst->rate = src->rate; } +bool mp_audio_config_equals(const struct mp_audio *a, const struct mp_audio *b) +{ + return a->format == b->format && a->rate == b->rate && + mp_chmap_equals(&a->channels, &b->channels); +} + char *mp_audio_fmt_to_str(int srate, const struct mp_chmap *chmap, int format) { char *chstr = mp_chmap_to_str(chmap); -- cgit v1.2.3