ffmpeg.git
2 years agoswresample/resample: do not assert compensation_distance on rebuild_filter
Muhammad Faiz [Fri, 17 Mar 2017 00:46:20 +0000 (07:46 +0700)]
swresample/resample: do not assert compensation_distance on rebuild_filter

when set_compensation is called with zero sample_delta,
compensation does not happen (because dst_incr == ideal_dst_incr)
but compensation_distance is set

regression since 01ebb57c03abde89bca7bdbc552917efcb8f551d

Found-by: wm4 <nfxjfg@googlemail.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2 years agoavcodec: fix uninitialized variable read
wm4 [Tue, 7 Mar 2017 08:56:42 +0000 (09:56 +0100)]
avcodec: fix uninitialized variable read

This cna happen if the user tries to call the new decode API for
subtitles.

Fixes CID 1402071.

2 years agolavu/spherical: Make AVSphericalMapping pointer parameter const.
Carl Eugen Hoyos [Thu, 16 Mar 2017 20:19:48 +0000 (21:19 +0100)]
lavu/spherical: Make AVSphericalMapping pointer parameter const.

Reflects the actual code and silences a gcc warning:
ffprobe.c:1797:42: warning: passing argument 1 of 'av_spherical_tile_bounds' discards 'const' qualifier from pointer target type

2 years agoMerge commit '0df4801105d84883071b0978cb3afc7cd5184ce8'
Clément Bœsch [Thu, 16 Mar 2017 20:44:15 +0000 (21:44 +0100)]
Merge commit '0df4801105d84883071b0978cb3afc7cd5184ce8'

* commit '0df4801105d84883071b0978cb3afc7cd5184ce8':
  vp9: make mv bounds 32bit.

This commit is a noop, see 024fac5cd4f74d237b7b285355d7e463c1911196

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '24a362569bff1d4161742fffaca80a4a4428be8a'
Clément Bœsch [Thu, 16 Mar 2017 20:42:45 +0000 (21:42 +0100)]
Merge commit '24a362569bff1d4161742fffaca80a4a4428be8a'

* commit '24a362569bff1d4161742fffaca80a4a4428be8a':
  buffer: fix av_buffer_realloc() when the data is offset wrt buffer start

Merged-by: Clément Bœsch <u@pkh.me>
2 years agolavc/internal: Constify AVPacket* in AVCodecInternal.
Carl Eugen Hoyos [Sun, 26 Feb 2017 11:34:41 +0000 (12:34 +0100)]
lavc/internal: Constify AVPacket* in AVCodecInternal.

Fixes a gcc warning:
libavcodec/utils.c:2244:26: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]

2 years agolavc/avpacket: Make pkt parameter of av_packet_get_side_data() const.
Carl Eugen Hoyos [Sun, 26 Feb 2017 10:58:49 +0000 (11:58 +0100)]
lavc/avpacket: Make pkt parameter of av_packet_get_side_data() const.

Reflects the actual code and silences a gcc warning:
libavcodec/utils.c:2102:36: warning: passing argument 1 of 'av_packet_get_side_data' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]

2 years agodoc/muxers: cleanup mpegts section
Lou Logan [Thu, 16 Mar 2017 03:51:01 +0000 (19:51 -0800)]
doc/muxers: cleanup mpegts section

Add missing options.
List correct variable types.
Re-order options and markup flag options properly.
Add more texinfo markup.

Signed-off-by: Lou Logan <lou@lrcd.com>
2 years agoconfigure: clang -Oz for small size build to reduce size further
wang-bin [Fri, 10 Mar 2017 04:02:13 +0000 (04:02 +0000)]
configure: clang -Oz for small size build to reduce size further

2 years agolavf/mpegtsenc: clarify pcr_period unit of measurement
Lou Logan [Thu, 16 Mar 2017 02:45:12 +0000 (18:45 -0800)]
lavf/mpegtsenc: clarify pcr_period unit of measurement

pcr_period is in milliseconds.

Signed-off-by: Lou Logan <lou@lrcd.com>
2 years agoMerge commit 'e99ecda55082cb9dde8fd349361e169dc383943a'
Clément Bœsch [Thu, 16 Mar 2017 19:16:48 +0000 (20:16 +0100)]
Merge commit 'e99ecda55082cb9dde8fd349361e169dc383943a'

* commit 'e99ecda55082cb9dde8fd349361e169dc383943a':
  checkasm: add vp9 MC tests.
  vp9mc/x86: sse2 MC assembly.
  vp9mc/x86: add AVX and AVX2 MC
  vp9mc/x86: rename ff_* to ff_vp9_*
  vp9mc/x86: rename ff_avg[48]_sse to ff_avg[48]_mmxext
  vp9mc/x86: simplify a few inits.
  vp9mc/x86: add 16px functions (64bit only).

Noop (aside from a formatting comment in vp9mc.asm). We already have all
of this. We should consider making a final diff between the two projects
when the dust comes down.

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '89466de4aeaf5e359489b81b8a9920a2bc7936d6'
Clément Bœsch [Thu, 16 Mar 2017 19:10:24 +0000 (20:10 +0100)]
Merge commit '89466de4aeaf5e359489b81b8a9920a2bc7936d6'

* commit '89466de4aeaf5e359489b81b8a9920a2bc7936d6':
  vp9/x86: rename vp9dsp to vp9mc

File was already renamed, only the top description is updated.

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoswresample/options: enable linear_interp and exact_rational by default
Muhammad Faiz [Mon, 13 Mar 2017 13:33:03 +0000 (20:33 +0700)]
swresample/options: enable linear_interp and exact_rational by default

better quality without speedloss

Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2 years agoavcodec/h264_cabac: Fix runtime error: negation of -2147483648 cannot be represented...
Michael Niedermayer [Wed, 15 Mar 2017 02:48:59 +0000 (03:48 +0100)]
avcodec/h264_cabac: Fix runtime error: negation of -2147483648 cannot be represented in type 'int'; cast to an unsigned type to negate this value to itself

Fixes: 858/clusterfuzz-testcase-5168477042114560

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/h264idct_template: fix multiple runtime error: signed integer overflow
Michael Niedermayer [Wed, 15 Mar 2017 01:58:16 +0000 (02:58 +0100)]
avcodec/h264idct_template: fix multiple runtime error: signed integer overflow

Fixes: 857/clusterfuzz-testcase-5319093760557056

Benchmark changes from 335->333 (so if its not a random fluctuation then it would be faster)

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agofate: Add vf_framerate test.
Alexis Ballier [Sat, 11 Mar 2017 19:18:55 +0000 (20:18 +0100)]
fate: Add vf_framerate test.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agolavf/vf_framerate: Fix frame leak when increasing framerate.
Alexis Ballier [Sat, 11 Mar 2017 19:18:54 +0000 (20:18 +0100)]
lavf/vf_framerate: Fix frame leak when increasing framerate.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agolavc/tests/dct/aarch64: add ff_simple_idct_neon test
Matthieu Bouron [Thu, 16 Feb 2017 12:34:53 +0000 (12:34 +0000)]
lavc/tests/dct/aarch64: add ff_simple_idct_neon test

2 years agolavc/aarch64: add ff_simple_idct{,_add,_put}_neon functions
Matthieu Bouron [Fri, 27 Jan 2017 11:55:48 +0000 (11:55 +0000)]
lavc/aarch64: add ff_simple_idct{,_add,_put}_neon functions

2 years agoffmpeg: don't use resample_lavr_opts
Rostislav Pehlivanov [Mon, 6 Mar 2017 02:46:49 +0000 (02:46 +0000)]
ffmpeg: don't use resample_lavr_opts

That pointer isn't used by absolutely anything.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoMerge commit '89aebc5bcc6e23a0a79c3f51c3a55c3571692ba0'
James Almer [Thu, 16 Mar 2017 01:16:53 +0000 (22:16 -0300)]
Merge commit '89aebc5bcc6e23a0a79c3f51c3a55c3571692ba0'

* commit '89aebc5bcc6e23a0a79c3f51c3a55c3571692ba0':
  lavc: align the linesize to 32 when AVX is enabled

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '63ac8e2d93080b74f6be32c7c3c1a1e44aacf34e'
James Almer [Thu, 16 Mar 2017 01:13:41 +0000 (22:13 -0300)]
Merge commit '63ac8e2d93080b74f6be32c7c3c1a1e44aacf34e'

* commit '63ac8e2d93080b74f6be32c7c3c1a1e44aacf34e':
  lavu: add LOCAL_ALIGNED_32

This commit is a noop, see 25d5ea6d5a08820a40dd145d40ddfaecdb44837b

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '3c504bc3599f00bfc5923adc114beef34bce11d0'
James Almer [Thu, 16 Mar 2017 01:07:28 +0000 (22:07 -0300)]
Merge commit '3c504bc3599f00bfc5923adc114beef34bce11d0'

* commit '3c504bc3599f00bfc5923adc114beef34bce11d0':
  x86: deduplicate some constants

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit 'd3e4d406b020b0464486318aceda08bd8f69ca41'
James Almer [Thu, 16 Mar 2017 00:41:29 +0000 (21:41 -0300)]
Merge commit 'd3e4d406b020b0464486318aceda08bd8f69ca41'

* commit 'd3e4d406b020b0464486318aceda08bd8f69ca41':
  h264dec: reset nb_slice_ctx_queued for hwaccel decoding

This commit is a noop, see 744801989099df26e90b00062c645969c5347533

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit 'e5b019725f53b79159931d3a7317107cbbfd0860'
James Almer [Thu, 16 Mar 2017 00:40:35 +0000 (21:40 -0300)]
Merge commit 'e5b019725f53b79159931d3a7317107cbbfd0860'

* commit 'e5b019725f53b79159931d3a7317107cbbfd0860':
  m4vdec: Check for non-startcode 00 00 00 sequences in probe

This commit is a noop, see 7c1835c52a4be2e4e996f83c91a8d5a147b01100

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '3ccec334b8502701e72ef13bed25913c3578022e'
James Almer [Thu, 16 Mar 2017 00:37:40 +0000 (21:37 -0300)]
Merge commit '3ccec334b8502701e72ef13bed25913c3578022e'

* commit '3ccec334b8502701e72ef13bed25913c3578022e':
  sbrdsp: Move a misplaced #endif directive to the right spot

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit 'e723dce6f8ba1e8260433b6ecfe5a3262f4c7a99'
James Almer [Thu, 16 Mar 2017 00:35:36 +0000 (21:35 -0300)]
Merge commit 'e723dce6f8ba1e8260433b6ecfe5a3262f4c7a99'

* commit 'e723dce6f8ba1e8260433b6ecfe5a3262f4c7a99':
  dvbsubdec: Use NULL instead of 0 as pointer value

This commit is a noop. The affected code isn't in our tree.

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit 'fc94a1acc27ab7296edce3fa81ef36691af5c134'
James Almer [Thu, 16 Mar 2017 00:33:59 +0000 (21:33 -0300)]
Merge commit 'fc94a1acc27ab7296edce3fa81ef36691af5c134'

* commit 'fc94a1acc27ab7296edce3fa81ef36691af5c134':
  Revert "libavutil: Use an intermediate variable in AV_COPY*U"

This commit is a noop.

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '9806b9ab5c7fb2ac5efd8ffa8713fea0c5fd218d'
James Almer [Thu, 16 Mar 2017 00:33:13 +0000 (21:33 -0300)]
Merge commit '9806b9ab5c7fb2ac5efd8ffa8713fea0c5fd218d'

* commit '9806b9ab5c7fb2ac5efd8ffa8713fea0c5fd218d':
  Revert "Don't use expressions with side effects in macro parameters"

This commit is a noop.

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit 'f79d847400d218cfd0b95f10358fe6e65ec3c9c4'
James Almer [Thu, 16 Mar 2017 00:20:44 +0000 (21:20 -0300)]
Merge commit 'f79d847400d218cfd0b95f10358fe6e65ec3c9c4'

* commit 'f79d847400d218cfd0b95f10358fe6e65ec3c9c4':
  intreadwrite: Use the __unaligned keyword on MSVC for ARM and x86_64

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '230b1c070baa3b6d4bd590426a365b843d60ff50'
James Almer [Thu, 16 Mar 2017 00:17:37 +0000 (21:17 -0300)]
Merge commit '230b1c070baa3b6d4bd590426a365b843d60ff50'

* commit '230b1c070baa3b6d4bd590426a365b843d60ff50':
  intreadwrite: Add intermediate variables in the byteswise AV_W*() macros

Mostly a noop. Merged for cosmetic purposes.
See d83ff76ca0e1ec905ca2d5b27bd0973991eadbd9

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '014773b66bdff4de24f384066d1a85d2a5bb6774'
James Almer [Thu, 16 Mar 2017 00:14:51 +0000 (21:14 -0300)]
Merge commit '014773b66bdff4de24f384066d1a85d2a5bb6774'

* commit '014773b66bdff4de24f384066d1a85d2a5bb6774':
  libavutil: Use an intermediate variable in AV_COPY*U

This commit is a noop. It would be reverted in a future merge either
way.

Merged-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '25bacd0a0c32ae682e6f411b1ac9020aeaabca72'
James Almer [Thu, 16 Mar 2017 00:13:54 +0000 (21:13 -0300)]
Merge commit '25bacd0a0c32ae682e6f411b1ac9020aeaabca72'

* commit '25bacd0a0c32ae682e6f411b1ac9020aeaabca72':
  Don't use expressions with side effects in macro parameters

This commit is a noop. It would be reverted in a future merge either
way.

Merged-by: James Almer <jamrial@gmail.com>
2 years agoavcodec/tiff: Check palette shift
Michael Niedermayer [Tue, 14 Mar 2017 00:34:14 +0000 (01:34 +0100)]
avcodec/tiff: Check palette shift

Fixes multiple  runtime error: shift exponent 792 is too large for 32-bit type 'unsigned int'

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/wavpack: Fix multiple integer overflows
Michael Niedermayer [Tue, 14 Mar 2017 00:17:53 +0000 (01:17 +0100)]
avcodec/wavpack: Fix multiple integer overflows

Fixes: 839/clusterfuzz-testcase-4871084446842880

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/simple_idct_template: Fix several integer overflows
Michael Niedermayer [Mon, 13 Mar 2017 01:25:42 +0000 (02:25 +0100)]
avcodec/simple_idct_template: Fix several integer overflows

Benchmarks with START_TIMER indicate that the code is faster with unsigned, (that is
with the patch), there was quite some fluctuation in the numbers so this may be just
random

Fixes: 811/clusterfuzz-testcase-6465493076541440

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoconfigure: libnpp is always nonfree, even with LGPL
Ricardo Constantino [Wed, 15 Mar 2017 22:47:58 +0000 (22:47 +0000)]
configure: libnpp is always nonfree, even with LGPL

libnpp was erroneously grouped up with libfdk-aac and openssl to check
if --enable-nonfree wasn't passed only with --enable-gpl in
9f28db47accb31bfec40a56dd2dc19ffd366a6be. The latter two are compatible
with LGPL, libnpp is not.

Signed-off-by: James Almer <jamrial@gmail.com>
2 years agoMerge commit '7ebdffc353f3f0827864e8e3461fdc00cc243b14'
Clément Bœsch [Wed, 15 Mar 2017 22:26:10 +0000 (23:26 +0100)]
Merge commit '7ebdffc353f3f0827864e8e3461fdc00cc243b14'

* commit '7ebdffc353f3f0827864e8e3461fdc00cc243b14':
  dxv: Check to make sure we don't overrun buffers on corrupt inputs

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'e328178da90f44690e0076f4dbfd16da9175f441'
Clément Bœsch [Wed, 15 Mar 2017 22:22:50 +0000 (23:22 +0100)]
Merge commit 'e328178da90f44690e0076f4dbfd16da9175f441'

* commit 'e328178da90f44690e0076f4dbfd16da9175f441':
  qsvdec: only access hwaccel_context is the pixel format is QSV

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'ed1cd81076434b76f37576d4d806973476a8e96c'
Clément Bœsch [Wed, 15 Mar 2017 22:16:23 +0000 (23:16 +0100)]
Merge commit 'ed1cd81076434b76f37576d4d806973476a8e96c'

* commit 'ed1cd81076434b76f37576d4d806973476a8e96c':
  flac demuxer: improve probing

Suggested commit very closely matches our code, except with regards to
AVPROBE_SCORE_EXTENSION. The code layout is mostly merged but preserves
our behaviour.

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '5ebef79abecc3ffcc4ab0d46e203d13b068107c9'
Clément Bœsch [Wed, 15 Mar 2017 22:00:50 +0000 (23:00 +0100)]
Merge commit '5ebef79abecc3ffcc4ab0d46e203d13b068107c9'

* commit '5ebef79abecc3ffcc4ab0d46e203d13b068107c9':
  Fix instances of broken indentation found by gcc 6

Noop, see 21d3f0c026089c44a2

Merged-by: Clément Bœsch <u@pkh.me>
2 years agodoc: remove remaining legacy x11grab references
Clément Bœsch [Wed, 15 Mar 2017 21:23:00 +0000 (22:23 +0100)]
doc: remove remaining legacy x11grab references

2 years agoMerge commit '5ed4644d6de7f6112431dc2d9a5cfe9a0a75a688'
Clément Bœsch [Wed, 15 Mar 2017 21:17:29 +0000 (22:17 +0100)]
Merge commit '5ed4644d6de7f6112431dc2d9a5cfe9a0a75a688'

* commit '5ed4644d6de7f6112431dc2d9a5cfe9a0a75a688':
  x11grab: Rename internal component to "xcbgrab"

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '4fef648d10bf3bcfd4b8fa5755c1128966a2427c'
Clément Bœsch [Wed, 15 Mar 2017 21:07:47 +0000 (22:07 +0100)]
Merge commit '4fef648d10bf3bcfd4b8fa5755c1128966a2427c'

* commit '4fef648d10bf3bcfd4b8fa5755c1128966a2427c':
  Remove the legacy X11 screen grabber

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '8495d84f0101464b15517860db33e8605586d87e'
Clément Bœsch [Wed, 15 Mar 2017 20:58:13 +0000 (21:58 +0100)]
Merge commit '8495d84f0101464b15517860db33e8605586d87e'

* commit '8495d84f0101464b15517860db33e8605586d87e':
  ac3dec: Add some inline hints

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '3db51bf671defd47f2ec5ab67b11fb7730fb5e5a'
Clément Bœsch [Wed, 15 Mar 2017 20:57:57 +0000 (21:57 +0100)]
Merge commit '3db51bf671defd47f2ec5ab67b11fb7730fb5e5a'

* commit '3db51bf671defd47f2ec5ab67b11fb7730fb5e5a':
  ac3dec: Simplify skipping

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'f0ccc65bc9ab9ddf1366066395564c71bcc825ee'
Clément Bœsch [Wed, 15 Mar 2017 20:56:47 +0000 (21:56 +0100)]
Merge commit 'f0ccc65bc9ab9ddf1366066395564c71bcc825ee'

