Reino17
078322f33c
Add support for LibOpenJPEG v2.2/git
...
Signed-off-by: Michael Bradshaw <mjbshaw@google.com >
2017-06-23 20:29:23 -07:00
Rostislav Pehlivanov
e1120b1c54
mdct15: add assembly optimizations for the 15-point FFT
...
c: 1802 decicycles in fft15,16774635 runs, 2581 skips
avx: 865 decicycles in fft15,16776378 runs, 838 skips
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com >
2017-06-23 23:45:37 +01:00
jerett
9f26d670e4
lavc/videotoolboxenc: fix open videotoolbox bug on iOS8.4
...
Checks for NULL before using object.
Signed-off-by: Rick Kern <kernrj@gmail.com >
2017-06-23 09:37:34 -04:00
jerett
82a8724df2
lavc/videotoolboxenc: fix loadVTEncSymbols crash when symbol not found
...
Signed-off-by: Rick Kern <kernrj@gmail.com >
2017-06-23 09:37:34 -04:00
Jun Zhao
ea1d07aed9
lavc/golomb: add value range comment for set_ue_golomb().
...
set_ue_golomb just support 2^16 - 2 at most, becase this function call
put_bits, and put_bits just support write up to 31 bits, when write 32
bit in put_bits, it's will overwrite the bit buffer, and the default
assert level is 0, the av_assert2(n <= 31 && value < (1U << n)) in
put_bits can not be trigger runtime.
Signed-off-by: Jun Zhao <jun.zhao@intel.com >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-23 13:03:20 +02:00
Michael Niedermayer
24e95f9d4d
avcodec/wavpack: Fix integer overflow
...
Fixes: runtime error: signed integer overflow: 227511904 + 1964113935 cannot be represented in type 'int'
Fixes: 2331/clusterfuzz-testcase-minimized-6182185830711296
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-23 03:03:04 +02:00
Michael Niedermayer
0c2ef4f6b4
avcodec/takdec: Fix integer overflow
...
Fixes: runtime error: signed integer overflow: 512 + 2147483146 cannot be represented in type 'int'
Fixes: 2314/clusterfuzz-testcase-minimized-4519333877252096
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-23 03:03:04 +02:00
Michael Niedermayer
27f80ab016
avcodec/tiff: Update pointer only when the result is used
...
Fixes: runtime error: signed integer overflow: 538976288 * 32 cannot be represented in type 'int'
Fixes: 2310/clusterfuzz-testcase-minimized-4534784887881728
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-23 03:03:04 +02:00
Rostislav Pehlivanov
7e98da9c4f
opus_celt: do not use double precision exp2
...
Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com >
2017-06-22 22:37:53 +01:00
Michael Niedermayer
6f1d2355a7
avcodec/cfhd: Check bpc before setting bpc in context
...
Fixes: runtime error: shift exponent 32 is too large for 32-bit type 'int'
Fixes: 2306/clusterfuzz-testcase-minimized-5002997392211968
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-22 01:54:40 +02:00
Michael Niedermayer
5a950f4e32
avcodec/cfhd: Fix undefined shift
...
Fixes: runtime error: left shift of negative value -1
Fixes: 2303/clusterfuzz-testcase-minimized-5529675273076736
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-22 01:54:40 +02:00
Diego Biurrun
fd502f4f5f
build: Generalize yasm/nasm-related variable names
...
None of them are specific to the YASM assembler.
(Cherry-picked from libav commit 39e208f4d4 )
Signed-off-by: James Almer <jamrial@gmail.com >
2017-06-21 17:00:29 -03:00
Ronald S. Bultje
e639d09199
mdec: stop preferring the simple IDCT.
...
This was added in e3e3c82555 , probably
as a workaround for the fact that the quant table was not permutated
and the IDCT coefficients are, meaning that you'd only get correct
reconstruction if the IDCT permutation was an identity matrix, which
happens to be the case when you use the simple IDCT. The quant table
permutation bug was fixed in 42dd1434bf ,
meaning this workaround is no longer necessary.
In practical terms, before 42dd1434bf ,
the PSNR between decodes of the fate-mdec using simple (C) or simplemmx
IDCTs was 35. After 42dd1434bf , it's 90.
2017-06-21 09:01:32 -04:00
Ronald S. Bultje
42dd1434bf
mdec: use correctly permutated quant matrix for dequantization.
2017-06-21 08:59:22 -04:00
Memphiz
9e85c5d6a7
aarch64: vp9 16bpp: Fix assembling with Xcode 6.2 and older
...
Properly use the b.eq form instead of the nonstandard form (which
both gas and newer clang accept though), and expand the register
lists that used a range (which the Xcode 6.2 clang, based on clang
3.5 svn, didn't support).
Signed-off-by: Martin Storsjö <martin@martin.st >
2017-06-21 09:08:14 +03:00
Memphiz
998609ddb8
aarch64: vp9: Fix assembling with Xcode 6.2 and older
...
Properly use the b.eq/b.ge forms instead of the nonstandard forms
(which both gas and newer clang accept though), and expand the
register list that used a range (which the Xcode 6.2 clang, based
on clang 3.5 svn, didn't support).
This is cherrypicked from libav commit
a970f9de86 .
Signed-off-by: Martin Storsjö <martin@martin.st >
2017-06-21 09:08:13 +03:00
Michael Niedermayer
70a7df049c
avcodec/mpegvideo: Use intra_scantable in dct_unquantize_h263_intra_c()
...
Reviewed-by: James Darnley <jdarnley@obe.tv >
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-21 02:25:23 +02:00
Michael Niedermayer
d7b3d5c3f2
avcodec/hevc_filter: Fix invalid shift
...
Fixes: runtime error: left shift of negative value -1
Fixes: 2299/clusterfuzz-testcase-minimized-4843509351710720
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-21 02:25:23 +02:00
Michael Niedermayer
fdfbcbdd14
avcodec/hevcdec: Check beta and tc offset in hls_slice_header()
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-21 02:25:23 +02:00
Michael Niedermayer
5443c4bdf4
avcodec/mpeg4videodec: Fix overflow in virtual_ref computation
...
Fixes: runtime error: signed integer overflow: 262144 * -16120 cannot be represented in type 'int'
Fixes: 2292/clusterfuzz-testcase-minimized-6156080415506432
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-21 02:25:23 +02:00
Michael Niedermayer
e95fcfe8fb
avcodec/lpc: signed integer overflow in compute_lpc_coefs() (aacdec_fixed)
...
Fixes: runtime error: signed integer overflow: -1575818955 + -915383657 cannot be represented in type 'int'
Fixes: 2224/clusterfuzz-testcase-minimized-6208559949807616
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-21 02:25:23 +02:00
John Rummell
966a0a814d
avcodec/decode: Update decode_simple_internal() to get the side data correctly.
...
Use avci->last_pkt_props to get the side data. Using |pkt| doesn't work
when FF_API_MERGE_SD is set, as the compressed side data is expanded into
|tmp|, leaving the original |pkt| unchanged.
Signed-off-by: James Almer <jamrial@gmail.com >
2017-06-20 17:14:17 -03:00
James Darnley
8221c71703
avcodec/x86: allow future 8-bit simple idct to use slightly different coefficients
2017-06-20 16:12:25 +02:00
James Darnley
9d11fedd11
avcodec/mdec: override IDCT choice before initing DSP structs
2017-06-20 13:59:51 +02:00
James Darnley
d2597fb0c1
avcodec/x86: modify simple_idct10 macros to add an action paramter
2017-06-20 13:35:01 +02:00
James Darnley
8781330d80
avcodec/x86: cleanup simple_idct10
...
Use named arguments for the functions so we can remove a define. The
stride/linesize argument is now ptrdiff_t type so we no longer need to
sign extend the register.
2017-06-20 13:34:38 +02:00
James Darnley
e3db94302c
avcodec/x86/mpegenc: support transpose permuation type
2017-06-20 12:12:13 +02:00
James Darnley
fa30a0a548
avcodec/x86/mpegenc: check IDCT permutation type is a valid value
2017-06-20 12:12:13 +02:00
Michael Niedermayer
ae6f6d4e34
avcodec/x86/mpegvideo: Use intra scantable in dct_unquantize_h263_intra_mmx()
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-20 00:07:51 +02:00
Anton Mitrofanov
cf231b68da
avcodec/h264: Fix mix of lossless and lossy MBs decoding
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
2017-06-19 14:33:40 -04:00
Anton Mitrofanov
06dda70f1e
avcodec/h264_mb: Fix 8x8dct in lossless for new versions of x264
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
2017-06-19 14:33:39 -04:00
Anton Mitrofanov
840b41b2a6
avcodec/h264_cabac: Fix CABAC+8x8dct in 4:4:4
...
Use the correct ctxIdxInc calculation for coded_block_flag.
Keep old behavior for old versions of x264 for backward compatibility.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com >
2017-06-19 14:33:39 -04:00
Michael Niedermayer
5f89747086
avcodec/wavpack: Fix undefined integer negation
...
Fixes: runtime error: negation of -2147483648 cannot be represented in type 'int'; cast to an unsigned type to negate this value to itself
Fixes: 2291/clusterfuzz-testcase-minimized-5538453481586688
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-19 17:54:40 +02:00
Michael Niedermayer
cf7edbd6c5
avcodec/aacdec_fixed: Check s for being too small
...
Fixes: runtime error: shift exponent -8 is negative
Fixes: 2286/clusterfuzz-testcase-minimized-5711764169687040
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-19 17:54:40 +02:00
Michael Niedermayer
f670c13f13
avcodec: Rename ff_mpv_decode_mb() to ff_mpv_reconstruct_mb
...
The new name more accuratly describes what the function does
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-19 17:54:40 +02:00
James Almer
8bb59e6742
x86/aacpsdsp: add ff_ps_hybrid_analysis_ileave_sse
...
About 2x faster than the c version.
2017-06-18 22:34:22 -03:00
James Almer
e229df9478
x86/aacpsdsp: add ff_ps_hybrid_synthesis_deint_{sse,sse4}
...
About 2x faster than the c version.
2017-06-18 22:33:27 -03:00
Michael Niedermayer
14b834c45a
avcodec/htmlsubtitles: Factor open brace handling into its own function
...
Suggested-by: wm4
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-18 14:50:35 +02:00
Michael Niedermayer
4132218b87
avcodec/htmlsubtitles: Replace very slow redundant sscanf() calls by cleaner and faster code
...
This reduces the worst case from O(n²) to O(n) time
Fixes Timeout
Fixes: 2127/clusterfuzz-testcase-minimized-6595787859427328
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-18 14:50:30 +02:00
Michael Niedermayer
27c2006805
avcodec/takdec: Fixes: integer overflow in AV_SAMPLE_FMT_U8P output
...
Fixes: runtime error: signed integer overflow: 2147483543 + 128 cannot be represented in type 'int'
Fixes: 2234/clusterfuzz-testcase-minimized-6266896041115648
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-18 14:38:41 +02:00
Michael Niedermayer
9a6503f496
avcodec/iff: Cleanup on init failure
...
Fixes: memleak
Fixes: 2272/clusterfuzz-testcase-minimized-5059103858622464
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-18 14:05:57 +02:00
Michael Niedermayer
c746f92a8e
avcodec/jpeg2000dsp: Reorder operations in ict_int() to avoid 2 integer overflows
...
Fixes: runtime error: signed integer overflow: 58065 * 51981 cannot be represented in type 'int'
Fixes: 2271/clusterfuzz-testcase-minimized-5778297776504832
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-17 22:36:54 +02:00
Michael Niedermayer
c94326c1fc
avcodec/hevcpred_template: Fix left shift of negative value
...
Fixes: runtime error: left shift of negative value -1
Fixes: 2250/clusterfuzz-testcase-minimized-5693382112313344
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-17 22:36:54 +02:00
Michael Niedermayer
1edbf5e20c
avcodec/hevcdec: Fix signed integer overflow in decode_lt_rps()
...
Fixes: runtime error: signed integer overflow: 2147483647 + 6 cannot be represented in type 'int'
Fixes: 2263/clusterfuzz-testcase-minimized-4800359627227136
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-17 00:34:48 +02:00
Michael Niedermayer
9b65dbf734
avcodec/gdv: Fix undefined shift
...
Fixes: runtime error: left shift of 255 by 24 places cannot be represented in type 'int'
Fixes: 2249/clusterfuzz-testcase-minimized-5388542379294720
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-16 23:32:28 +02:00
Michael Niedermayer
dfb61ea263
avcodec/jpeg2000dec: Check nonzerobits more completely
...
Fixes: runtime error: shift exponent 36 is too large for 32-bit type 'int'
Fixes: 2239/clusterfuzz-testcase-minimized-5639766592716800
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-16 20:32:39 +02:00
Michael Niedermayer
16d6cc2168
avcodec/wavpack: Change wp_log2() to unsigned
...
Fixes: runtime error: signed integer overflow: 2143315325 + 4186162 cannot be represented in type 'int'
Fixes: 2134/clusterfuzz-testcase-minimized-4619258405322752
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-16 20:32:39 +02:00
Michael Niedermayer
e77ddd31a8
avcodec/shorten: Sanity check maxnlpc
...
Fixes OOM
Fixes: 2131/clusterfuzz-testcase-minimized-4718045157130240
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc >
2017-06-16 20:32:39 +02:00
James Almer
623d217ed1
avcodec/aacps: move checks for valid length outside the stereo_interpolate dsp function
...
Signed-off-by: James Almer <jamrial@gmail.com >
2017-06-15 23:49:40 -03:00
James Almer
b3446862bf
x86/vorbisdsp: optimize ff_vorbis_inverse_coupling_sse
...
About 7% faster.
2017-06-15 23:20:05 -03:00