Hendrik Leppkes
8d1267932c
x86/h264_weight: use appropriate register size for weight parameters
...
This fixes decoding corruption on 64 bit windows.
Signed-off-by: Martin Storsjö <martin@martin.st>
2016-09-30 12:18:22 +03:00
Diego Biurrun
2caa93b813
mpegaudiodsp: Change type of array stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
stride argument manually to be able to do pointer arithmetic.
2016-09-29 17:54:24 +02:00
Diego Biurrun
15b4f494fc
mss*: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-29 17:54:24 +02:00
Diego Biurrun
a339e919ca
ea: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-29 17:54:23 +02:00
Diego Biurrun
ba479f3daa
hevc: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-29 17:54:23 +02:00
Diego Biurrun
e4a94d8b36
h264chroma: Change type of stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
stride argument manually to be able to do pointer arithmetic.
2016-09-29 14:48:04 +02:00
Diego Biurrun
2ec9fa5ec6
idct: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-29 14:48:03 +02:00
Diego Biurrun
b2939a7527
blockdsp: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-29 14:48:03 +02:00
Diego Biurrun
3281d823cd
intrax8: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
Also rename all such parameters to "stride" for consistency.
2016-09-29 14:48:03 +02:00
Diego Biurrun
92c5755a18
hpeldsp: arm: Update comments left behind in 25841dfe80
2016-09-29 14:48:03 +02:00
Diego Biurrun
009adfd4fb
x86: fpel: Remove unnecessary sign extend
2016-09-29 14:47:41 +02:00
Mark Thompson
956a54129d
vaapi_h264: Set max_num_ref_frames to 1 when not using B frames
2016-09-28 22:54:11 +01:00
Mark Thompson
086e4b58b5
vaapi_encode: Sync to input surface rather than output
...
While outwardly bizarre, this change makes the behaviour consistent
with other VAAPI encoders which sync to the encode /input/ picture in
order to wait for /output/ from the encoder. It is not harmful on
i965 (because synchronisation already happens in vaRenderPicture(),
so it has no effect there), and it allows the encoder to work on
mesa/gallium which assumes this behaviour.
2016-09-28 22:54:11 +01:00
Mark Thompson
892bbbcdc1
vaapi_encode: Check packed header capabilities
...
This improves behaviour with drivers which do not support packed
headers, such as AMD VCE on mesa/gallium.
2016-09-28 22:54:11 +01:00
Mark Thompson
80a5d05108
vaapi_encode: Refactor initialisation
...
This allows better checking of capabilities and will make it easier
to add more functionality later.
It also commonises some duplicated code around rate control setup
and adds more comments explaining the internals.
2016-09-28 22:54:10 +01:00
Anton Khirnov
7bf8db4db6
tdsc: use the new decoding API
2016-09-28 10:01:52 +02:00
Anton Khirnov
de2ae3c1fa
lavc: add clobber tests for the new encoding/decoding API
2016-09-28 10:01:52 +02:00
Anton Khirnov
68811a41c7
mpegvideo_enc: use the new encoding API for b_strategy=2
2016-09-28 10:01:52 +02:00
Anton Khirnov
f03f78bc1c
mpegvideo_enc: handle encoding errors with b_strategy=2
2016-09-28 10:01:52 +02:00
Anton Khirnov
6f733ecab6
mpegvideo_enc: add const to the AVCodec instance
2016-09-28 10:01:52 +02:00
Yogender Gupta
70de2ea426
nvenc: Extended rate-control support as provided by SDK 7
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-09-24 19:03:10 +02:00
Yogender Gupta
358c887a9f
nvenc: Add support for high bitdepth
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-09-24 19:02:31 +02:00
Yogender Gupta
e02e2515b2
nvenc: Add some easier to understand presets that match x264 terminology
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2016-09-24 18:08:54 +02:00
Luca Barbato
352741b5ea
nvenc: Make sure that enum and array index match
...
And use a macro to reduce the boilerplate.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2016-09-24 18:08:54 +02:00
Anton Khirnov
12004a9a7f
audiodsp/x86: yasmify vector_clipf_sse
2016-09-22 09:47:52 +02:00
Anton Khirnov
683da86aab
audiodsp: reorder arguments for vector_clipf
...
This will make the x86 asm simpler.
ARM conversion by Martin Storsjö <martin@martin.st> and Janne Grunau
<janne-libav@jannau.net>
2016-09-22 09:47:52 +02:00
Anton Khirnov
bf58545aac
audiodsp: fix vector_clipf documentation
...
The x86 version processes 16 floats per iteration, so len must be a
multiple of 16.
2016-09-22 09:47:52 +02:00
Anton Khirnov
eea9857bfd
blockdsp: drop the high_bit_depth parameter
...
It has no effect, since the code is supposed to operate the same way for
any bit depth.
2016-09-22 09:47:52 +02:00
Anton Khirnov
75d98e30af
audiodsp/x86: clear the high bits of the order parameter on 64bit
...
Also change shl to add, since it can be faster on some CPUs.
CC: libav-stable@libav.org
2016-09-19 19:18:07 +02:00
Anton Khirnov
1d6c76e11f
audiodsp/x86: fix ff_vector_clip_int32_sse2
...
This version, which is the only one doing two processing cycles per loop
iteration, computes the load/store indices incorrectly for the second
cycle.
CC: libav-stable@libav.org
2016-09-19 19:18:07 +02:00
Yogender Gupta
de64dd13cb
avcodec: Add the extended pixel format profile for HEVC
...
It is supported by the NVIDIA video SDK 7.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2016-09-19 10:02:43 +02:00
Michael Niedermayer
136f552075
mpegvideo_motion: Handle edge emulation even without unrestricted_mv
...
Fix out of bounds read.
Bug-Id: 962
Found by: F4B3CD@STARLAB and Agostino Sarubbo
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2016-09-16 16:28:07 +02:00
Mark Thompson
3a9662af6c
vaapi_h264: Fix HRD bit_rate/cpb_size scaling
...
There should be an extra offset of 6 on bit_rate_scale and of 4 on
cpb_size_scale which were not accounted for here.
2016-09-14 20:48:36 +01:00
Diego Biurrun
de452e5037
pixblockdsp: Change type of stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
line size argument manually to be able to do pointer arithmetic.
Also adjust parameter names to be "stride" everywhere.
2016-09-14 14:12:36 +02:00
Diego Biurrun
468bfe38c6
ppc: mpegvideo: Add proper runtime AltiVec detection
2016-09-11 23:30:40 +02:00
Diego Biurrun
6ce93757ee
ppc: Update #endif comments
2016-09-11 19:19:41 +02:00
Luca Barbato
caccb3a0cd
audiodsp: ppc: Add VSX variant
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-09-11 19:19:41 +02:00
Mark Thompson
75d642a944
vaapi_vp8: Explicitly include libva vp8 decode header
...
With some old libva versions <va/va.h> does not automatically include
the per-codec subsidiary headers, so we need to include the right one
explicitly ourselves.
2016-09-09 18:56:18 +01:00
Mark Thompson
11c191b52c
vaapi_decode: Ignore the profile when not useful
...
Enables VP8 decoding - the decoder places the the bitstream version
in the profile field, which we want to ignore.
2016-09-08 21:58:22 +01:00
Mark Thompson
a9fb134730
lavc/vaapi: Add VP8 decode hwaccel
2016-09-08 21:58:22 +01:00
Mark Thompson
4e528206bc
vp8: Add hwaccel hooks
...
Also adds some extra fields to the main context structure that may
be needed by a hwaccel decoder.
2016-09-08 21:58:22 +01:00
Diego Biurrun
131a85a1fe
utvideo: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-08 13:51:30 +02:00
Diego Biurrun
52730e0f86
iir_filter: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-07 11:30:18 +02:00
Diego Biurrun
6b52762951
error_resilience: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-07 11:30:17 +02:00
Diego Biurrun
5b5ed92d92
sanm: Change type of array pitch parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array pitches and similar.
2016-09-04 12:19:58 +02:00
Diego Biurrun
73f5e17a20
copy_block: Change type of array stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-09-04 12:19:47 +02:00
Diego Biurrun
21e500ba64
svq1dec: Change type of array pitch parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array pitches and similar.
2016-09-04 11:57:15 +02:00
Diego Biurrun
746c56b773
indeo: Change type of array pitch parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array pitches and similar.
2016-09-04 11:57:15 +02:00
Mark Thompson
851960f6f8
lavc: Remove old vaapi decode infrastructure
...
Deprecates struct vaapi_context and the installed header vaapi.h,
to be removed at the next version bump.
2016-08-30 22:16:01 +01:00
Mark Thompson
ccd0316f7c
vaapi_mpeg4: Convert to use the new VAAPI hwaccel code
2016-08-30 21:45:59 +01:00
Mark Thompson
520fb77285
vaapi_vc1: Convert to use the new VAAPI hwaccel code
2016-08-30 21:45:59 +01:00
Mark Thompson
102e13c353
vaapi_mpeg2: Convert to use the new VAAPI hwaccel code
2016-08-30 21:45:59 +01:00
Mark Thompson
2fe93244ab
vaapi_h264: Convert to use the new VAAPI hwaccel code
2016-08-30 21:45:59 +01:00
Mark Thompson
123ccd07c5
lavc: Rewrite VAAPI decode infrastructure
...
Moves much of the setup logic for VAAPI decoding into lavc; the user
now need only provide the hw_frames_ctx.
2016-08-30 21:45:59 +01:00
Diego Biurrun
72eba6558e
wmavoice: Simplify GetBitContext initialization
2016-08-30 22:06:47 +02:00
Diego Biurrun
4ab496261b
libvpx: Cast a pointer to const to squelch a warning
...
libavcodec/libvpxdec.c💯 57: warning: passing argument 3 of 'av_image_copy' from incompatible pointer type
av_image_copy(picture->data, picture->linesize, img->planes,
libavutil/imgutils.h:116:6: note: expected 'const uint8_t **' but argument is of type 'unsigned char **'
void av_image_copy(uint8_t *dst_data[4], int dst_linesizes[4],
2016-08-26 13:25:59 +02:00
Diego Biurrun
721d57e608
vp56: Separate VP5 and VP6 dsp initialization
...
VP5 has no arch-specific optimizations (nor will it get some in the
future), so it makes no sense to try to share dsp init code with VP6.
2016-08-26 11:50:22 +02:00
Diego Biurrun
3fd22538bc
prores: Change type of stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
line size argument manually to be able to do pointer arithmetic.
Also adjust parameter names to be "linesize" everywhere.
2016-08-26 11:50:21 +02:00
Diego Biurrun
f81be06cf6
cavs: Change type of stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-08-26 11:48:15 +02:00
Diego Biurrun
802727b538
vp8: Update some assembly comments left unchanged in bd66f073fe
2016-08-26 11:36:53 +02:00
Diego Biurrun
87c6c78604
vp8: Change type of stride parameters to ptrdiff_t
...
ptrdiff_t is the correct type for array strides and similar.
2016-08-26 11:36:53 +02:00
Diego Biurrun
d9d26a3674
vp56: Change type of stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
line size argument manually to be able to do pointer arithmetic.
2016-08-26 11:36:26 +02:00
Diego Biurrun
6892df9294
vp3: Change type of stride parameters to ptrdiff_t
...
This avoids SIMD-optimized functions having to sign-extend their
stride argument manually to be able to do pointer arithmetic.
Also adjust parameter names to be "stride" everywhere.
2016-08-26 11:36:26 +02:00
Luca Barbato
d42809f983
av1: Add codec_id and basic demuxing support
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
2016-08-24 14:45:08 +02:00
Anton Khirnov
6755eb5b21
mss12: validate display dimensions
...
The code currently reads the coded dimensions from the extradata, but
expects the display dimensions to be set by the caller, and does not
check that they are compatible (i.e. that the displayed size is smaller
than the coded size).
Make sure that when the display dimensions are set, they are also valid.
Fixes possible invalid memory access.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
33f10546ec
vc1: check that slices have a positive height
...
Fixes possible invalid reads.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
09b23786b3
pcx: use the bytestream2 API for reading from input
...
Fixes possible invalid reads.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
221402c1c8
pcx: check that the packet is large enough before reading the header
...
Fixes possible invalid reads.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
15ee419b7a
pcx: properly pad the scanline
...
It is passed to the get_bits API, which requires buffers to be padded.
Fixes possible invalid reads.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
409d1cd2c9
cook: use the bytestream2 API for reading extradata
...
Fixes possible invalid reads in corrupted files.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
bba9d8bdfb
qpeg: fix an off by 1 error in the MV check
...
height - me_y is the line from which we read, so it must be strictly
smaller than the frame height. Fixes possible invalid reads in corrupted
files.
Also, use a proper context for logging the error.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
796dca027b
alac: do not return success if nothing was decoded
...
If we encounter an END element before anything is decoded, we would
return success even though the output frame has not been allocated,
which is invalid.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Anton Khirnov
f5d46d3322
vmnc: check that subrectangles fit into their containing rectangles
...
Fixes possible invalid writes with corrupted files.
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2016-08-18 17:06:46 +02:00
Diego Biurrun
83b92a855e
golomb: Drop disabled cruft
2016-08-17 12:22:29 +02:00
Diego Biurrun
014852e932
simple_idct: arm: Drop disabled code variant
2016-08-17 12:21:54 +02:00
Diego Biurrun
e2b9993558
simple_idct: x86: Drop disabled IDCT implementation
...
This gem has been disabled since 2001.
2016-08-17 12:21:54 +02:00
Diego Biurrun
7effebde78
dvbsubdec: Remove disabled, near-duplicate debug code
2016-08-17 12:16:42 +02:00
Diego Biurrun
0e285c2f90
mpegvideo: Kill some disabled code
2016-08-17 12:16:42 +02:00
Diego Biurrun
f2f145f303
msmpeg4: Drop disabled debug cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
be1db21ba8
mathops: Drop disabled alternative mid_pred() implementation
2016-08-17 12:16:42 +02:00
Diego Biurrun
b53d8c3ccf
mjpegdec: Drop disabled code
2016-08-17 12:16:42 +02:00
Diego Biurrun
34c22a9ca6
faan(i)dct: Kill some disabled code
2016-08-17 12:16:42 +02:00
Diego Biurrun
17cb56b356
ffv1: Remove broken disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
b96f0ab3d2
h264: Kill broken disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
42c4c2d2a6
aac: Drop broken cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
263efc095e
jfdct: Kill broken cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
dab2034b86
roqvideoenc: Drop broken disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
562bec0e69
pnm_parser: Drop broken disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
a972fc1c0a
wma: Kill non-compiling disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
d5fda00efa
mpeg4videoenc: Kill non-compiling disabled cruft
2016-08-17 12:16:42 +02:00
Diego Biurrun
e4d5b55193
rangecoder: Kill non-compiling disabled cruft
2016-08-17 12:16:42 +02:00
Mark Thompson
5a667322f5
vaapi_vc1: Remove redundant version check
...
The lowest supported VAAPI version is 0.34 (checked at configure
time), so this test is no longer needed.
2016-08-13 09:46:48 +01:00
Mark Thompson
01d6f84f49
vaapi_vc1: Constify pointers
2016-08-13 09:46:48 +01:00
Mark Thompson
ee9061293e
vaapi_mpeg2: Constify pointers
2016-08-13 09:46:48 +01:00
Mark Thompson
03adfe9130
vaapi_h264: Constify pointers
2016-08-13 09:46:48 +01:00
Anton Khirnov
f2143c57b6
vp9: reindent after last commit
2016-08-11 11:02:47 +02:00
Ronald S. Bultje
1730a67ab9
vp9: add frame threading
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2016-08-11 10:54:44 +02:00
Ronald S. Bultje
5b995452a6
vp9: allocate 'b', 'block/uvblock' and 'eob/uveob' dynamically.
...
This will be needed for frame threading.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2016-08-11 10:54:20 +02:00
Ronald S. Bultje
bc6e0b64a9
vp9: split last/cur_frame from the reference buffers.
...
We need more information from last/cur_frame than from reference
buffers, so we can use a simplified structure for reference buffers,
and then store mvs and segmentation map information in last/cur.
This prepares the decoder for frame threading support.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2016-08-11 10:53:13 +02:00
Anton Khirnov
04763c6f87
h264_direct: use the reference mask from the actual reference
...
Not from the underlying frame. Fixes races with frame threading in
field-coded files, where decoding would wait for the wrong field (e.g.
random failures in mixed-nal-coding).
Bug-Id: 954
2016-08-11 10:52:54 +02:00