Commit Graph

62785 Commits

Author SHA1 Message Date
Michael Niedermayer
e20ebe491c avcodec/shorten: check bitshift
Fixes invalid shift
Fixes CID1194400

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 13:03:28 +02:00
Carl Eugen Hoyos
ade5851be0 Try mov tags if the fourcc in V_MS/VFW mkv files cannot be found in bmp tags.
Fixes decoding of broken mkv files containing ProRes video from ticket #3434.
2014-04-27 12:52:34 +02:00
Clément Bœsch
b2cfd1fde7 avfilter/curves: fix resource leaks.
Fixes CID1206650
2014-04-27 11:49:13 +02:00
Michael Niedermayer
b432960528 avcodec/mjpegdec: Fix undefined shift
Fixes CID1194388

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 05:32:56 +02:00
Michael Niedermayer
bc3234062d avcodec/truemotion2: replace impossible condition by av_assert2
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 05:20:04 +02:00
Michael Niedermayer
09b16619d3 ffmpeg_filter: fix pointer to local outside scope
Fixes CID1206652
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 05:07:29 +02:00
Michael Niedermayer
6956b048d8 avfilter/vf_drawtext: fix resource leaks
Fixes CID1206649

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-27 03:18:57 +02:00
Michael Niedermayer
66e30a2e65 avformat/mpegtsenc: check avformat_new_stream() return
Fixes CID1206645
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 22:08:37 +02:00
Michael Niedermayer
24725f8e09 avformat/matroskaenc: fix indention level
Fixes CID1206644
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 22:01:48 +02:00
Michael Niedermayer
9b1d7d4fd3 avformat/oggparsecelt: fix memleak
Fixes: CID1108605

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 21:31:15 +02:00
Michael Niedermayer
68de2115ca avformat/tee: print errors for each failed bitstream filter
Fixes CID1108584

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 21:08:44 +02:00
Michael Niedermayer
ebfe154bd5 avcodec/apedec: tmpk==32 is not supported, prevent undefined behavior
Fixes CID1206639
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 20:56:31 +02:00
tue46wsdgxfjrt
669a09fb37 Add AV_LOG_PRINT_LEVEL flag to include log severity in default log formatting.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 19:27:33 +02:00
tue46wsdgxfjrt
262ea965e7 cmdutils: preserve unchanged log flags when setting AV_LOG_SKIP_REPEATED
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 19:21:59 +02:00
Lukasz Marek
b217dc91bf lavfi/avfilter: clarify avfilter_graph_get_filter() doxygen
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 02:16:56 +02:00
Michael Niedermayer
3ba77ea369 avcodec/vc1dec: print debug message if a b frame without reference is skiped
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 01:41:31 +02:00
Michael Niedermayer
8b2c3d2ae9 Merge commit 'cdf6eb5a9710566be217a3f17d3d94ac4e4d2662'
* commit 'cdf6eb5a9710566be217a3f17d3d94ac4e4d2662':
  vc1: Do not return an error when skipping b frames

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-26 01:06:15 +02:00
Reynaldo H. Verdejo Pinochet
7228bdeebd ffserver: fix missing frees at connection setup
Should fix FFmpeg Coverity Scan issue #732266 and some of #732265

Signed-off-by: Reynaldo H. Verdejo Pinochet <r.verdejo@sisa.samsung.com>
2014-04-25 19:49:55 -03:00
Reynaldo H. Verdejo Pinochet
1404e2a389 ffserver: free AVStream st before wiping context
Should fix FFmpeg Coverity Scan issue #732269

Signed-off-by: Reynaldo H. Verdejo Pinochet <r.verdejo@sisa.samsung.com>
2014-04-25 19:49:55 -03:00
Reynaldo H. Verdejo Pinochet
107f2468c4 ffserver: free nacl as needed
Should fix FFmpeg Coverity Scan issue #732268

Signed-off-by: Reynaldo H. Verdejo Pinochet <r.verdejo@sisa.samsung.com>
2014-04-25 19:49:55 -03:00
Lukasz Marek
b2682db34c lavfi/avfilter: fix typos in doxgens
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 23:49:11 +02:00
Michael Niedermayer
e0e60c9211 avcodec/dpx: extract frame rate
Fixes part of Ticket3511

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 23:40:59 +02:00
Michael Niedermayer
af165acefa avformat/movenc: dont store invalid tapt atom
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 21:51:34 +02:00
Michael Niedermayer
c9e0f7a080 Merge commit '99e22b7859177f6d3ed6121040924b337dce5497'
* commit '99e22b7859177f6d3ed6121040924b337dce5497':
  mov: Emit the correct tags for clcp tracks

