1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-07 11:13:41 +02:00
Commit Graph

82975 Commits

Author SHA1 Message Date
Andreas Cadhalpun
4c45566493 configure: enable autodetected libraries after option parsing
And only enable them, if they haven't been disabled.

This is needed for the following patch.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-12-10 19:29:37 +01:00
Andreas Cadhalpun
c50d591ce2 configure: enable sdl if sdl2 is enabled
sdl is supposed to be an alias, so it should have the same value.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-12-10 19:29:37 +01:00
Derek Buitenhuis
51c673a0d7 libavcodec/tests: Add avpacket test to .gitignore
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-12-10 15:51:01 +00:00
Mark Thompson
db7271bff2 configure: Require bit_depth field for VAAPI VP9 decode hwaccel
libva versions from 1.6.0 to 1.6.2 do not include it, and therefore
cannot work with VP9 profile >= 2.

Fixes ticket #6003.
2016-12-10 13:53:30 +00:00
Andreas Cadhalpun
c085f1a7e1 opus_parser: make ParseContext the first element in OpusParseContext
ff_parse_close expects priv_data to be the ParseContext directly and
thus doesn't work if it isn't at the beginning of OpusParseContext.

Reviewed-by: Hendrik Leppkes <h.leppkes@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-12-10 13:36:57 +01:00
Andreas Cadhalpun
7d3baebe40 opus_parser: fix leaking channel_maps on error
Make ff_opus_parse_extradata free allocated memory on error instead of
expecting callers to free it in that case.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-12-10 13:36:12 +01:00
Marton Balint
df694a5e9d avfilter/af_ashowinfo: properly show input channel layout for unknown channel layouts
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Marton Balint <cus@passwd.hu>
2016-12-10 11:57:12 +01:00
Marton Balint
01a19f77ca avfilter/af_channelmap: add support for unknown input channel layouts
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Marton Balint <cus@passwd.hu>
2016-12-10 11:57:11 +01:00
Marton Balint
bffc2bcd75 avfilter/af_atempo: add support for unknown channel layouts
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Marton Balint <cus@passwd.hu>
2016-12-10 11:57:11 +01:00
Marton Balint
7ceb9e6b11 avfilter/formats: allow unknown channel layouts by default
Since the default in the libav fork is to only allow known layouts, making
unknown layouts allowed by default here can be a security risk for filters
directly merged from libav. However, usually it is simple to detect such cases,
use of av_get_channel_layout_nb_channels is a good indicator, so I suggest we
change this regardless.

See http://ffmpeg.org/pipermail/ffmpeg-devel/2016-November/203204.html.

This patch indirectly adds unknown channel layout support for filters where
query_formats is not specified:

abench
afifo
ainterleave
anullsink
apad
aperms
arealtime
aselect
asendcmd
asetnsamples
asetpts
asettb
ashowinfo
azmq

It introduces a query_formats callback for the asyncts filter, which only
supports known channel layouts since it is using libavresample.

And it removes .query_formats callback from filters where it was only there to
support unknown layouts, as this is now the default:

aloop
ametadata
anull
asidedata
asplit
atrim

Acked-by: Nicolas George <george@nsup.org>
Signed-off-by: Marton Balint <cus@passwd.hu>
2016-12-10 11:57:11 +01:00
Michael Niedermayer
5b73ba9887 avcodec/mpeg12dec: Add FF_CODEC_CAP_SKIP_FRAME_FILL_PARAM
This decreases the amount of computations and memory needed for analysing mpeg1/2 streams

the properties update is moved from code that is skiped if skip_frame is set
to code that is not skiped so the change doesnt loose that
from being executed

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 04:58:52 +01:00
Michael Niedermayer
65e33d8e23 swresample/resample_template: Add filter values in parallel
This is faster 2871 -> 2189  cycles for int16 matrixbench -> 23456hz
Fixes a integer overflow in a artificial corner case
Fixes part of 668007-media

Found-by: Matt Wolenetz <wolenetz@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 02:44:21 +01:00
Michael Niedermayer
34db650784 swresample/resample_template: Reorder operations to avoid one addition
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 02:05:17 +01:00
Michael Niedermayer
b3928a1cc6 swresample/swresample: Check count before memcpy()
Fixes undefined operation
Fixes part of 668007-media

Found-by: Matt Wolenetz <wolenetz@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 02:05:17 +01:00
Michael Niedermayer
8258e36385 avcodec/mpeg4videodec: Fix undefined shifts in mpeg4_decode_sprite_trajectory()
Fixes: part of 670190.ogg

