Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
8f483108
Commit
8f483108
authored
Oct 22, 2017
by
James Almer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec: Drop deprecated audio resample API
Deprecated in 03/2013.
parent
24a8603a
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
0 additions
and
860 deletions
+0
-860
Makefile
libavcodec/Makefile
+0
-2
avcodec.h
libavcodec/avcodec.h
+0
-97
resample.c
libavcodec/resample.c
+0
-439
resample2.c
libavcodec/resample2.c
+0
-319
version.h
libavcodec/version.h
+0
-3
No files found.
libavcodec/Makefile
View file @
8f483108
...
...
@@ -45,8 +45,6 @@ OBJS = allcodecs.o \
profiles.o
\
qsv_api.o
\
raw.o
\
resample.o
\
resample2.o
\
utils.o
\
vorbis_parser.o
\
xiph.o
\
...
...
libavcodec/avcodec.h
View file @
8f483108
...
...
@@ -5516,103 +5516,6 @@ int avcodec_encode_subtitle(AVCodecContext *avctx, uint8_t *buf, int buf_size,
* @}
*/
#if FF_API_AVCODEC_RESAMPLE
/**
* @defgroup lavc_resample Audio resampling
* @ingroup libavc
* @deprecated use libswresample instead
*
* @{
*/
struct
ReSampleContext
;
struct
AVResampleContext
;
typedef
struct
ReSampleContext
ReSampleContext
;
/**
* Initialize audio resampling context.
*
* @param output_channels number of output channels
* @param input_channels number of input channels
* @param output_rate output sample rate
* @param input_rate input sample rate
* @param sample_fmt_out requested output sample format
* @param sample_fmt_in input sample format
* @param filter_length length of each FIR filter in the filterbank relative to the cutoff frequency
* @param log2_phase_count log2 of the number of entries in the polyphase filterbank
* @param linear if 1 then the used FIR filter will be linearly interpolated
between the 2 closest, if 0 the closest will be used
* @param cutoff cutoff frequency, 1.0 corresponds to half the output sampling rate
* @return allocated ReSampleContext, NULL if error occurred
*/
attribute_deprecated
ReSampleContext
*
av_audio_resample_init
(
int
output_channels
,
int
input_channels
,
int
output_rate
,
int
input_rate
,
enum
AVSampleFormat
sample_fmt_out
,
enum
AVSampleFormat
sample_fmt_in
,
int
filter_length
,
int
log2_phase_count
,
int
linear
,
double
cutoff
);
attribute_deprecated
int
audio_resample
(
ReSampleContext
*
s
,
short
*
output
,
short
*
input
,
int
nb_samples
);
/**
* Free resample context.
*
* @param s a non-NULL pointer to a resample context previously
* created with av_audio_resample_init()
*/
attribute_deprecated
void
audio_resample_close
(
ReSampleContext
*
s
);
/**
* Initialize an audio resampler.
* Note, if either rate is not an integer then simply scale both rates up so they are.
* @param filter_length length of each FIR filter in the filterbank relative to the cutoff freq
* @param log2_phase_count log2 of the number of entries in the polyphase filterbank
* @param linear If 1 then the used FIR filter will be linearly interpolated
between the 2 closest, if 0 the closest will be used
* @param cutoff cutoff frequency, 1.0 corresponds to half the output sampling rate
*/
attribute_deprecated
struct
AVResampleContext
*
av_resample_init
(
int
out_rate
,
int
in_rate
,
int
filter_length
,
int
log2_phase_count
,
int
linear
,
double
cutoff
);
/**
* Resample an array of samples using a previously configured context.
* @param src an array of unconsumed samples
* @param consumed the number of samples of src which have been consumed are returned here
* @param src_size the number of unconsumed samples available
* @param dst_size the amount of space in samples available in dst
* @param update_ctx If this is 0 then the context will not be modified, that way several channels can be resampled with the same context.
* @return the number of samples written in dst or -1 if an error occurred
*/
attribute_deprecated
int
av_resample
(
struct
AVResampleContext
*
c
,
short
*
dst
,
short
*
src
,
int
*
consumed
,
int
src_size
,
int
dst_size
,
int
update_ctx
);
/**
* Compensate samplerate/timestamp drift. The compensation is done by changing
* the resampler parameters, so no audible clicks or similar distortions occur
* @param compensation_distance distance in output samples over which the compensation should be performed
* @param sample_delta number of output samples which should be output less
*
* example: av_resample_compensate(c, 10, 500)
* here instead of 510 samples only 500 samples would be output
*
* note, due to rounding the actual compensation might be slightly different,
* especially if the compensation_distance is large and the in_rate used during init is small
*/
attribute_deprecated
void
av_resample_compensate
(
struct
AVResampleContext
*
c
,
int
sample_delta
,
int
compensation_distance
);
attribute_deprecated
void
av_resample_close
(
struct
AVResampleContext
*
c
);
/**
* @}
*/
#endif
#if FF_API_AVPICTURE
/**
* @addtogroup lavc_picture
...
...
libavcodec/resample.c
deleted
100644 → 0
View file @
24a8603a
This diff is collapsed.
Click to expand it.
libavcodec/resample2.c
deleted
100644 → 0
View file @
24a8603a
This diff is collapsed.
Click to expand it.
libavcodec/version.h
View file @
8f483108
...
...
@@ -57,9 +57,6 @@
#ifndef FF_API_AUDIO_CONVERT
#define FF_API_AUDIO_CONVERT (LIBAVCODEC_VERSION_MAJOR < 58)
#endif
#ifndef FF_API_AVCODEC_RESAMPLE
#define FF_API_AVCODEC_RESAMPLE FF_API_AUDIO_CONVERT
#endif
#ifndef FF_API_LOWRES
#define FF_API_LOWRES (LIBAVCODEC_VERSION_MAJOR < 59)
#endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment