aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/qsvdec_other.c
Commit message (Collapse)AuthorAgeFilesLines
* ffplay, avcodec, avformat: Don't initialize before av_packet_ref()Andreas Rheinhardt2020-03-281-1/+1
| | | | | | | It already initializes the packet. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* lavc/qsvdec: Add GPU-accelerated memory copy supportLinjie Fu2019-10-091-0/+5
| | | | | | | | | | | | | | | | GPU copy enables or disables GPU accelerated copying between video and system memory. This may lead to a notable performance improvement. Memory must be sequent and aligned with 128x64. CMD: ffmpeg -init_hw_device qsv=hw -filter_hw_device hw -c:v h264_qsv -gpu_copy on -i input.h264 -f null - or: ffmpeg -c:v h264_qsv -gpu_copy on -i input.h264 -f null - Signed-off-by: Linjie Fu <linjie.fu@intel.com> Signed-off-by: ChaoX A Liu <chaox.a.liu@intel.com> Signed-off-by: Zhong Li <zhong.li@intel.com>
* lavc/qsvdec: Add VP9 decoder supportZhong Li2019-08-201-3/+43
| | | | | | VP9 decoder is support on Intel kabyLake+ platforms with MSDK Version 1.19+ Signed-off-by: Zhong Li <zhong.li@intel.com>
* lavc/qsvdec: Add mjpeg decoder supportZhong Li2019-08-201-1/+27
| | | | Signed-off-by: Zhong Li <zhong.li@intel.com>
* lavc/qsvdec: Replace current parser with MFXVideoDECODE_DecodeHeader()Zhong Li2019-08-201-0/+1
| | | | | | | | | | | | | | | | | Using MSDK parser can improve qsv decoder pass rate in some cases (E.g: sps declares a wrong level_idc, smaller than it should be). And it is necessary for adding new qsv decoders such as MJPEG and VP9 since current parser can't provide enough information. Actually using MFXVideoDECODE_DecodeHeader() was disscussed at https://ffmpeg.org/pipermail/ffmpeg-devel/2015-July/175734.html and merged as commit 1acb19d, but was overwritten when merged libav patches (commit: 1f26a23) without any explain. Split decode header from decode_init, and call it for everyframe to detect format/resoultion change. It can fix some regression issues such as hevc 10bits decoding. Signed-off-by: Zhong Li <zhong.li@intel.com> Signed-off-by: Dmitry Rogozhkin <dmitry.v.rogozhkin@intel.com>
* lavc/qsvdec: flush buffered data before reinitLinjie Fu2018-11-061-3/+7
| | | | | | | | | | | | | | | | | Flush the buffered data in libmfx before video param reinit in case the frames drop. Cache the first frame causing the reinit and decode zero-size pkt to flush the buffered pkt before reinit. After all the buffered pkts being flushed, resume to reinit and decode. Fix the issue in ticket #7399. [V2]: Move the definition of zero_pkt to where it is exactly used. Signed-off-by: Linjie Fu <linjie.fu@intel.com> Signed-off-by: Zhong Li <zhong.li@intel.com>
* Merge commit '69caad8959982580504643d36aef22528e4aa6ce'James Almer2018-09-111-1/+6
|\ | | | | | | | | | | | | * commit '69caad8959982580504643d36aef22528e4aa6ce': qsvdec: Release packet on decoding failure for mpeg2/vp8/vc1 Merged-by: James Almer <jamrial@gmail.com>
| * qsvdec: Release packet on decoding failure for mpeg2/vp8/vc1Zhong Li2018-08-231-1/+6
| | | | | | | | | | | | | | | | | | H264/265 have been fixed such an issue with commit 559370f2c45110afd8308eec7194437736c323d4. Similar fixing is needed for other codecs. Signed-off-by: Zhong Li <zhong.li@intel.com> Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | Merge commit 'c1bcd321ea2c2ae1765a1e64f03278712221d726'James Almer2018-09-021-1/+1
|\| | | | | | | | | | | | | * commit 'c1bcd321ea2c2ae1765a1e64f03278712221d726': avcodec/qsv: fix async support Merged-by: James Almer <jamrial@gmail.com>
| * avcodec/qsv: fix async supportDmitry Rogozhkin2018-07-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | Current implementations of qsv components incorrectly work with async level, they actually try to work in async+1 level stepping into MFX_WRN_DEVICE_BUSY and polling loop. This change address this misbehaviour. Signed-off-by: Dmitry Rogozhkin <dmitry.v.rogozhkin@intel.com> Cc: Maxym Dmytrychenko <maxim.d33@gmail.com> Cc: Zhong Li <zhong.li@intel.com> Signed-off-by: Maxym Dmytrychenko <maxim.d33@gmail.com>
| * lavc: Delete all fake hwaccelsMark Thompson2017-12-191-27/+0
| | | | | | | | They are now unused.
| * lavc: Add hardware config metadata for decoders supporting hardware outputMark Thompson2017-12-191-0/+3
| | | | | | | | | | | | | | | | | | This includes a pointer to the associated hwaccel for decoders using hwaccels - these will be used later to implement the hwaccel setup without needing a global list. Also added is a new file listing all hwaccels as external declarations - this will be used later to generate the hwaccel list at configure time.
| * avcodec: add metadata to identify wrappers and hardware decoderswm42017-12-141-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Explicitly identify decoder/encoder wrappers with a common name. This saves API users from guessing by the name suffix. For example, they don't have to guess that "h264_qsv" is the h264 QSV implementation, and instead they can just check the AVCodec .codec and .wrapper_name fields. Explicitly mark AVCodec entries that are hardware decoders or most likely hardware decoders with new AV_CODEC_CAPs. The purpose is allowing API users listing hardware decoders in a more generic way. The proposed AVCodecHWConfig does not provide this information fully, because it's concerned with decoder configuration, not information about the fact whether the hardware is used or not. AV_CODEC_CAP_HYBRID exists specifically for QSV, which can have software implementations in case the hardware is not capable. Based on a patch by Philip Langdale <philipl@overt.org>. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* | Merge commit 'f2e9a0ecbef5027f9532c49ffcdfc11d199f6150'James Almer2017-12-141-0/+5
|\| | | | | | | | | | | | | * commit 'f2e9a0ecbef5027f9532c49ffcdfc11d199f6150': qsv/vp8dec: fixes memory leak issue Merged-by: James Almer <jamrial@gmail.com>
| * qsv/vp8dec: fixes memory leak issueLi, Zhong2017-12-121-0/+5
| | | | | | | | | | Signed-off-by: Zhong Li <zhong.li@intel.com> Signed-off-by: Maxym Dmytrychenko <maxim.d33@gmail.com>
* | avcodec: add metadata to identify wrappers and hardware decoderswm42017-12-141-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Explicitly identify decoder/encoder wrappers with a common name. This saves API users from guessing by the name suffix. For example, they don't have to guess that "h264_qsv" is the h264 QSV implementation, and instead they can just check the AVCodec .codec and .wrapper_name fields. Explicitly mark AVCodec entries that are hardware decoders or most likely hardware decoders with new AV_CODEC_CAPs. The purpose is allowing API users listing hardware decoders in a more generic way. The proposed AVCodecHWConfig does not provide this information fully, because it's concerned with decoder configuration, not information about the fact whether the hardware is used or not. AV_CODEC_CAP_HYBRID exists specifically for QSV, which can have software implementations in case the hardware is not capable. Based on a patch by Philip Langdale <philipl@overt.org>. Merges Libav commit 47687a2f8aca3f65b6fdd117b1cb66a7409a7fd1.
* | lavc: Delete all fake hwaccelsMark Thompson2017-11-261-27/+0
| | | | | | | | They are now unused.
* | lavc: Add hardware config metadata for decoders supporting hardware outputMark Thompson2017-11-261-0/+3
| | | | | | | | | | | | | | | | | | This includes a pointer to the associated hwaccel for decoders using hwaccels - these will be used later to implement the hwaccel setup without needing a global list. Also added is a new file listing all hwaccels as external declarations - this will be used later to generate the hwaccel list at configure time.
* | Merge commit 'e0b164576f7467b7b1127c18175e215dc1df011f'Clément Bœsch2017-04-011-1/+47
|\| | | | | | | | | | | | | * commit 'e0b164576f7467b7b1127c18175e215dc1df011f': qsv: Add VP8 decoder Merged-by: Clément Bœsch <u@pkh.me>
| * qsv: Add VP8 decoderMark Thompson2016-11-141-1/+47
| |
* | Merge commit 'b6582b29277e00e5d49f400e58beefa5a21d83b8'James Almer2017-03-311-6/+6
|/ | | | | | | | | | * commit 'b6582b29277e00e5d49f400e58beefa5a21d83b8': qsv: Add VC-1 decoder See fb57bc6c34b979bec995e714162fdfb4caf6db1a. Merged for cosmetic purposes to reduce differences with libav. Merged-by: James Almer <jamrial@gmail.com>
* qsv: Add VC-1 decoderMark Thompson2016-11-141-0/+218
It uses the same code as the MPEG-2 decoder, so the file is renamed to contain all "other" (that is, not H.26[45]) codecs.