Found-by: Matt Wolenetz <wolenetz@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-09 17:44:54 +01:00
Michael Niedermayer
ee2a6f5df8 avformat/oggdec: Skip streams in duration correction that did not had their duration set.
Fixes: part of 670190.ogg
Fixes integer overflow

Found-by: Matt Wolenetz <wolenetz@google.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-09 17:43:47 +01:00
Derek Buitenhuis
4413e950b2 h264_slice: Wait for refs to be available before we use them in error concealment
This could happen when there was a frame number gap and frame threading was used.

This fixes #5458.

Debugging-by: Ronald S. Bultje <rsbultje@gmail.com>
Debugging-by: Justin Ruggles <justin.ruggles@gmail.com>
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-12-09 15:00:29 +00:00
James Almer
06c62ce09c fate: add a monoscopic spherical matroska test
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-09 11:19:38 -03:00
James Almer
77aa8005ec fate: improve fate-mov dependencies
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-09 11:19:29 -03:00
Michael Niedermayer
38a7834bbb avcodec/ffv1enc: Allocate smaller packet if the worst case size cannot be allocated
We are checking during encoding if there is enough space as version 4 needs that
check.

Fixes Ticket6005

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-09 01:59:40 +01:00
Michael Niedermayer
cff1c0edaa avcodec/ffv1enc: Fix size of first slice
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-09 01:59:30 +01:00
Alex Converse
51a055b206 aacdec: Rename elem_type_prev to che_prev_type.
It describes the type of the previous che element (SCE, CPE, CCE, or
LFE) and does not reflect non-che elements.
2016-12-08 13:31:50 -08:00
Alex Converse
d379592687 aacdec: Allow SBR after DRC.
Fixes https://www2.iis.fraunhofer.de/AAC/7.1auditionOutLeader_v2_rtb.mp4

Reported-by: rcombs on IRC
2016-12-08 13:31:50 -08:00
Lou Logan
ee795d9d26 doc/muxers: remove "-strict experimental" from tee muxer examples
Examples use the native FFmpeg AAC encoder but it is no longer
considered experimental and therefore not required.

Signed-off-by: Lou Logan <lou@lrcd.com>
2016-12-08 12:06:05 -09:00
Paul B Mahol
a251149833 avfilter/vf_deband: fix silly mistakes
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2016-12-08 21:29:58 +01:00
Michael Niedermayer
1296f84495 avformat: Add max_streams option
This allows user apps to stop OOM due to excessive number of streams

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-08 18:25:30 +01:00
Martin Storsjö
da5c8284c0 aarch64: h264idct: Use the offset parameter to movrel
Signed-off-by: Martin Storsjö <martin@martin.st>
(cherry picked from commit 6a62795d40)
Cherry pick Suggested-by: Martin Storsjö

This should fix the build failure on macosx

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-08 18:11:07 +01:00
Srinath K R
4df5a6a26a avfilter/vf_hwupload_cuda: Add min/max limits for the 'device' option
Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2016-12-08 11:11:26 +01:00
James Almer
120471da2d avformat/matroskadec: remove unused variable
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-08 01:23:24 -03:00
James Almer
8396d54d3c avformat/matroskadec: fix memleak on stream side data failure
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-08 01:21:11 -03:00
Michael Niedermayer
3ab1311aba avcodec/golomb: Consume invalid data in get_ur_golomb_jpegls()
Fixes slow loops on fuzzed data
Fixes: 245/fuzz-3-ffmpeg_AUDIO_AV_CODEC_ID_FLAC_fuzzer

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-08 02:47:47 +01:00
James Almer
445204cd57 avformat/matroskadec: add support for Spherical Video elements
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-07 22:40:59 -03:00
Andreas Cadhalpun
e3694478a9 yuv4mpegdec: fix leaking pkt in yuv4_read_packet
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-12-08 00:26:41 +01:00
James Darnley
acdd2d805d avcodec/h264: resolve assert being triggered when stack is not aligned
32-bit msvc.
2016-12-07 22:32:19 +01:00
Vittorio Giovara
0c0da45f0f fate: Add a monoscopic spherical mov test 2016-12-07 14:41:02 -05:00
Vittorio Giovara
4dcdecf471 mov: Export spherical information
This implements Spherical Video V1 and V2, as described in the
spatial-media collection by Google.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-12-07 14:40:59 -05:00
Vittorio Giovara
e7a6f8c972 lavc: Add spherical packet side data API
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-12-07 14:40:06 -05:00
Vittorio Giovara
8f58ecc344 lavu: Add AVSphericalMapping type and frame side data
While no decoder currently exports spherical information, this type
represents a frame property that has to be passed through from container
to frames.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-12-07 14:39:04 -05:00
Michael Niedermayer
c188f358aa avcodec/wavpack: Treat the first block coding too many channels as an error
Fixes memleak
Fixes: 236/8aeebc9ca49b91bf71c114dcefac56c154a3a563

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-07 13:16:32 +01:00
Steven Liu
6b95da9af9 avformat/hlsenc: save the EXT-X-DISCONTINUITY from old list
when use fix ticket 2nd problem.

