1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-02 03:06:28 +02:00
Commit Graph

84373 Commits

Author SHA1 Message Date
James Almer
824d4062a1 compat/atomics/gcc: use __typeof__ instead of typeof
The typeof keyword is apparently not available when using the -std=c99 option.

Fixes the use of C11 atomic functions with old GCC.

Reviewed-by: Muhammad Faiz <mfcc64@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2017-03-18 12:13:46 -03:00
Rostislav Pehlivanov
3796fb2692 lavfi: deprecate AVFilterGraph->resample_lavr_opts
Not used by anything at all since we don't auto insert lavr filters.

Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
2017-03-18 07:37:35 +00:00
Muhammad Faiz
c52638cca2 swresample/swresample: do not use s32p internally by default when resampling
use fltp when doing s32 -> s32 resampling
because s32p has no simd optimization

benchmark:
old 17.913s
new  7.584s (use fma3)

Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2017-03-18 13:57:03 +07:00
Carl Eugen Hoyos
9e6b269fea lavc/avcodec: Constify AVBitStreamFilter* in AVBitStreamFilterContext struct.
Fixes a gcc warning:
libavcodec/bitstream_filter.c:71:20: warning: assignment discards 'const' qualifier from pointer target type
2017-03-17 23:46:47 +01:00
Vittorio Giovara
95a72aed76 mov: Drop extra format specifier in error message 2017-03-17 15:30:11 -04:00
Vittorio Giovara
f20bcec4c2 spherical: Change types of bounding and pad to uint32_t
These values are defined to be 32bit in the specification,
so it makes more sense to store them as fixed width.

Based on a patch by Micahel Niedermayer <michael@niedermayer.cc>.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2017-03-17 13:12:25 -04:00
Vittorio Giovara
21a8e751ad fate: Do not report side data size
This field is of little value, and interferes with testing side data,
since sizes can be different on multiple architectures.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2017-03-17 13:12:25 -04:00
Matthieu Bouron
e2adbcbd97 Merge commit '0638b99cdba52554691fc668d9e477bc184c7a33'
* commit '0638b99cdba52554691fc668d9e477bc184c7a33':
aiff: Skip padding byte for odd-sized chunks

Also removes to odd-size checks from get_aiff_header and get_meta to use
the generic path introduced by the original commit.

Merged-by: Matthieu Bouron <matthieu.bouron@gmail.com>
2017-03-17 13:31:03 +01:00
Tobias Rapp
205b8fd078 avcodec: estimate output bitrate for uncompressed video codecs
Allows to get a more realistic total bitrate (and estimated file size)
in avi_write_header. Previously a static default value of 200k was
assumed.

Adds an internal helper function for bitrate guessing.

Signed-off-by: Tobias Rapp <t.rapp@noa-archive.com>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
2017-03-17 11:55:16 +01:00
Anton Khirnov
8db301dead ffmpeg: set the encoding framerate when the output is CFR
(cherry picked from Libav commit d10102d23c)

Signed-off-by: Tobias Rapp <t.rapp@noa-archive.com>
2017-03-17 11:54:38 +01:00
Konda Raju
2db5ab73d4 avcodec/nvenc: allow different const-qps for I, P and B frames
Signed-off-by: Timo Rothenpieler <timo@rothenpieler.org>
2017-03-17 10:42:55 +01:00
Muhammad Faiz
3ba7b47d5c 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 01ebb57c03

Found-by: wm4 <nfxjfg@googlemail.com>
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2017-03-17 09:59:44 +07:00
wm4
b4b8ca24f6 avcodec: fix uninitialized variable read
This cna happen if the user tries to call the new decode API for
subtitles.

Fixes CID 1402071.
2017-03-17 00:29:03 +01:00
Carl Eugen Hoyos
1cd58e9154 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
2017-03-16 22:18:12 +01:00
Clément Bœsch
d006a075b8 Merge commit '0df4801105d84883071b0978cb3afc7cd5184ce8'
* commit '0df4801105d84883071b0978cb3afc7cd5184ce8':
  vp9: make mv bounds 32bit.

This commit is a noop, see 024fac5cd4

Merged-by: Clément Bœsch <u@pkh.me>
2017-03-16 21:44:15 +01:00
Clément Bœsch
5e4a572699 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>
2017-03-16 21:42:45 +01:00
Carl Eugen Hoyos
5dd7ea9f56 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]
2017-03-16 21:14:34 +01:00
Carl Eugen Hoyos
0d34dbc272 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]
2017-03-16 21:09:41 +01:00
Lou Logan
396be0da59 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>
2017-03-16 12:01:15 -08:00
wang-bin
b573e3f484 configure: clang -Oz for small size build to reduce size further 2017-03-16 20:58:52 +01:00
Lou Logan
e7282674a5 lavf/mpegtsenc: clarify pcr_period unit of measurement
pcr_period is in milliseconds.

