summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
88cbd25)
Deprecate the entire library. Merged years ago to provide compatibility
with Libav, it remained unmaintained by the FFmpeg project and duplicated
functionality provided by libswresample.
In order to improve consistency and reduce attack surface, as well as to ease
burden on maintainers, it has been deprecated. Users of this library are asked
to migrate to libswresample, which, as well as providing more functionality,
is faster and has higher accuracy.
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
--disable-swscale disable libswscale build
--disable-postproc disable libpostproc build
--disable-avfilter disable libavfilter build
--disable-swscale disable libswscale build
--disable-postproc disable libpostproc build
--disable-avfilter disable libavfilter build
- --enable-avresample enable libavresample build [no]
+ --enable-avresample enable libavresample build (deprecated) [no]
--disable-pthreads disable pthreads [autodetect]
--disable-w32threads disable Win32 threads [autodetect]
--disable-os2threads disable OS/2 threads [autodetect]
--disable-pthreads disable pthreads [autodetect]
--disable-w32threads disable Win32 threads [autodetect]
--disable-os2threads disable OS/2 threads [autodetect]
$ALL_COMPONENTS \
enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pthread threading without atomics not supported, try adding --enable-pthreads or --cpu=i486 or higher if you are on x86"
$ALL_COMPONENTS \
enabled threads && ! enabled pthreads && ! enabled atomics_native && die "non pthread threading without atomics not supported, try adding --enable-pthreads or --cpu=i486 or higher if you are on x86"
+enabled avresample && warn "Building with deprecated library libavresample"
if test $target_os = "haiku"; then
disable memalign
if test $target_os = "haiku"; then
disable memalign
API changes, most recent first:
API changes, most recent first:
+2017-xx-xx - xxxxxxx - lavr 4.0.0 - avresample.h
+ Deprecate the entire library. Merged years ago to provide compatibility
+ with Libav, it remained unmaintained by the FFmpeg project and duplicated
+ functionality provided by libswresample.
+
+ In order to improve consistency and reduce attack surface, it has been deprecated.
+ Users of this library are asked to migrate to libswresample, which, as well as
+ providing more functionality, is faster and has higher accuracy.
+
2017-xx-xx - xxxxxxx - lavc 58.9.100 - avcodec.h
Deprecate av_lockmgr_register(). You need to build FFmpeg with threading
support enabled to get basic thread-safety (which is the default build
2017-xx-xx - xxxxxxx - lavc 58.9.100 - avcodec.h
Deprecate av_lockmgr_register(). You need to build FFmpeg with threading
support enabled to get basic thread-safety (which is the default build
#define AVRESAMPLE_MAX_CHANNELS 32
#define AVRESAMPLE_MAX_CHANNELS 32
-typedef struct AVAudioResampleContext AVAudioResampleContext;
+typedef attribute_deprecated struct AVAudioResampleContext AVAudioResampleContext;
-/** Mixing Coefficient Types */
-enum AVMixCoeffType {
+/**
+ * @deprecated use libswresample
+ *
+ * Mixing Coefficient Types */
+enum attribute_deprecated AVMixCoeffType {
AV_MIX_COEFF_TYPE_Q8, /** 16-bit 8.8 fixed-point */
AV_MIX_COEFF_TYPE_Q15, /** 32-bit 17.15 fixed-point */
AV_MIX_COEFF_TYPE_FLT, /** floating-point */
AV_MIX_COEFF_TYPE_NB, /** Number of coeff types. Not part of ABI */
};
AV_MIX_COEFF_TYPE_Q8, /** 16-bit 8.8 fixed-point */
AV_MIX_COEFF_TYPE_Q15, /** 32-bit 17.15 fixed-point */
AV_MIX_COEFF_TYPE_FLT, /** floating-point */
AV_MIX_COEFF_TYPE_NB, /** Number of coeff types. Not part of ABI */
};
-/** Resampling Filter Types */
-enum AVResampleFilterType {
+/**
+ * @deprecated use libswresample
+ *
+ * Resampling Filter Types */
+enum attribute_deprecated AVResampleFilterType {
AV_RESAMPLE_FILTER_TYPE_CUBIC, /**< Cubic */
AV_RESAMPLE_FILTER_TYPE_BLACKMAN_NUTTALL, /**< Blackman Nuttall Windowed Sinc */
AV_RESAMPLE_FILTER_TYPE_KAISER, /**< Kaiser Windowed Sinc */
};
AV_RESAMPLE_FILTER_TYPE_CUBIC, /**< Cubic */
AV_RESAMPLE_FILTER_TYPE_BLACKMAN_NUTTALL, /**< Blackman Nuttall Windowed Sinc */
AV_RESAMPLE_FILTER_TYPE_KAISER, /**< Kaiser Windowed Sinc */
};
-enum AVResampleDitherMethod {
+/**
+ * @deprecated use libswresample
+ */
+enum attribute_deprecated AVResampleDitherMethod {
AV_RESAMPLE_DITHER_NONE, /**< Do not use dithering */
AV_RESAMPLE_DITHER_RECTANGULAR, /**< Rectangular Dither */
AV_RESAMPLE_DITHER_TRIANGULAR, /**< Triangular Dither*/
AV_RESAMPLE_DITHER_NONE, /**< Do not use dithering */
AV_RESAMPLE_DITHER_RECTANGULAR, /**< Rectangular Dither */
AV_RESAMPLE_DITHER_TRIANGULAR, /**< Triangular Dither*/
+ *
+ * @deprecated use libswresample
+ *
* Return the LIBAVRESAMPLE_VERSION_INT constant.
*/
* Return the LIBAVRESAMPLE_VERSION_INT constant.
*/
unsigned avresample_version(void);
/**
unsigned avresample_version(void);
/**
+ *
+ * @deprecated use libswresample
+ *
* Return the libavresample build-time configuration.
* @return configure string
*/
* Return the libavresample build-time configuration.
* @return configure string
*/
const char *avresample_configuration(void);
/**
const char *avresample_configuration(void);
/**
+ *
+ * @deprecated use libswresample
+ *
* Return the libavresample license.
*/
* Return the libavresample license.
*/
const char *avresample_license(void);
/**
const char *avresample_license(void);
/**
+ *
+ * @deprecated use libswresample
+ *
* Get the AVClass for AVAudioResampleContext.
*
* Can be used in combination with AV_OPT_SEARCH_FAKE_OBJ for examining options
* Get the AVClass for AVAudioResampleContext.
*
* Can be used in combination with AV_OPT_SEARCH_FAKE_OBJ for examining options
*
* @return AVClass for AVAudioResampleContext
*/
*
* @return AVClass for AVAudioResampleContext
*/
const AVClass *avresample_get_class(void);
/**
const AVClass *avresample_get_class(void);
/**
+ *
+ * @deprecated use libswresample
+ *
* Allocate AVAudioResampleContext and set options.
*
* @return allocated audio resample context, or NULL on failure
*/
* Allocate AVAudioResampleContext and set options.
*
* @return allocated audio resample context, or NULL on failure
*/
AVAudioResampleContext *avresample_alloc_context(void);
/**
AVAudioResampleContext *avresample_alloc_context(void);
/**
+ *
+ * @deprecated use libswresample
+ *
* Initialize AVAudioResampleContext.
* @note The context must be configured using the AVOption API.
* @note The fields "in_channel_layout", "out_channel_layout",
* Initialize AVAudioResampleContext.
* @note The context must be configured using the AVOption API.
* @note The fields "in_channel_layout", "out_channel_layout",
* @param avr audio resample context
* @return 0 on success, negative AVERROR code on failure
*/
* @param avr audio resample context
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_open(AVAudioResampleContext *avr);
/**
int avresample_open(AVAudioResampleContext *avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Check whether an AVAudioResampleContext is open or closed.
*
* @param avr AVAudioResampleContext to check
* @return 1 if avr is open, 0 if avr is closed.
*/
* Check whether an AVAudioResampleContext is open or closed.
*
* @param avr AVAudioResampleContext to check
* @return 1 if avr is open, 0 if avr is closed.
*/
int avresample_is_open(AVAudioResampleContext *avr);
/**
int avresample_is_open(AVAudioResampleContext *avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Close AVAudioResampleContext.
*
* This closes the context, but it does not change the parameters. The context
* Close AVAudioResampleContext.
*
* This closes the context, but it does not change the parameters. The context
*
* @param avr audio resample context
*/
*
* @param avr audio resample context
*/
void avresample_close(AVAudioResampleContext *avr);
/**
void avresample_close(AVAudioResampleContext *avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Free AVAudioResampleContext and associated AVOption values.
*
* This also calls avresample_close() before freeing.
*
* @param avr audio resample context
*/
* Free AVAudioResampleContext and associated AVOption values.
*
* This also calls avresample_close() before freeing.
*
* @param avr audio resample context
*/
void avresample_free(AVAudioResampleContext **avr);
/**
void avresample_free(AVAudioResampleContext **avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Generate a channel mixing matrix.
*
* This function is the one used internally by libavresample for building the
* Generate a channel mixing matrix.
*
* This function is the one used internally by libavresample for building the
* @param matrix_encoding matrixed stereo downmix mode (e.g. dplii)
* @return 0 on success, negative AVERROR code on failure
*/
* @param matrix_encoding matrixed stereo downmix mode (e.g. dplii)
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_build_matrix(uint64_t in_layout, uint64_t out_layout,
double center_mix_level, double surround_mix_level,
double lfe_mix_level, int normalize, double *matrix,
int stride, enum AVMatrixEncoding matrix_encoding);
/**
int avresample_build_matrix(uint64_t in_layout, uint64_t out_layout,
double center_mix_level, double surround_mix_level,
double lfe_mix_level, int normalize, double *matrix,
int stride, enum AVMatrixEncoding matrix_encoding);
/**
+ *
+ * @deprecated use libswresample
+ *
* Get the current channel mixing matrix.
*
* If no custom matrix has been previously set or the AVAudioResampleContext is
* Get the current channel mixing matrix.
*
* If no custom matrix has been previously set or the AVAudioResampleContext is
* @param stride distance between adjacent input channels in the matrix array
* @return 0 on success, negative AVERROR code on failure
*/
* @param stride distance between adjacent input channels in the matrix array
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_get_matrix(AVAudioResampleContext *avr, double *matrix,
int stride);
/**
int avresample_get_matrix(AVAudioResampleContext *avr, double *matrix,
int stride);
/**
+ *
+ * @deprecated use libswresample
+ *
* Set channel mixing matrix.
*
* Allows for setting a custom mixing matrix, overriding the default matrix
* Set channel mixing matrix.
*
* Allows for setting a custom mixing matrix, overriding the default matrix
* @param stride distance between adjacent input channels in the matrix array
* @return 0 on success, negative AVERROR code on failure
*/
* @param stride distance between adjacent input channels in the matrix array
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_set_matrix(AVAudioResampleContext *avr, const double *matrix,
int stride);
/**
int avresample_set_matrix(AVAudioResampleContext *avr, const double *matrix,
int stride);
/**
+ *
+ * @deprecated use libswresample
+ *
* Set a customized input channel mapping.
*
* This function can only be called when the allocated context is not open.
* Set a customized input channel mapping.
*
* This function can only be called when the allocated context is not open.
* @param channel_map customized input channel mapping
* @return 0 on success, negative AVERROR code on failure
*/
* @param channel_map customized input channel mapping
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_set_channel_mapping(AVAudioResampleContext *avr,
const int *channel_map);
/**
int avresample_set_channel_mapping(AVAudioResampleContext *avr,
const int *channel_map);
/**
+ *
+ * @deprecated use libswresample
+ *
* Set compensation for resampling.
*
* This can be called anytime after avresample_open(). If resampling is not
* Set compensation for resampling.
*
* This can be called anytime after avresample_open(). If resampling is not
* @param compensation_distance compensation distance, in samples
* @return 0 on success, negative AVERROR code on failure
*/
* @param compensation_distance compensation distance, in samples
* @return 0 on success, negative AVERROR code on failure
*/
int avresample_set_compensation(AVAudioResampleContext *avr, int sample_delta,
int compensation_distance);
/**
int avresample_set_compensation(AVAudioResampleContext *avr, int sample_delta,
int compensation_distance);
/**
+ *
+ * @deprecated use libswresample
+ *
* Provide the upper bound on the number of samples the configured
* conversion would output.
*
* Provide the upper bound on the number of samples the configured
* conversion would output.
*
* @return number of samples or AVERROR(EINVAL) if the value
* would exceed INT_MAX
*/
* @return number of samples or AVERROR(EINVAL) if the value
* would exceed INT_MAX
*/
int avresample_get_out_samples(AVAudioResampleContext *avr, int in_nb_samples);
/**
int avresample_get_out_samples(AVAudioResampleContext *avr, int in_nb_samples);
/**
+ *
+ * @deprecated use libswresample
+ *
* Convert input samples and write them to the output FIFO.
*
* The upper bound on the number of output samples can be obtained through
* Convert input samples and write them to the output FIFO.
*
* The upper bound on the number of output samples can be obtained through
* not including converted samples added to the internal
* output FIFO
*/
* not including converted samples added to the internal
* output FIFO
*/
int avresample_convert(AVAudioResampleContext *avr, uint8_t **output,
int out_plane_size, int out_samples,
uint8_t * const *input, int in_plane_size,
int in_samples);
/**
int avresample_convert(AVAudioResampleContext *avr, uint8_t **output,
int out_plane_size, int out_samples,
uint8_t * const *input, int in_plane_size,
int in_samples);
/**
+ *
+ * @deprecated use libswresample
+ *
* Return the number of samples currently in the resampling delay buffer.
*
* When resampling, there may be a delay between the input and output. Any
* Return the number of samples currently in the resampling delay buffer.
*
* When resampling, there may be a delay between the input and output. Any
* @param avr audio resample context
* @return number of samples currently in the resampling delay buffer
*/
* @param avr audio resample context
* @return number of samples currently in the resampling delay buffer
*/
int avresample_get_delay(AVAudioResampleContext *avr);
/**
int avresample_get_delay(AVAudioResampleContext *avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Return the number of available samples in the output FIFO.
*
* During conversion, if the user does not specify an output buffer or
* Return the number of available samples in the output FIFO.
*
* During conversion, if the user does not specify an output buffer or
* @param avr audio resample context
* @return number of samples available for reading
*/
* @param avr audio resample context
* @return number of samples available for reading
*/
int avresample_available(AVAudioResampleContext *avr);
/**
int avresample_available(AVAudioResampleContext *avr);
/**
+ *
+ * @deprecated use libswresample
+ *
* Read samples from the output FIFO.
*
* During conversion, if the user does not specify an output buffer or
* Read samples from the output FIFO.
*
* During conversion, if the user does not specify an output buffer or
* @param nb_samples number of samples to read from the FIFO
* @return the number of samples written to output
*/
* @param nb_samples number of samples to read from the FIFO
* @return the number of samples written to output
*/
int avresample_read(AVAudioResampleContext *avr, uint8_t **output, int nb_samples);
/**
int avresample_read(AVAudioResampleContext *avr, uint8_t **output, int nb_samples);
/**
+ *
+ * @deprecated use libswresample
+ *
* Convert the samples in the input AVFrame and write them to the output AVFrame.
*
* Input and output AVFrames must have channel_layout, sample_rate and format set.
* Convert the samples in the input AVFrame and write them to the output AVFrame.
*
* Input and output AVFrames must have channel_layout, sample_rate and format set.
* @return 0 on success, AVERROR on failure or nonmatching
* configuration.
*/
* @return 0 on success, AVERROR on failure or nonmatching
* configuration.
*/
int avresample_convert_frame(AVAudioResampleContext *avr,
AVFrame *output, AVFrame *input);
/**
int avresample_convert_frame(AVAudioResampleContext *avr,
AVFrame *output, AVFrame *input);
/**
+ *
+ * @deprecated use libswresample
+ *
* Configure or reconfigure the AVAudioResampleContext using the information
* provided by the AVFrames.
*
* Configure or reconfigure the AVAudioResampleContext using the information
* provided by the AVFrames.
*
* @param in input AVFrame
* @return 0 on success, AVERROR on failure.
*/
* @param in input AVFrame
* @return 0 on success, AVERROR on failure.
*/
int avresample_config(AVAudioResampleContext *avr, AVFrame *out, AVFrame *in);
/**
int avresample_config(AVAudioResampleContext *avr, AVFrame *out, AVFrame *in);
/**