Luca Barbato
11db644a8e
lavr: Update the planar check in ff_audio_convert
...
Leftover from fbc0b86599
.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
11 years ago
Luca Barbato
fb1ddcdc8f
avresample: Introduce AVFrame-based API
11 years ago
Anton Khirnov
1985c2e75c
Bump major versions of all libraries.
11 years ago
Anton Khirnov
f4c444e17d
Postpone API-incompatible changes until the next bump.
11 years ago
Justin Ruggles
fbc0b86599
lavr: Do not change the sample format for mono audio
...
This treats mono as planar internally within libavresample rather
than changing the sample format.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
11 years ago
Luca Barbato
b2d4565422
avresample: Add avresample_get_out_samples
...
Utility function to get the upper bound on the number of samples the
resampler would output.
11 years ago
Janne Grunau
449511740f
build: handle library dependencies in configure
...
Instead of setting FFLIBS in each library Makefile configure
exports FFLIBS-$library in config.mak.
11 years ago
Janne Grunau
a24a252709
aarch64: NEON optimized FIR audio resampling
...
Optimized for the default filter length 16.
30% faster opus silk decoding.
11 years ago
Janne Grunau
cae8df7875
lavr: define ResampleContext in resample.h
...
Required for arch optimized resampling.
11 years ago
Janne Grunau
f4d5a2cc35
aarch64: NEON float to s16 audio conversion
11 years ago
Anton Khirnov
21d8f4da91
resample: remove an unneeded context variable
11 years ago
Anton Khirnov
ac976ed91e
lavr: allocate the resampling buffer with a positive size
...
This fixes cases where very few input samples (fewer than needed for one
output sample) are passed to lavr at the beginning.
CC:libav-stable@libav.org
11 years ago
Anton Khirnov
f7c5fd8151
resample: implement flushing
11 years ago
Anton Khirnov
254c95cdd1
resample: split linear into its own function
11 years ago
Anton Khirnov
be394968c8
resample: add initial padding explicitly
...
This simplifies the code, since we do not have to deal with a possibly
negative source index anymore.
11 years ago
Anton Khirnov
eed752d61d
resample: drop useless abs()
...
negative sample_index is handled in the block above.
11 years ago
Anton Khirnov
3c84f6b5d2
resample: reindent
11 years ago
Anton Khirnov
f20892eb67
resample: split the nearest neighbour path into a separate function pointer
11 years ago
Anton Khirnov
b9dea23766
resample: fix avresample_get_delay() return value
...
The correct "next" input sample is not the first sample of the
resampling buffer, but the center sample of the filter_length-sized
block at the beginning.
CC:libav-stable@libav.org
11 years ago
Diego Biurrun
01c5779f56
x86: Drop some unnecessary YASM ifdefs
...
Dead code elimination is enough to avoid undefined references in these cases.
11 years ago
Diego Biurrun
aba70bb538
Add missing headers to make template files compile (more) standalone
11 years ago
Anton Khirnov
1db03a6864
lavr: return an error if a avresample_open() is called on an open context
11 years ago
Anton Khirnov
7e86c27b4e
lavr: add a function for checking whether AVAudioResampleContext is open
11 years ago
Tim Walker
76a75c523c
lavr: mix front center channel as indicated in the ATSC A/52 specification.
...
When mixing 3 front channels into 2, the center channel is mixed into left and right with the center mix level, not -3dB.
11 years ago
Martin Storsjö
5bcbb516f2
arm: Add X() around all references to extern symbols
...
Don't rely on the fact that an unprefixed label currently exists.
Signed-off-by: Martin Storsjö <martin@martin.st>
11 years ago
Janne Grunau
fe96769bed
aarch64: port neon clobber test from arm
11 years ago
Martin Storsjö
99e2012523
x86/arm: Add clobber tests to libavresample
...
Signed-off-by: Martin Storsjö <martin@martin.st>
11 years ago
Anton Khirnov
cc976a75df
audio_mix: print (SKIP) instead of 0.0 for matrix columns removed along with output zeroing
11 years ago
Anton Khirnov
fc6a3ef40d
audio_mix: fix zeroing output channels in certain cases
...
Specifically, when the corresponding input channel exists and its matrix
column is all-zero (which is necessary for zeroing the output), the
matrix column must be removed from the matrix.
This is not done currently, so the mixing code would end up using
uninitialized pointers from stack.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
11 years ago
Anton Khirnov
3d95d27376
audio_mix: initialize the data pointers to NULL
...
This should make it easier to catch problems where some of those
pointers are used uninitialized, since reading from NULL should always
crash, while random numbers from stack can turn out to be valid
pointers, so random memory may be silently overwritten.
11 years ago
Diego Biurrun
b83d1ee3b4
avutil: Move library version related macros to version.h
...
This is a more sensible place for these macros.
11 years ago
Diego Biurrun
8f8bc92365
Add missing #includes for *INT64_MAX and *INT64_C
11 years ago
Justin Ruggles
211ca69b13
lavr: check that current_buffer is not NULL before using it
...
Fixes a segfault during resampling when compiled with -DDEBUG.
Fixes all fate-lavr-resample tests with -DDEBUG.
CC:libav-stable@libav.org
11 years ago
Derek Buitenhuis
206895708e
x86inc: Remove our FMA4 support
...
This is so we can sync to x264's version of FMA4 support.
This partialy reverts commit 79687079a9
.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
11 years ago
Derek Buitenhuis
15748773bf
avresample/x86: Switch operand order for mulps
...
With the forthcoming VEX instruction emulation, mulps
must have only the third operand point to memory, as
this is what vmulps expects.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
11 years ago
Anton Khirnov
df6737a55f
audio_mix: fix channel order in mix_1_to_2_fltp_flt_c
...
CC:libav-stable@libav.org
11 years ago
Diego Biurrun
b5a138652f
Give less generic names to global library option arrays
12 years ago
Diego Biurrun
03039f4c8c
miscellaneous typo fixes
12 years ago
Diego Biurrun
3ac7fa81b2
Consistently use "cpu_flags" as variable/parameter name for CPU flags
12 years ago
Anton Khirnov
006ec64877
lavr doxy: add version.h to the lavr group
12 years ago
Diego Biurrun
e445647b4f
avresample: Add av_cold attributes to init functions missing them
12 years ago
Diego Biurrun
b6649ab503
cosmetics: Remove unnecessary extern keywords from function declarations
12 years ago
Justin Ruggles
b2eea615c0
lavr: allow setting internal_sample_fmt option by string
12 years ago
Justin Ruggles
50f4337a2f
lavr: Add "resample_cutoff" option as a duplicate of "cutoff"
...
Avoids an option name conflict with libavcodec, which is needed in order
to work properly with avconv.
12 years ago
Justin Ruggles
157542ebc1
lavr: fix mixing matrix reduction when normalization is disabled
...
In some cases when an input contributes fully to the corresponding
output, other inputs may also contribute to the same output. This is the
case, for example, for the default 5.1 to stereo downmix matrix without
normalization.
12 years ago
Justin Ruggles
600b4c973f
lavr: fix matrix reduction for upmixing in certain cases
...
Do not skip an output if the corresponding input contributes to other output
channels.
12 years ago
Justin Ruggles
a3735bb92a
lavr: cosmetics: reindent
12 years ago
Justin Ruggles
1647da89dd
lavr: make sure that the mix function is reset even if no mixing will be done
...
If the matrix reduction ends up with no mixing matrix needed, we need to still
reset the mix function accordingly and log the info to the user.
12 years ago
Justin Ruggles
646831e697
lavr: print out the mix matrix in ff_audio_mix_set_matrix()
...
This will print the new matrix if it is set after initialization.
12 years ago
Justin Ruggles
b90632d596
lavr: always reset mix function names and pointers in mix_function_init()
...
CC: libav-stable@libav.org
12 years ago