* commit 'f0ccc65bc9ab9ddf1366066395564c71bcc825ee':
  ac3dec: Split coupling-specific code from decode_audio_block()

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'a5ebe5d1217942238c641c83b24ef1106e53934a'
Clément Bœsch [Wed, 15 Mar 2017 20:43:59 +0000 (21:43 +0100)]
Merge commit 'a5ebe5d1217942238c641c83b24ef1106e53934a'

* commit 'a5ebe5d1217942238c641c83b24ef1106e53934a':
  ac3dec: Split spx-specific code from decode_audio_block()

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit '2ac00d2d1d51047c6ce69d5fbe1a08392d142658'
Clément Bœsch [Wed, 15 Mar 2017 20:29:56 +0000 (21:29 +0100)]
Merge commit '2ac00d2d1d51047c6ce69d5fbe1a08392d142658'

* commit '2ac00d2d1d51047c6ce69d5fbe1a08392d142658':
  mov: Validate the ID number

This commit is a noop as the modified check is not present in FFmpeg.
See d30870cc730337b7017cc194d696f68ee48f7f1d.

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'a115eb9e750543f1d8bf951414d291069bf396c2'
Clément Bœsch [Wed, 15 Mar 2017 20:23:30 +0000 (21:23 +0100)]
Merge commit 'a115eb9e750543f1d8bf951414d291069bf396c2'

* commit 'a115eb9e750543f1d8bf951414d291069bf396c2':
  mimic: do not release the newly obsolete reference at the end of decoding

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoMerge commit 'ae90119c6701fa09ff747cca35238e36b2d2ab2f'
Clément Bœsch [Wed, 15 Mar 2017 20:09:06 +0000 (21:09 +0100)]
Merge commit 'ae90119c6701fa09ff747cca35238e36b2d2ab2f'

* commit 'ae90119c6701fa09ff747cca35238e36b2d2ab2f':
  configure: Simplify license incompatibility check

An extra GPLV3 list is added for libsmbclient as having it in both GPL
and VERSION3 lists would cause a duplicate in the final config list.

Also, for consistency, libnpp is treated the same as the other nonfree
component (libfdk_aac and openssl).

Merged-by: Clément Bœsch <u@pkh.me>
2 years agoavcodec/videotoolboxenc: add rc_max_bitrate control into videotoolbox
Steven Liu [Tue, 14 Mar 2017 14:53:43 +0000 (22:53 +0800)]
avcodec/videotoolboxenc: add rc_max_bitrate control into videotoolbox

add kVTCompressionPropertyKey_DataRateLimits support by rc_max_bitrate

Reviewed-by: Rick Kern <kernrj@gmail.com>
Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2 years agoMerge commit 'e46a6fb7732a7caef97a916a4f765ec0f779d195'
Clément Bœsch [Wed, 15 Mar 2017 13:25:46 +0000 (14:25 +0100)]
Merge commit 'e46a6fb7732a7caef97a916a4f765ec0f779d195'

* commit 'e46a6fb7732a7caef97a916a4f765ec0f779d195':
  avconv: Check that muxing_queue exists before reading from it

Mostly noop. This was fixed in FFmpeg in 7f7c494a3.

The merge makes the cosmetics match but does not include the weird
av_log().

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit '100fb0ddfda958da70f98feac81f924c02483789'
Clément Bœsch [Wed, 15 Mar 2017 11:49:03 +0000 (12:49 +0100)]
Merge commit '100fb0ddfda958da70f98feac81f924c02483789'

* commit '100fb0ddfda958da70f98feac81f924c02483789':
  configure: Allow detecting and using LLVM lld-link as linker for windows

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit '79fb0692992c74214c6cf8e81350fc93eeffc5ec'
Clément Bœsch [Wed, 15 Mar 2017 11:44:35 +0000 (12:44 +0100)]
Merge commit '79fb0692992c74214c6cf8e81350fc93eeffc5ec'

* commit '79fb0692992c74214c6cf8e81350fc93eeffc5ec':
  configure: Move defines for controlling MSVCRT headers to the CRT detection section

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit '56af0bc10f49654b5b5f3efe82c69a13bf15fc8b'
Clément Bœsch [Wed, 15 Mar 2017 11:39:34 +0000 (12:39 +0100)]
Merge commit '56af0bc10f49654b5b5f3efe82c69a13bf15fc8b'

* commit '56af0bc10f49654b5b5f3efe82c69a13bf15fc8b':
  configure: Check for strtoll and redirect to _strtoi64 in the msvcrt block

Also includes _strtoui64 in the check.

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit '48b80f8393d418ad35d73f5a36f5011de1928f3c'
Clément Bœsch [Wed, 15 Mar 2017 11:34:51 +0000 (12:34 +0100)]
Merge commit '48b80f8393d418ad35d73f5a36f5011de1928f3c'