Conflicts:
	libavformat/movenc.c

See: a5f6720f13
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 21:33:18 +02:00
Michael Niedermayer
944a744bf5 Merge commit '802385dbc2c57abd76f6a00e32f3df35e9526c08'
* commit '802385dbc2c57abd76f6a00e32f3df35e9526c08':
  mov: Write prof section of tapt tag

See: 8a9b48bfa9
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 20:52:59 +02:00
Don Moir
62056d09b1 avformat/avidec: skip len=0 entries from the index
Reduces cpu & memory requirements for the index
See Ticket 3531

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 18:56:05 +02:00
Alessandro Ghedini
cdf6eb5a97 vc1: Do not return an error when skipping b frames
This caused mpv (and possibly others) to fallback to software decoding after
seeking a VC1 stream.

Bug-Id: 667

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-04-25 18:22:25 +02:00
Miles Gould
99e22b7859 mov: Emit the correct tags for clcp tracks
Bug-Id: 664

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-04-25 17:38:19 +02:00
Aidan Skinner
802385dbc2 mov: Write prof section of tapt tag
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2014-04-25 17:38:19 +02:00
James Almer
cdac3ab59f swresample: add swri_resample_double_sse2
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 16:46:07 +02:00
Michael Niedermayer
92cc6d5163 avcodec/mdct_template: Use av_malloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 15:07:31 +02:00
Michael Niedermayer
681a5b8d6f avcodec/ttaenc: use av_malloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 15:04:42 +02:00
Michael Niedermayer
abbcc6b26b avcodec/utils: use av_malloc(z)_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 15:03:26 +02:00
Michael Niedermayer
2f2629c870 Merge commit '6d69f9f37689c999815a65a2d99999fad3a41705'
* commit '6d69f9f37689c999815a65a2d99999fad3a41705':
  vp9: write uveob as 16-bit value for 16x16/32x32 transforms.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 13:55:44 +02:00
Ronald S. Bultje
6d69f9f376 vp9: write uveob as 16-bit value for 16x16/32x32 transforms.
This fixes make fate-vp9-00-quantizer-01 THREADS=2.
2014-04-25 07:51:39 -04:00
James Almer
c7b089048d vp9: use LOCAL_ALIGNED_32 for left/top intra_pred pointers
This is needed for future AVX2 implementations

Signed-off-by: James Almer <jamrial@gmail.com>
Reviewed-by: "Ronald S. Bultje" <rsbultje@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 06:13:15 +02:00
James Almer
25d5ea6d5a lavu: add LOCAL_ALIGNED_32
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 06:12:51 +02:00
Y.C. Liu
cebe06a0bf avutil/opencl: fix a segmentfault in libavutil/opencl.c
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 05:29:21 +02:00
Michael Niedermayer
6e5cce1cbe configure: allow overriding ranlib
Reviewed-by: Timothy Gu <timothygu99@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 04:28:43 +02:00
Ben Avison
a0d7f9ec9a vc-1: Optimise parser (with special attention to ARM)
The previous implementation of the parser made four passes over each input
buffer (reduced to two if the container format already guaranteed the input
buffer corresponded to frames, such as with MKV). But these buffers are
often 200K in size, certainly enough to flush the data out of L1 cache, and
for many CPUs, all the way out to main memory. The passes were:

1) locate frame boundaries (not needed for MKV etc)
2) copy the data into a contiguous block (not needed for MKV etc)
3) locate the start codes within each frame
4) unescape the data between start codes

After this, the unescaped data was parsed to extract certain header fields,
but because the unescape operation was so large, this was usually also
effectively operating on uncached memory. Most of the unescaped data was
simply thrown away and never processed further. Only step 2 - because it
used memcpy - was using prefetch, making things even worse.

