From a0884c82a91a3688bd0f448ad4502796782db7bb Mon Sep 17 00:00:00 2001 From: Kevin Mitchell Date: Wed, 16 Mar 2016 23:37:46 -0700 Subject: audio: add af_select_best_samplerate function This function chooses the best match to a given samplerate from a provided list. This can be used, for example, by the ao to decide what samplerate to use for output. --- audio/format.h | 1 + 1 file changed, 1 insertion(+) (limited to 'audio/format.h') diff --git a/audio/format.h b/audio/format.h index de1ff1a30d..3d5cc1024b 100644 --- a/audio/format.h +++ b/audio/format.h @@ -76,6 +76,7 @@ int af_fmt_seconds_to_bytes(int format, float seconds, int channels, int sampler void af_fill_silence(void *dst, size_t bytes, int format); void af_get_best_sample_formats(int src_format, int out_formats[AF_FORMAT_COUNT]); +int af_select_best_samplerate(int src_sampelrate, const int *available); int af_format_sample_alignment(int format); -- cgit v1.2.3