Commit Graph

74716 Commits

Author SHA1 Message Date
Rostislav Pehlivanov
0818705bf3 aacenc_tns: fix triggering an assertion with assert-level=2
It also made no sense to actually make the filter span the entire
window including the first band of the next window.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 19:01:59 +01:00
Ganesh Ajjanagadde
47b41feb72 avfilter/af_apad: use the name 's' for the pointer to the private context
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-08-29 16:38:38 +00:00
Paul B Mahol
16229fae9c avfilter/vf_vectorscope: add yet another mode
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-08-29 14:05:03 +00:00
Clément Bœsch
b48d8fa3ac avfilter: add allrgb
Signed-off-by: Nicolas George <george@nsup.org>
Signed-off-by: Clément Bœsch <u@pkh.me>
2015-08-29 14:57:52 +02:00
Rostislav Pehlivanov
8323d9b8af fate: adjust AAC encoder TNS test fuzziness
Tests fails on some ARM builds but it's close enough so it's okay.
NEON, half-precision floats, rounding errors, who knows.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 09:26:05 +01:00
Rostislav Pehlivanov
4ff897a536 fate: add a test for encoding AAC-Main prediction
This commit introduces a test for AAC-Main prediction
which was just reworked in this series of commits.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 07:00:54 +01:00
Rostislav Pehlivanov
fe12ba6f30 fate: reenable TNS test
Hopefully without errors like last time, but I'm prepared.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 07:00:17 +01:00
Rostislav Pehlivanov
f04d86c16a aacenc: remove TNS from the todo list
Pulses are already on the way so expect to see the list
gone in the close future.

