[FFmpeg-cvslog] qsvenc: properly handle the warning from MFXVideoCORE_SyncOperation
Maxym Dmytrychenko
git at videolan.org
Tue Jan 19 08:43:49 CET 2016
ffmpeg | branch: master | Maxym Dmytrychenko <maxym.dmytrychenko at intel.com> | Fri Dec 18 14:24:36 2015 +0100| [a6259a6ecbad18d58085e4ab23f56151e98d7b53] | committer: Anton Khirnov
qsvenc: properly handle the warning from MFXVideoCORE_SyncOperation
Same as what is done in 3b6473b43eb69fc3faaf69f7fd0b83b51db7607f.
Signed-off-by: Anton Khirnov <anton at khirnov.net>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a6259a6ecbad18d58085e4ab23f56151e98d7b53
---
libavcodec/qsvenc.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c
index f19ca76..cda11fa 100644
--- a/libavcodec/qsvenc.c
+++ b/libavcodec/qsvenc.c
@@ -919,7 +919,9 @@ int ff_qsv_encode(AVCodecContext *avctx, QSVEncContext *q,
av_fifo_generic_read(q->async_fifo, &sync, sizeof(sync), NULL);
av_fifo_generic_read(q->async_fifo, &bs, sizeof(bs), NULL);
- MFXVideoCORE_SyncOperation(q->session, sync, 60000);
+ do {
+ ret = MFXVideoCORE_SyncOperation(q->session, sync, 1000);
+ } while (ret == MFX_WRN_IN_EXECUTION);
new_pkt.dts = av_rescale_q(bs->DecodeTimeStamp, (AVRational){1, 90000}, avctx->time_base);
new_pkt.pts = av_rescale_q(bs->TimeStamp, (AVRational){1, 90000}, avctx->time_base);
More information about the ffmpeg-cvslog
mailing list