* commit '48b80f8393d418ad35d73f5a36f5011de1928f3c':
  hpeldsp: Explain why put_no_rnd_pixels_tab is larger than necessary

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit '40ad05bab206c932a32171d45581080c914b06ec'
Clément Bœsch [Wed, 15 Mar 2017 11:32:15 +0000 (12:32 +0100)]
Merge commit '40ad05bab206c932a32171d45581080c914b06ec'

* commit '40ad05bab206c932a32171d45581080c914b06ec':
  checkasm: Cast unsigned to signed

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agoMerge commit 'b183abfb5b6366b177cf44f244c66156257a6fd6'
Clément Bœsch [Wed, 15 Mar 2017 11:23:18 +0000 (12:23 +0100)]
Merge commit 'b183abfb5b6366b177cf44f244c66156257a6fd6'

* commit 'b183abfb5b6366b177cf44f244c66156257a6fd6':
  vpx: Support color range

Decoder chunk not merged as the framework automatically copies avctx
color range to the frame color range. And we already set the avctx field
since cbcc88c039.

Merged-by: Clément Bœsch <cboesch@gopro.com>
2 years agolavc/h264dec: use OFFSET macro
Matthieu Bouron [Mon, 6 Feb 2017 16:14:57 +0000 (17:14 +0100)]
lavc/h264dec: use OFFSET macro

2 years agoavformat/hlsenc: fix duration wrong when no pkt duration
Steven Liu [Tue, 14 Mar 2017 23:37:11 +0000 (07:37 +0800)]
avformat/hlsenc: fix duration wrong when no pkt duration

when cannot get pkt duration, hlsenc segments duration will
be set to 0, this patch can fix it.

Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2 years agoffmpeg, ffprobe: don't "merge" side data into packet data by default
wm4 [Thu, 9 Mar 2017 14:43:30 +0000 (15:43 +0100)]
ffmpeg, ffprobe: don't "merge" side data into packet data by default

Preparation for potentially disabling merged side data by default in the
libs. Do this in particular because it affects fate tests.

The changed tests either reflect added packet side data, or the changed
packet size due to merged side data removal reducing the packet size.

2 years agolavf/avio: Be more explicit in logging white/black list matches
Alexander Strasser [Sat, 11 Mar 2017 14:43:39 +0000 (15:43 +0100)]
lavf/avio: Be more explicit in logging white/black list matches

The current form of the messages indicating matches in the white
or black lists seems to be a bit too much relying on context.

Make the messages more explicit.

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2 years agolavf/avio: Remove unnecessary escaping of ' in string literals
Alexander Strasser [Sat, 11 Mar 2017 11:02:32 +0000 (12:02 +0100)]
lavf/avio: Remove unnecessary escaping of ' in string literals

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
2 years agoavcodec/mpegaudiodec_template: Make l3_unscale() work with e=0
Michael Niedermayer [Mon, 13 Mar 2017 19:45:09 +0000 (20:45 +0100)]
avcodec/mpegaudiodec_template: Make l3_unscale() work with e=0

Fixes undefined behavior
Fixes: 830/clusterfuzz-testcase-6253175327686656

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/tiff: Check for multiple geo key directories
Michael Niedermayer [Mon, 13 Mar 2017 19:45:08 +0000 (20:45 +0100)]
avcodec/tiff: Check for multiple geo key directories

Fixes memleak
Fixes: 826/clusterfuzz-testcase-5316921379520512

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/pictordec: Fix runtime error: left shift of 805306368 by 2 places cannot...
Michael Niedermayer [Mon, 13 Mar 2017 19:45:07 +0000 (20:45 +0100)]
avcodec/pictordec: Fix runtime error: left shift of 805306368 by 2 places cannot be represented in type 'int'

Fixes: 823/clusterfuzz-testcase-6727060074528768

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agodoc/filters: Add colourspace values for colormatrix filter
Katherine Nagels [Sun, 12 Mar 2017 22:57:11 +0000 (11:57 +1300)]
doc/filters: Add colourspace values for colormatrix filter

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Kieran Kunhya <kierank@obe.tv>
2 years agoavformat/flvenc: flx flvflags no_metadata bug
Steven Liu [Tue, 14 Mar 2017 10:11:20 +0000 (18:11 +0800)]
avformat/flvenc: flx flvflags no_metadata bug

When use flvflags no_metadata , the FLV header will be cover by write tailer
This commit fix the bug

Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2 years agoavformat/hlsenc: fix ticket 6231
Steven Liu [Tue, 14 Mar 2017 02:16:00 +0000 (10:16 +0800)]
avformat/hlsenc: fix ticket 6231