TNS is already of sufficiently high quality to be enabled
by default (but isn't yet, so you too can help by testing!).

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:57:08 +01:00
Rostislav Pehlivanov
f20b67173c aacenc_tns: rework the way coefficients are calculated
This commit abandons the way the specifications state to
quantize the coefficients, makes use of the new LPC float
functions and is much better.

The original way of converting non-normalized float samples
to int32_t which out LPC system expects was wrong and it was
wrong to assume the coefficients that are generated are also
valid. It was essentially a full garbage-in, garbage-out
system and it definitely shows when looking at spectrals
and listening. The high frequencies were very overattenuated.
The new LPC function performs the analysis directly.

The specifications state to quantize the coefficients into
four bit index values using an asin() function which of course
had to have ugly ternary operators because the function turns
negative if the coefficients are negative which when encoding
causes invalid bitstream to get generated.

This deviates from this by using the direct TNS tables, which
are fairly small since you only have 4 bits at most for index
values. The LPC values are directly quantized against the tables
and are then used to perform filtering after the requantization,
which simply fetches the array values.

The end result is that TNS works much better now and doesn't
attenuate anything but the actual signal, e.g. TNS removes
quantization errors and does it's job correctly now.

It might be enabled by default soon since it doesn't hurt and
helps reduce nastyness at low bitrates.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:47:31 +01:00
Rostislav Pehlivanov
1cd5daee20 aac: remove now-unused redundant array
This commit removes the array which was made redundant with
the last commit. The current prediction system gets the
quantization error directly (and without the single-frame delay)
in the search_for_pred function.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:44:20 +01:00
Rostislav Pehlivanov
44ddee945a aacenc_pred: rework the way prediction is done
This commit completely alters the algorithm of prediction.
The original commit which introduced prediction was completely
incorrect to even remotely care about what the actual coefficients
contain or whether any options were enabled. Not my actual fault.

This commit treats prediction the way the decoder does and expects
to do: like lossy encryption. Everything related to prediction now
happens at the very end but just before quantization and encoding
of coefficients. On the decoder side, prediction happens before
anything has had a chance to even access the coefficients.

Also the original implementation had problems because it actually
touched the band_type of special bands which already had their
scalefactor indices marked and it's a wonder the asserion wasn't
triggered when transmitting those.

Overall, this now drastically increases audio quality and you should
think about enabling it if you don't plan on playing anything encoded
on really old low power ultra-embedded devices since they might not
support decoding of prediction or AAC-Main. Though the specifications
were written ages ago and as times change so do the FLOPS.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:34:08 +01:00
Rostislav Pehlivanov
949a4892fa aacenc: change FF_PROFILE_UNKNOWN to AAC-Main if prediction is enabled
This was missed when the original commits were done. FF_PROFILE_UNKNOWN
is what's in avctx->profile when no audio profile is specified.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:28:21 +01:00
Rostislav Pehlivanov
20962b567b lpc: create a simplified Levinson-Durbin LPC handling float samples
This commit simply duplicates the functionality of ff_lpc_calc_coefs()
for the case of a Levinson-Durbin LPC with the only difference being
that floating point samples are accepted and the resulting coefficients
are raw and unquantized.
The motivation behind doing this is the fact that the AAC encoder
requires LPC in TNS and LTP and converting non-normalized floating
point coefficients to int32_t using SWR and again back for the LPC
coefficients was very impractical.
The current LPC interfaces were designed for int32_t in mind possibly
because FLAC and ALAC use this type for most internal operations.
The mathematics in case of floats remains of course identical.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:14:13 +01:00
Rostislav Pehlivanov
f55cc57911 aac: move the TNS tables from aacdectab to the shared aactab
This commit simply moves the TNS tables to a more appropriate
aactab.h since then they can be accessed by both the decoder
and encoder.

The encoder _shouldn't_ normally need the tables since the
specs describe a specific quantization process, but the exact
reason for this can be seen in the TNS commit following.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2015-08-29 06:07:12 +01:00
Philip Langdale
91f1115a0e avcodec/vc1dec: Re-order init to avoid initting hwaccel too early
At least for vdpau, the hwaccel init code tries to check the video
profile and ensure that there is a matching vdpau profile available.

If it can't find a match, it will fail to initialise.

In the case of wmv3/vc1, I observed initialisation to fail all the
time. It turns out that this is due to the hwaccel being initialised
very early in the codec init, before the profile has been extracted
and set.

Conceptually, it's a simple fix to reorder the init code, but it gets
messy really fast because ff_get_format(), which is what implicitly
trigger hwaccel init, is called multiple times through various shared
init calls from h263, etc. It's incredibly hard to prove to my own
satisfaction that it's safe to move the vc1 specific init code
ahead of this generic code, but all the vc1 fate tests pass, and I've
visually inspected a couple of samples and things seem correct.

Signed-off-by: Philip Langdale <philipl@overt.org>
2015-08-28 19:11:55 -07:00
Michael Niedermayer
628a73f8f3 ffmpeg: force 128k default audio bitrate if nothing is specified and there is no specific default
This prevents breaking existing command lines in case the "ab" default is removed from libavcodec

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 23:07:12 +02:00
Paul B Mahol
777df1ff74 avfilter/vf_dejudder: use the name 's' for the pointer to the private context
This is shorter and consistent across filters.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-08-28 19:05:19 +00:00
Ronald S. Bultje
7e12a54251 ffserver: use -b instead of -ab for setting audio bitrate. 2015-08-28 14:59:58 -04:00
Ronald S. Bultje
2fb593dcb9 Put remaining pieces of CODEC_FLAG_EMU_EDGE under FF_API_EMU_EDGE.
The amv one probably looks suspicious, but since it's an intra-only
codec, I couldn't possibly imagine what it would use the edge for,
and the vsynth fate result doesn't change, so it's probably OK.
2015-08-28 14:40:59 -04:00
Philip Langdale
1e50f953fa Changelog: Add VDPAU HEVC to the list
Signed-off-by: Philip Langdale <philipl@overt.org>
2015-08-28 08:16:39 -07:00
Paul B Mahol
9f2fa95bd8 avfilter/vf_histogram: 9 and 10 bit depth support
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-08-28 14:15:17 +00:00
Harshit Mittal
53bf32fa42 doc/examples/filtering_video: better demo ffmpeg filters; demos chaining the filters
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 12:53:35 +02:00
Carl Eugen Hoyos
24e0b14c4f Changelog: Clarify that the new asf demuxer is optional. 2015-08-28 11:08:28 +02:00
Thilo Borgmann
2392da164a Changelog: Mention the change of the default webm codecs.
Signed-off-by: Carl Eugen Hoyos <cehoyos@ag.or.at>
2015-08-28 06:05:41 +02:00
Carl Eugen Hoyos
b009d5b1f7 configure: Do not let the webm muxer suggest external libraries.
This can fail as seen on fate and the usefulness of the suggestion is limited.
2015-08-28 06:03:58 +02:00
Donny Yang
51ca703222 apng: Support inter-frame compression
The current algorithm is just "try all the combinations, and pick the best".
It's not very fast either, probably due to a lot of copying, but will do for
an initial implementation.

Signed-off-by: Donny Yang <work@kota.moe>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 04:25:15 +02:00
Michael Niedermayer
3322f0d415 avcodec/dnxhddata: Fix inconsistent table entry
Fixes segfault
Fixes Ticket4809

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 04:07:42 +02:00
rogerdpack
832b4a4a43 configure: Print out enabled programs
Better message that ffplay is not going to be built by printing out what
will be built.

Based on a patch by Moritz Barsnick.

Signed-off-by: rogerdpack <rogerpack2005@gmail.com>
Reviewed-by: Ganesh Ajjanagadde <gajjanag@mit.edu>
Signed-off-by: Timothy Gu <timothygu99@gmail.com>
2015-08-27 16:26:54 -07:00
Michael Niedermayer
e2b19a533d avformat/segment: atomically update list if possible
Fixes Ticket4802

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 00:09:56 +02:00
Zhang Rui
92d378067e ffplay: remove unused include libavutil/colorspace.h
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-28 00:09:42 +02:00
Ganesh Ajjanagadde
9ba511d5d3 avfilter/af_amerge: use the name 's' for the pointer to the private context
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-08-27 21:01:01 +00:00
Paul B Mahol
15f4b3db58 avfilter: add framerate video filter
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-08-27 20:00:36 +00:00
Stefano Sabatini
57cd2f7777 lavf/mpegenc: provide better feedback in case of invalid media type 2015-08-27 18:07:43 +02:00
lummax
0c800b2761 avcodec: Assert on codec->encode2 in encode_audio2
Assert on `avctx->codec->encode2` to avoid a SEGFAULT on the subsequent
function call.

avcodec_encode_video2() uses a similar assertion.
Calling the wrong function on a stream is a serious inconsistency
which could at other places be potentially dangerous and exploitable,
it is thus safer to stop execution and not continue with such
inconsistency after returning an error.

Commit-message-extended-by commiter
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-27 17:26:24 +02:00
Timo Rothenpieler
1dd854e10f vaapi: Add hevc hwaccel support
Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2015-08-27 17:05:44 +02:00
Ganesh Ajjanagadde
bfe525e632 configure: warn if GCC 4.2 is being used
The wiki, Ticket1464, and Ticket3970 warn about the usage of GCC 4.2.
This fixes Ticket3970.

Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-08-27 16:56:34 +02:00
Carl Eugen Hoyos
0382c546cc lavc: Describe eia_608 as text subtitles. 2015-08-27 16:42:39 +02:00
Michael Niedermayer
6701c92fa4 avcodec/libopusenc: Fix infinite loop on flushing after 0 input
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-27 12:44:31 +02:00
Ganesh Ajjanagadde
f174bfea86 configure: remove unused apply() function
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-27 11:47:52 +02:00
Hendrik Leppkes
f5258a7d16 Merge commit 'e176639bcbf4b580edb462a6b0650e53cd5e3c04'
* commit 'e176639bcbf4b580edb462a6b0650e53cd5e3c04':
  webm: Explicitly select libvpx, libopus and libvorbis encoders

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:53:07 +02:00
Hendrik Leppkes
ebff705c2c Merge commit '413d4e54a9bffe2d0afdc6d8a80f516e5df6a421'
* commit '413d4e54a9bffe2d0afdc6d8a80f516e5df6a421':
  nvenc: Properly free the fifos

Not merged, ffmpeg's nvenc doesn't use these fifos.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:50:53 +02:00
Hendrik Leppkes
540f280098 Merge commit '2157df425bd909854fd4afcec4aa3311d8a3b31b'
* commit '2157df425bd909854fd4afcec4aa3311d8a3b31b':
  hlsenc: Support outputting specific versions

Not merged, the version is auto-selected in ffmpeg based on enabled features.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:49:21 +02:00
Hendrik Leppkes
427598a2f4 Merge commit 'd68705c9756e6558c8e28d90b4c364f25ba72083'
* commit 'd68705c9756e6558c8e28d90b4c364f25ba72083':
  dnxhddata: Add tables for missing DNx100 profiles

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:40:06 +02:00
Hendrik Leppkes
f30132f9c4 Merge commit 'a4615572b576d3ef7ee2f11529d935e61bf4ebb8'
* commit 'a4615572b576d3ef7ee2f11529d935e61bf4ebb8':
  dnxhddata: Merge a few duplicated RUN tables

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:31:52 +02:00
Hendrik Leppkes
f19a283867 Merge commit 'efbfb1ad1112cea79bef51fd9f30c0c94735abfc'
* commit 'efbfb1ad1112cea79bef51fd9f30c0c94735abfc':
  dnxhddata: Group together RUN-related tables

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:29:54 +02:00
Hendrik Leppkes
305f461754 Merge commit '403ea4ac7289ac39229452b6b5e2f8ebcc00f2a1'
* commit '403ea4ac7289ac39229452b6b5e2f8ebcc00f2a1':
  dnxhddata: Merge a few duplicated DC tables

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:27:02 +02:00
Hendrik Leppkes
3b0af76c1b Merge commit '5e129ed655bff5b6d90355c0b713d7aaba3898ec'
* commit '5e129ed655bff5b6d90355c0b713d7aaba3898ec':
  dnxhddata: Group together DC-related tables

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:26:14 +02:00
Hendrik Leppkes
3f491224fe Merge commit 'd3ae4c65942d67a294fd56eabbbdcce6756fab5f'
* commit 'd3ae4c65942d67a294fd56eabbbdcce6756fab5f':
  dnxhddata: List the reused tables in a comment

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:19:41 +02:00
Hendrik Leppkes
bd074bde02 Merge commit 'fdd021884d5c06fb9ad65cb0040bb5717a7b084b'
* commit 'fdd021884d5c06fb9ad65cb0040bb5717a7b084b':
  dnxhddata: Keep a single CID in the table names

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-08-27 09:17:37 +02:00
Michael Niedermayer
81a8701eb5 avformat/oggenc: Check segments_count for headers too
Fixes infinite loop and segfault in ogg_buffer_data()
Fixes Ticket4806

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-27 04:28:21 +02:00