Signed-off-by: Lou Logan <lou@lrcd.com>
2017-03-16 11:35:41 -08:00
Clément Bœsch
8286c359ad 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>
2017-03-16 20:25:39 +01:00
Clément Bœsch
a4f5e79f7c 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>
2017-03-16 20:10:47 +01:00
Muhammad Faiz
1f7eb216b0 swresample/options: enable linear_interp and exact_rational by default
better quality without speedloss

Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2017-03-17 00:08:03 +07:00
Michael Niedermayer
a3a4082599 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>
2017-03-16 16:16:05 +01:00
Michael Niedermayer
2898bc522d 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>
2017-03-16 16:16:05 +01:00
Alexis Ballier
21bed3c981 fate: Add vf_framerate test.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-03-16 16:16:05 +01:00
Alexis Ballier
bbc8f3d20e lavf/vf_framerate: Fix frame leak when increasing framerate.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-03-16 16:16:05 +01:00
Matthieu Bouron
0c6105dde0 lavc/tests/dct/aarch64: add ff_simple_idct_neon test 2017-03-16 12:00:41 +01:00
Matthieu Bouron
4c8e528d19 lavc/aarch64: add ff_simple_idct{,_add,_put}_neon functions 2017-03-16 12:00:41 +01:00
Rostislav Pehlivanov
911417f0b3 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>
2017-03-16 06:58:50 +00:00
James Almer
6c4665deb4 Merge commit '89aebc5bcc6e23a0a79c3f51c3a55c3571692ba0'
* commit '89aebc5bcc6e23a0a79c3f51c3a55c3571692ba0':
  lavc: align the linesize to 32 when AVX is enabled

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 22:16:53 -03:00
James Almer
b5122b040f Merge commit '63ac8e2d93080b74f6be32c7c3c1a1e44aacf34e'
* commit '63ac8e2d93080b74f6be32c7c3c1a1e44aacf34e':
  lavu: add LOCAL_ALIGNED_32

This commit is a noop, see 25d5ea6d5a

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 22:13:41 -03:00
James Almer
e632fe9bab Merge commit '3c504bc3599f00bfc5923adc114beef34bce11d0'
* commit '3c504bc3599f00bfc5923adc114beef34bce11d0':
  x86: deduplicate some constants

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 22:07:28 -03:00
James Almer
65ff562c3b Merge commit 'd3e4d406b020b0464486318aceda08bd8f69ca41'
* commit 'd3e4d406b020b0464486318aceda08bd8f69ca41':
  h264dec: reset nb_slice_ctx_queued for hwaccel decoding

This commit is a noop, see 7448019890

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 21:41:29 -03:00
James Almer
67817468d3 Merge commit 'e5b019725f53b79159931d3a7317107cbbfd0860'
* commit 'e5b019725f53b79159931d3a7317107cbbfd0860':
  m4vdec: Check for non-startcode 00 00 00 sequences in probe

This commit is a noop, see 7c1835c52a

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 21:40:35 -03:00
James Almer
e298497f0c Merge commit '3ccec334b8502701e72ef13bed25913c3578022e'
* commit '3ccec334b8502701e72ef13bed25913c3578022e':
  sbrdsp: Move a misplaced #endif directive to the right spot

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 21:37:40 -03:00
James Almer
f073b2da84 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>
2017-03-15 21:35:36 -03:00
James Almer
8c0aacf0ec 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>
2017-03-15 21:33:59 -03:00
James Almer
86fb169df5 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>
2017-03-15 21:33:13 -03:00
James Almer
30fe4b8d4c Merge commit 'f79d847400d218cfd0b95f10358fe6e65ec3c9c4'
* commit 'f79d847400d218cfd0b95f10358fe6e65ec3c9c4':
  intreadwrite: Use the __unaligned keyword on MSVC for ARM and x86_64

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 21:20:44 -03:00
James Almer
916dff9cb1 Merge commit '230b1c070baa3b6d4bd590426a365b843d60ff50'
* commit '230b1c070baa3b6d4bd590426a365b843d60ff50':
  intreadwrite: Add intermediate variables in the byteswise AV_W*() macros

Mostly a noop. Merged for cosmetic purposes.
See d83ff76ca0

Merged-by: James Almer <jamrial@gmail.com>
2017-03-15 21:17:37 -03:00
James Almer
4708f97890 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>
2017-03-15 21:14:51 -03:00
James Almer
eedb44a605 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>
2017-03-15 21:13:54 -03:00
Michael Niedermayer
cfa10e11be 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>
2017-03-16 01:04:35 +01:00
Michael Niedermayer
58e9c7f4a2 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>
2017-03-16 01:04:35 +01:00
Michael Niedermayer
45198477de 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>
2017-03-16 01:04:35 +01:00
Ricardo Constantino
b409d8d4a2 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
9f28db47ac. The latter two are compatible
with LGPL, libnpp is not.

Signed-off-by: James Almer <jamrial@gmail.com>
2017-03-15 19:53:12 -03:00
Clément Bœsch
d96f6df3a6 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>
2017-03-15 23:26:10 +01:00
Clément Bœsch
aabe525734 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>
2017-03-15 23:22:50 +01:00