check if the hls_flags is byterange_mode and check if should close fd

Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2 years agoavcodec/wavpack: Fix runtime error: shift exponent 32 is too large for 32-bit type...
Michael Niedermayer [Mon, 13 Mar 2017 01:51:15 +0000 (02:51 +0100)]
avcodec/wavpack: Fix runtime error: shift exponent 32 is too large for 32-bit type 'int'

Fixes: 822/clusterfuzz-testcase-4873433189974016

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/targa: Skip hflip on blank images
Michael Niedermayer [Sun, 12 Mar 2017 23:18:04 +0000 (00:18 +0100)]
avcodec/targa: Skip hflip on blank images

Fixes: timeout with 810/clusterfuzz-testcase-5249282825256960

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/wavpack: Fix runtime error: shift exponent 137 is too large for 32-bit type...
Michael Niedermayer [Sun, 12 Mar 2017 22:45:54 +0000 (23:45 +0100)]
avcodec/wavpack: Fix runtime error: shift exponent 137 is too large for 32-bit type 'int'

Fixes: 808/clusterfuzz-testcase-4715513349406720

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/h264_direct: Fix runtime error: signed integer overflow: 2147483647 - -14133...
Michael Niedermayer [Fri, 10 Mar 2017 14:24:52 +0000 (15:24 +0100)]
avcodec/h264_direct: Fix runtime error: signed integer overflow: 2147483647 - -14133 cannot be represented in type 'int'

Fixes: 755/clusterfuzz-testcase-5369072516595712

See: [FFmpeg-devel] [PATCH 1/2] avcodec/h264_direct: Fix runtime error: signed integer overflow: 2147483647 - -14133 cannot be represented in type 'int'

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/xpmdec: there are XPM files with dos line endings
Paul B Mahol [Sun, 12 Mar 2017 22:13:26 +0000 (23:13 +0100)]
avcodec/xpmdec: there are XPM files with dos line endings

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavfilter/vf_lut3d: actually skip lines when encountering DOMAIN_ string
Paul B Mahol [Sun, 12 Mar 2017 17:59:05 +0000 (18:59 +0100)]
avfilter/vf_lut3d: actually skip lines when encountering DOMAIN_ string

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavformat/hlsenc: second_levels flags process function extract
Steven Liu [Mon, 13 Mar 2017 03:58:34 +0000 (11:58 +0800)]
avformat/hlsenc: second_levels flags process function extract

the SECOND_LEVEL* flags process and name is too long
extract all of them output to funtions, make code clear

Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
2 years agoavcodec/vp6: clear dimensions on failed resolution change in vp6_parse_header()
Michael Niedermayer [Sun, 12 Mar 2017 02:04:06 +0000 (03:04 +0100)]
avcodec/vp6: clear dimensions on failed resolution change in vp6_parse_header()

Fixes: 807/clusterfuzz-testcase-6470061042696192
Fixes null pointer dereference

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/rv34: Fix runtime error: signed integer overflow: 36880 * 66288 cannot be...
Michael Niedermayer [Sun, 12 Mar 2017 02:04:05 +0000 (03:04 +0100)]
avcodec/rv34: Fix runtime error: signed integer overflow: 36880 * 66288 cannot be represented in type 'int'

Fixes: 768/clusterfuzz-testcase-4807444305805312

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/mpeg12dec: Fix runtime error: left shift of negative value -1
Michael Niedermayer [Sun, 12 Mar 2017 02:04:04 +0000 (03:04 +0100)]
avcodec/mpeg12dec: Fix runtime error: left shift of negative value -1

Fixes: 764/clusterfuzz-testcase-6273034652483584

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2 years agoavcodec/xpmdec: avoid "magic" numbers in function hex_char_to_number()
Paul B Mahol [Sun, 12 Mar 2017 21:58:49 +0000 (22:58 +0100)]
avcodec/xpmdec: avoid "magic" numbers in function hex_char_to_number()

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: fix colors values which are different for X11
Paul B Mahol [Sun, 12 Mar 2017 21:56:58 +0000 (22:56 +0100)]
avcodec/xpmdec: fix colors values which are different for X11

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: do not allow number of colors to be higher than allocated
Paul B Mahol [Sun, 12 Mar 2017 21:51:00 +0000 (22:51 +0100)]
avcodec/xpmdec: do not allow number of colors to be higher than allocated

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: rename yet another function
Paul B Mahol [Sun, 12 Mar 2017 21:43:49 +0000 (22:43 +0100)]
avcodec/xpmdec: rename yet another function

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: rename convert to hex_char_to_number
Paul B Mahol [Sun, 12 Mar 2017 21:42:05 +0000 (22:42 +0100)]
avcodec/xpmdec: rename convert to hex_char_to_number

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: improve comment for one function and also fix 2 identation issues
Paul B Mahol [Sun, 12 Mar 2017 21:37:53 +0000 (22:37 +0100)]
avcodec/xpmdec: improve comment for one function and also fix 2 identation issues

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoswresample/swresample: do not reset tsf on swr_alloc_set_opts
Muhammad Faiz [Sat, 11 Mar 2017 17:24:21 +0000 (00:24 +0700)]
swresample/swresample: do not reset tsf on swr_alloc_set_opts