This patch reorganises these steps so that, aside from the copying, the
operations are performed in parallel, maximising cache utilisation. No more
than the worst-case number of bytes needed for header parsing is unescaped.
Most of the data is, in practice, only read in order to search for a start
code, for which optimised implementations already existed in the H264 codec
(notably the ARM version uses prefetch, so we end up doing both remaining
passes at maximum speed). For MKV files, we know when we've found the last
start code of interest in a given frame, so we are able to avoid doing even
that one remaining pass for most of the buffer.

In some use-cases (such as the Raspberry Pi) video decode is handled by the
GPU, but the entire elementary stream is still fed through the parser to
pick out certain elements of the header which are necessary to manage the
decode process. As you might expect, in these cases, the performance of the
parser is significant.

To measure parser performance, I used the same VC-1 elementary stream in
either an MPEG-2 transport stream or a MKV file, and fed it through ffmpeg
with -c:v copy -c:a copy -f null. These are the gperftools counts for
those streams, both filtered to only include vc1_parse() and its callees,
and unfiltered (to include the whole binary). Lower numbers are better:

                Before          After
File  Filtered  Mean   StdDev   Mean   StdDev  Confidence  Change
M2TS  No        861.7  8.2      650.5  8.1     100.0%      +32.5%
MKV   No        868.9  7.4      731.7  9.0     100.0%      +18.8%
M2TS  Yes       250.0  11.2     27.2   3.4     100.0%      +817.9%
MKV   Yes       149.0  12.8     1.7    0.8     100.0%      +8526.3%

Yes, that last case shows vc1_parse() running 86 times faster! The M2TS
case does show a larger absolute improvement though, since it was worse
to begin with.

This patch has been tested with the FATE suite (albeit on x86 for speed).

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 02:36:29 +02:00
Ben Avison
9d8ecdd8ca vc-1: Add platform-specific start code search routine to VC1DSPContext.
Initialise VC1DSPContext for parser as well as for decoder.
Note, the VC-1 code doesn't actually use the function pointer yet.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 02:36:11 +02:00
Ben Avison
270cede3f3 h264: Move search code search functions into separate source files.
This permits re-use with parsers for codecs which use similar start codes.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 02:35:56 +02:00
Michael Niedermayer
e148a5820d Merge remote-tracking branch 'cehoyos/master'
* cehoyos/master:
  Enable muxing ac-3 in caf.
  Use correct msvc type specifiers for ptrdiff_t and size_t.
  Fix vf_eq.c and vf_eq2.c compilation with !HAVE_6REGS.
  Fix libpostproc compilation with !HAVE_6REGS.
  Never write 0 as maximum bitrate for asf files.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 01:56:23 +02:00
Michael Niedermayer
817627d925 Merge commit '8de77b665d2a2f1cd560d2183fd4664298b30715'
* commit '8de77b665d2a2f1cd560d2183fd4664298b30715':
  fate: Add fic-in-avi test

Conflicts:
	tests/ref/fate/fic-avi

See: d66de5006b
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 01:33:41 +02:00
Michael Niedermayer
e32fc9b45b Merge commit 'a24a252709dd38f12aa4929ce4981f87091a5113'
* commit 'a24a252709dd38f12aa4929ce4981f87091a5113':
  aarch64: NEON optimized FIR audio resampling

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 01:19:27 +02:00
Michael Niedermayer
26953ed2e3 Merge commit 'cae8df78759c2e69257f7fe58842f34c0d98a7ec'
* commit 'cae8df78759c2e69257f7fe58842f34c0d98a7ec':
  lavr: define ResampleContext in resample.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 01:17:15 +02:00
Michael Niedermayer
06e664366a Merge commit 'a88e1d1c598e641eecd5d43730211d91c82787c6'
* commit 'a88e1d1c598e641eecd5d43730211d91c82787c6':
  lavu: add CHK_OFFS as AV_CHECK_OFFSET to check struct member offsets

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 00:55:40 +02:00
James Almer
5ac10d40fb x86/mpegaudiodsp: define apply_window_mp3 as SSE
None of the handwritten asm in this function seems to be SSE2

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-25 00:38:01 +02:00
Derek Buitenhuis
d66de5006b fate: Add fic-in-avi test
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2014-04-24 22:01:33 +01:00
Derek Buitenhuis
8de77b665d fate: Add fic-in-avi test
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2014-04-24 22:00:50 +01:00