Sven Dueking
5d4a3563f2
qsvenc.c: use query to catch all kind of setting issues
...
Reviewed-by: Ivan Uskov <ivan.uskov@nablet.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-10-01 16:12:33 +02:00
Hendrik Leppkes
49a25d02dd
Merge commit '83847cc8fa97e0fc637a0962bafb837acdb6eacc'
...
* commit '83847cc8fa97e0fc637a0962bafb837acdb6eacc':
qsvenc: do not try to close the encoder if the session is NULL
Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2015-09-29 14:10:25 +02:00
Anton Khirnov
83847cc8fa
qsvenc: do not try to close the encoder if the session is NULL
2015-09-28 15:42:56 +02:00
Sven Dueking
67e87f8050
avcodec/qsv : Added look ahead rate control mode
...
Reviewed-by: Ivan Uskov <ivan.uskov@nablet.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-30 16:00:05 +02:00
Sven Dueking
6eecb91fbc
avcodec/qsvenc: Added PicTiming SEI
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-19 13:49:37 +02:00
Sven Dueking
f3fbe790d9
avcodec/qsvenc: Set MaxKpbs to rc_max_rate for CBR and VBR (bitrate is equal to rc_max_rate for CBR)
...
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-08-14 14:51:47 +02:00
Ivan Uskov
947c2aa456
libavcodec/qsvenc.c delay in 1 microsecond replaced to more appropriate 500 microseconds
...
This commit replaces the 1 microsecond delay by 500 microsecond for the
case when the MFX library does return MFX_WRN_DEVICE_BUSY status.
In general this warning never appears for simple encoding or
transcoding session because the GPU is so fast so it almost always is not busy and
any delay value just does not executes.
But for heavy transcoding tasks for example, when several QSV sessions
are running simultaneously then using a 1-microsecond delay may
result in 1000 iterations per each frame.
So here possible a paradoxical case when GPU loading also loads CPU by dummy tasks.
Official MFX/QSV samples by Intel are using 1 millisecond (i.e. 1000
microseconds) everywhere where MFX_WRN_DEVICE_BUSY does appear.
So 500us is a much more optimal value than 1us.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-28 20:37:38 +02:00
Michael Niedermayer
29d147c94d
Merge commit '059a934806d61f7af9ab3fd9f74994b838ea5eba'
...
* commit '059a934806d61f7af9ab3fd9f74994b838ea5eba':
lavc: Consistently prefix input buffer defines
Conflicts:
doc/examples/decoding_encoding.c
libavcodec/4xm.c
libavcodec/aac_adtstoasc_bsf.c
libavcodec/aacdec.c
libavcodec/aacenc.c
libavcodec/ac3dec.h
libavcodec/asvenc.c
libavcodec/avcodec.h
libavcodec/avpacket.c
libavcodec/dvdec.c
libavcodec/ffv1enc.c
libavcodec/g2meet.c
libavcodec/gif.c
libavcodec/h264.c
libavcodec/h264_mp4toannexb_bsf.c
libavcodec/huffyuvdec.c
libavcodec/huffyuvenc.c
libavcodec/jpeglsenc.c
libavcodec/libxvid.c
libavcodec/mdec.c
libavcodec/motionpixels.c
libavcodec/mpeg4videodec.c
libavcodec/mpegvideo.c
libavcodec/noise_bsf.c
libavcodec/nuv.c
libavcodec/nvenc.c
libavcodec/options.c
libavcodec/parser.c
libavcodec/pngenc.c
libavcodec/proresenc_kostya.c
libavcodec/qsvdec.c
libavcodec/svq1enc.c
libavcodec/tiffenc.c
libavcodec/truemotion2.c
libavcodec/utils.c
libavcodec/utvideoenc.c
libavcodec/vc1dec.c
libavcodec/wmalosslessdec.c
libavformat/adxdec.c
libavformat/aiffdec.c
libavformat/apc.c
libavformat/apetag.c
libavformat/avidec.c
libavformat/bink.c
libavformat/cafdec.c
libavformat/flvdec.c
libavformat/id3v2.c
libavformat/isom.c
libavformat/matroskadec.c
libavformat/mov.c
libavformat/mpc.c
libavformat/mpc8.c
libavformat/mpegts.c
libavformat/mvi.c
libavformat/mxfdec.c
libavformat/mxg.c
libavformat/nutdec.c
libavformat/oggdec.c
libavformat/oggparsecelt.c
libavformat/oggparseflac.c
libavformat/oggparseopus.c
libavformat/oggparsespeex.c
libavformat/omadec.c
libavformat/rawdec.c
libavformat/riffdec.c
libavformat/rl2.c
libavformat/rmdec.c
libavformat/rtpdec_latm.c
libavformat/rtpdec_mpeg4.c
libavformat/rtpdec_qdm2.c
libavformat/rtpdec_svq3.c
libavformat/sierravmd.c
libavformat/smacker.c
libavformat/smush.c
libavformat/spdifenc.c
libavformat/takdec.c
libavformat/tta.c
libavformat/utils.c
libavformat/vqf.c
libavformat/westwood_vqa.c
libavformat/xmv.c
libavformat/xwma.c
libavformat/yop.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 23:15:19 +02:00
Michael Niedermayer
94d68a41fa
Merge commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615'
...
* commit '7c6eb0a1b7bf1aac7f033a7ec6d8cacc3b5c2615':
lavc: AV-prefix all codec flags
Conflicts:
doc/examples/muxing.c
ffmpeg.c
ffmpeg_opt.c
ffplay.c
libavcodec/aacdec.c
libavcodec/aacenc.c
libavcodec/ac3dec.c
libavcodec/ac3enc_float.c
libavcodec/atrac1.c
libavcodec/atrac3.c
libavcodec/atrac3plusdec.c
libavcodec/dcadec.c
libavcodec/ffv1enc.c
libavcodec/h264.c
libavcodec/h264_loopfilter.c
libavcodec/h264_mb.c
libavcodec/imc.c
libavcodec/libmp3lame.c
libavcodec/libtheoraenc.c
libavcodec/libtwolame.c
libavcodec/libvpxenc.c
libavcodec/libxavs.c
libavcodec/libxvid.c
libavcodec/mpeg12dec.c
libavcodec/mpeg12enc.c
libavcodec/mpegaudiodec_template.c
libavcodec/mpegvideo.c
libavcodec/mpegvideo_enc.c
libavcodec/mpegvideo_motion.c
libavcodec/nellymoserdec.c
libavcodec/nellymoserenc.c
libavcodec/nvenc.c
libavcodec/on2avc.c
libavcodec/options_table.h
libavcodec/opus_celt.c
libavcodec/pngenc.c
libavcodec/ra288.c
libavcodec/ratecontrol.c
libavcodec/twinvq.c
libavcodec/vc1_block.c
libavcodec/vc1_loopfilter.c
libavcodec/vc1_mc.c
libavcodec/vc1dec.c
libavcodec/vorbisdec.c
libavcodec/vp3.c
libavcodec/wma.c
libavcodec/wmaprodec.c
libavcodec/x86/hpeldsp_init.c
libavcodec/x86/me_cmp_init.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-27 22:10:35 +02:00
Vittorio Giovara
059a934806
lavc: Consistently prefix input buffer defines
...
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:59 +01:00
Vittorio Giovara
7c6eb0a1b7
lavc: AV-prefix all codec flags
...
Convert doxygen to multiline and express bitfields more simply.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-27 15:24:58 +01:00
Michael Niedermayer
495eee0123
Merge commit '40cf1bbacc6220a0aa6bed5c331871d43f9ce370'
...
* commit '40cf1bbacc6220a0aa6bed5c331871d43f9ce370':
Deprecate avctx.coded_frame
Conflicts:
ffmpeg.c
libavcodec/a64multienc.c
libavcodec/asvenc.c
libavcodec/cljrenc.c
libavcodec/dpxenc.c
libavcodec/gif.c
libavcodec/mpegvideo_enc.c
libavcodec/nvenc.c
libavcodec/proresenc_kostya.c
libavcodec/pthread_frame.c
libavcodec/rawenc.c
libavcodec/sunrastenc.c
libavcodec/tiffenc.c
libavcodec/version.h
libavcodec/xbmenc.c
libavcodec/xwdenc.c
libavdevice/v4l2.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-21 01:17:15 +02:00
Michael Niedermayer
b1fad7ac20
Merge commit 'd6604b29ef544793479d7fb4e05ef6622bb3e534'
...
* commit 'd6604b29ef544793479d7fb4e05ef6622bb3e534':
Gather all coded_frame allocations and free functions to a single place
Conflicts:
libavcodec/a64multienc.c
libavcodec/asvenc.c
libavcodec/cljrenc.c
libavcodec/dpxenc.c
libavcodec/dvenc.c
libavcodec/gif.c
libavcodec/huffyuvenc.c
libavcodec/jpeglsenc.c
libavcodec/libopenjpegenc.c
libavcodec/libtheoraenc.c
libavcodec/libvpxenc.c
libavcodec/mpegvideo_enc.c
libavcodec/nvenc.c
libavcodec/pngenc.c
libavcodec/proresenc_kostya.c
libavcodec/sunrastenc.c
libavcodec/tiffenc.c
libavcodec/utils.c
libavcodec/utvideoenc.c
libavcodec/v210enc.c
libavcodec/v410enc.c
libavcodec/xbmenc.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-20 23:43:05 +02:00
Vittorio Giovara
40cf1bbacc
Deprecate avctx.coded_frame
...
The rationale is that coded_frame was only used to communicate key_frame,
pict_type and quality to the caller, as well as a few other random fields,
in a non predictable, let alone consistent way.
There was agreement that there was no use case for coded_frame, as it is
a full-sized AVFrame container used for just 2-3 int-sized properties,
which shouldn't even belong into the AVCodecContext in the first place.
The appropriate AVPacket flag can be used instead of key_frame, while
quality is exported with the new AVPacketSideData quality factor.
There is no replacement for the other fields as they were unreliable,
mishandled or just not used at all.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-20 15:06:50 +01:00
Vittorio Giovara
d6604b29ef
Gather all coded_frame allocations and free functions to a single place
...
Allocating coded_frame is what most encoders do anyway, so it makes
sense to always allocate and free it in a single place. Moreover a lot
of encoders freed the frame with av_freep() instead of the correct API
av_frame_free().
This bring uniformity to encoder behaviour and prevents applications
from erroneusly accessing this field when not allocated. Additionally
this helps isolating encoders that export information with coded_frame,
and heavily simplifies its deprecation.
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-07-20 14:16:15 +01:00
Michael Niedermayer
9c943e077b
Merge commit '69b92f1b99f3f210be19ee6ec06f6c0de1733031'
...
* commit '69b92f1b99f3f210be19ee6ec06f6c0de1733031':
qsvenc: properly handle asynchronous encoding
Conflicts:
libavcodec/qsvenc.c
Merged-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-19 16:34:12 +02:00
Anton Khirnov
69b92f1b99
qsvenc: properly handle asynchronous encoding
...
Wait for async_depth frames before syncing.
2015-07-19 10:06:53 +02:00
Ivan Uskov
ce91bab70f
libavcodec/qsv.c: Issue fixed: QSV engine does not release display handler under linux platform.
...
Reviewed-by: Gwenole Beauchesne <gb.devel@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2015-07-14 02:02:55 +02:00
Ivan Uskov
5985316fba
libavcodec/qsvenc.c: improving handling for return codes of MFXVideoENCODE_EncodeFrameAsync
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-10 01:26:16 +02:00
Ivan Uskov
dbf8352a2e
libavcodec/qsvenc.c: Fix for too agressive height alignment during frame encoding which may be reason of superflous frame copying.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-09 17:46:18 +02:00
Michael Niedermayer
7871eb4361
Merge commit '66acb76bb0492b263215ca9b4d927a7be39ace02'
...
* commit '66acb76bb0492b263215ca9b4d927a7be39ace02':
lavc: add Intel libmfx-based HEVC encoder
Conflicts:
Changelog
configure
libavcodec/Makefile
libavcodec/allcodecs.c
libavcodec/qsv.c
libavcodec/qsvenc.c
libavcodec/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-09 11:53:14 +02:00
Michael Niedermayer
96ee6b9962
Merge commit '3a85397e8bb477eb34678d9edc52893f57003226'
...
* commit '3a85397e8bb477eb34678d9edc52893f57003226':
lavc: add Intel libmfx-based MPEG2 encoder
Conflicts:
Changelog
configure
libavcodec/allcodecs.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-09 11:17:12 +02:00
Ivan Uskov
b409748bc4
libavcodec/qsvenc.c: fix incorrect loop condition.
...
For example, the encoder may return MFX_WRN_INCOMPATIBLE_VIDEO_PARAM warning
i.e. ret==5 old loop implementation will repeat several times until output buffer
overflow. New implementation explicitly uses loop only for device busy case.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-09 02:25:39 +02:00
Anton Khirnov
66acb76bb0
lavc: add Intel libmfx-based HEVC encoder
2015-07-08 23:40:11 +02:00
Anton Khirnov
3a85397e8b
lavc: add Intel libmfx-based MPEG2 encoder
2015-07-08 23:39:28 +02:00
Ivan Uskov
115c14c3b6
libavcodec/qsvenc.c: A warning message when library will work at partial hardware acceleration.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-06 17:39:08 +02:00
Ivan Uskov
38402754b9
libavcodec/qsvenc.c: More correct selection of alignment of a frame height depending whether an encoded sequence progressive or not.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-06 15:13:08 +02:00
Michael Niedermayer
0a731e4596
Merge commit '72b7441a10f578a1d0be7083d8f5adf6a01921c2'
...
* commit '72b7441a10f578a1d0be7083d8f5adf6a01921c2':
lavc: add Intel libmfx-based H.264 encoder
Conflicts:
Changelog
libavcodec/version.h
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-28 01:33:27 +01:00
Anton Khirnov
72b7441a10
lavc: add Intel libmfx-based H.264 encoder
2015-03-27 22:02:10 +01:00