so tsf option in aresample will have effect
previously tsf/internal_sample_format had no effect

fate is updated
s32p previously used fltp internally
dblp previously used fltp/dblp internally

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2 years agovf_hwupload: Add missing return value check
Jun Zhao [Fri, 3 Mar 2017 01:25:53 +0000 (09:25 +0800)]
vf_hwupload: Add missing return value check

Add missing return value checks to suppress build warning and
remove noop ff_formats_unref() calling.

Note: most filters using ff_formats_ref() didn't have a suitable
error handling, it's a potential memory leak issue.

Signed-off-by: Jun Zhao <jun.zhao@intel.com>
Signed-off-by: Mark Thompson <sw@jkqxz.net>
2 years agotests/api-seek: fix memory leak on realloc() failure
James Almer [Sat, 11 Mar 2017 23:29:40 +0000 (20:29 -0300)]
tests/api-seek: fix memory leak on realloc() failure

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2 years agotest/api-seek: clean up properly on failure
James Almer [Sun, 12 Mar 2017 13:36:44 +0000 (10:36 -0300)]
test/api-seek: clean up properly on failure

Also propagate better error values.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2 years agotests/api-seek: make the crc array uint32_t
James Almer [Sat, 11 Mar 2017 23:24:53 +0000 (20:24 -0300)]
tests/api-seek: make the crc array uint32_t

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2 years agoavcodec/xpmdec: skip everything before signature
Paul B Mahol [Sun, 12 Mar 2017 14:07:02 +0000 (15:07 +0100)]
avcodec/xpmdec: skip everything before signature

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/codec_desc: add mime type for X-BitMap
Paul B Mahol [Sun, 12 Mar 2017 13:50:33 +0000 (14:50 +0100)]
avcodec/codec_desc: add mime type for X-BitMap

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/codec_desc: add mime type for X-PixMap
Paul B Mahol [Sun, 12 Mar 2017 13:49:26 +0000 (14:49 +0100)]
avcodec/codec_desc: add mime type for X-PixMap

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec/xpmdec: make convert function more picky about its input
Paul B Mahol [Sun, 12 Mar 2017 11:48:01 +0000 (12:48 +0100)]
avcodec/xpmdec: make convert function more picky about its input

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2 years agoavcodec: add XPM decoder and demuxer
Paras Chadha [Sat, 11 Mar 2017 21:01:23 +0000 (02:31 +0530)]
avcodec: add XPM decoder and demuxer

Signed-off-by: Paras Chadha <paraschadha18@gmail.com>
2 years agoMerge commit 'ad71d3276fef0ee7e791e62bbfe9c4e540047417'
Mark Thompson [Sun, 12 Mar 2017 16:55:32 +0000 (16:55 +0000)]
Merge commit 'ad71d3276fef0ee7e791e62bbfe9c4e540047417'

* commit 'ad71d3276fef0ee7e791e62bbfe9c4e540047417':
  lavfi: add a QSV deinterlacing filter

Minor fixup for lavfi differences.

Merged-by: Mark Thompson <sw@jkqxz.net>
2 years agoMerge commit '8e07c22e508b349d145b9f142aa3ee8b3ce1d3a4'
Mark Thompson [Sun, 12 Mar 2017 15:21:41 +0000 (15:21 +0000)]
Merge commit '8e07c22e508b349d145b9f142aa3ee8b3ce1d3a4'

* commit '8e07c22e508b349d145b9f142aa3ee8b3ce1d3a4':
  qsvenc: print warnings from encode/init

Merged-by: Mark Thompson <sw@jkqxz.net>
2 years agoMerge commit '0956fd460681e8ccbdae19f135f0d3970bf95c2f'
Mark Thompson [Sun, 12 Mar 2017 15:19:52 +0000 (15:19 +0000)]
Merge commit '0956fd460681e8ccbdae19f135f0d3970bf95c2f'

* commit '0956fd460681e8ccbdae19f135f0d3970bf95c2f':
  qsvenc: do not re-execute encoding on all positive status codes

Noop, see fb240a6276fa36fe120aadd67b4ca774e354f22b.

Merged-by: Mark Thompson <sw@jkqxz.net>
2 years agoMerge commit '95414eb2dc63a6f934275b4ed33dedd4369f2c49'
Mark Thompson [Sun, 12 Mar 2017 15:19:05 +0000 (15:19 +0000)]
Merge commit '95414eb2dc63a6f934275b4ed33dedd4369f2c49'

* commit '95414eb2dc63a6f934275b4ed33dedd4369f2c49':
  qsv: print more complete error messages

Merged-by: Mark Thompson <sw@jkqxz.net>