command line test step:
rm -rf output*;./ffmpeg  -i ~/Movies/objectC/facebook.mp4 -an -c:v copy
-f hls -hls_time 4 -hls_list_size 5 -hls_flags +delete_segments
-hls_flags +append_list -hls_flags +omit_endlist -hls_flags
+discont_start -t 50 output.m3u8
./ffmpeg -i ~/Movies/objectC/facebook.mp4 -an -c:v libx264 -g 4 -f hls
-hls_time 4 -hls_list_size 5 -hls_flags +delete_segments -hls_flags
+append_list -hls_flags +omit_endlist -hls_flags +discont_start -t 5
output.m3u8
./ffmpeg -i ~/Movies/objectC/facebook.mp4 -an -c:v libx264 -g 4 -f hls
-hls_time 4 -hls_list_size 5 -hls_flags +delete_segments -hls_flags
+append_list -hls_flags +omit_endlist -hls_flags +discont_start -t 5
output.m3u8

result:
 #EXTM3U
 #EXT-X-VERSION:3
 #EXT-X-TARGETDURATION:5
 #EXT-X-MEDIA-SEQUENCE:6
 #EXTINF:4.120000,
 output6.ts
 #EXT-X-DISCONTINUITY
 #EXTINF:4.000000,
 output7.ts
 #EXTINF:0.960000,
 output8.ts
 #EXT-X-DISCONTINUITY
 #EXTINF:4.000000,
 output9.ts
 #EXTINF:0.960000,
 output10.ts

Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2016-12-07 07:43:36 +08:00
James Darnley
728651df06 avcodec/h264: mmx2, sse2, avx 10-bit 4:2:2 h chroma deblock/loop filter
Yorkfield:
 - mmx2: 2.53x (504 vs. 199 cycles)
 - sse2: 3.83x (504 vs. 131 cycles)

Nehalem:
 - mmx2: 2.42x (365 vs. 151 cycles)
 - sse2: 3.56x (365 vs. 103 cycles)

Skylake:
 - mmx2: 1.81x (308 vs. 170 cycles)
 - sse2: 2.84x (308 vs. 108 cycles)
 - avx:  2.93x (308 vs. 105 cycles)
2016-12-07 00:29:13 +01:00
James Darnley
add21d0bb3 avcodec/h264: mmx2, sse2, avx 10-bit h chroma deblock/loop filter
Yorkfield:
 - mmx2: 2.45x (279 vs. 114 cycles)
 - sse2: 3.36x (279 vs.  83 cycles)

Nehalem:
 - mmx2: 2.10x (192 vs.  92 cycles)
 - sse2: 2.84x (192 vs.  68 cycles)

Skylake:
 - mmx2: 1.75x (170 vs.  97 cycles)
 - sse2: 2.47x (170 vs.  69 cycles)
 - avx:  2.47x (170 vs.  69 cycles)
2016-12-07 00:29:13 +01:00
James Darnley
58ca2ef62e whitespace changes after last commit 2016-12-07 00:29:13 +01:00
James Darnley
f33714a694 avcodec/h264: clean up and expand x86 function definitions 2016-12-07 00:29:13 +01:00
Timothy Gu
b6f80b16d1 qsvdec: Fix memory leak
Fixes CID1396851.
2016-12-06 13:21:08 -08:00
Timothy Gu
16a75304fe omx: Fix OOM check
Also use av_mallocz_array().

Fixes CID1396839.
2016-12-06 13:20:55 -08:00
Georgi D. Sotirov
581f93f37e lavf/chromaprint: Update for version 1.4
Fixes ticket #5997.
2016-12-06 21:07:59 +01:00
Thomas Turner
da3c69a5a9 Added test for libavcodec/avpacket.c
Signed-off-by: Thomas Turner <thomastdt@googlemail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-06 17:12:38 +01:00
Michael Niedermayer
7679c38b3b tests/api/api-seek-test: check all compute_crc_of_packets() calls
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-06 15:42:07 +01:00
Michael Niedermayer
5952b8da0b tests/api/api-seek-test: Silence compiler warnings about uninitialized variables
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-06 15:41:32 +01:00