From 7e15df7551cf45ad1d3e39d20fdc8d6c651d4705 Mon Sep 17 00:00:00 2001 From: Justin Ruggles Date: Sat, 26 May 2012 14:50:02 -0400 Subject: swr: resampling: add filter type and Kaiser window beta to AVOptions --- libswresample/swresample_internal.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'libswresample/swresample_internal.h') diff --git a/libswresample/swresample_internal.h b/libswresample/swresample_internal.h index 52b60ce734..e569a4430f 100644 --- a/libswresample/swresample_internal.h +++ b/libswresample/swresample_internal.h @@ -63,6 +63,8 @@ struct SwrContext { int phase_shift; /**< log2 of the number of entries in the resampling polyphase filterbank */ int linear_interp; /**< if 1 then the resampling FIR filter will be linearly interpolated */ double cutoff; /**< resampling cutoff frequency. 1.0 corresponds to half the output sample rate */ + enum SwrFilterType filter_type; /**< resampling filter type */ + int kaiser_beta; /**< beta value for Kaiser window (only applicable if filter_type == AV_FILTER_TYPE_KAISER) */ float min_compensation; ///< minimum below which no compensation will happen float min_hard_compensation; ///< minimum below which no silence inject / sample drop will happen @@ -109,7 +111,7 @@ struct SwrContext { /* TODO: callbacks for ASM optimizations */ }; -struct ResampleContext *swri_resample_init(struct ResampleContext *, int out_rate, int in_rate, int filter_size, int phase_shift, int linear, double cutoff, enum AVSampleFormat); +struct ResampleContext *swri_resample_init(struct ResampleContext *, int out_rate, int in_rate, int filter_size, int phase_shift, int linear, double cutoff, enum AVSampleFormat, enum SwrFilterType, int kaiser_beta); void swri_resample_free(struct ResampleContext **c); int swri_multiple_resample(struct ResampleContext *c, AudioData *dst, int dst_size, AudioData *src, int src_size, int *consumed); void swri_resample_compensate(struct ResampleContext *c, int sample_delta, int compensation_distance); -- cgit v1.2.3