[FFmpeg-cvslog] qsvenc: do not re-execute encoding on all positive status codes
Anton Khirnov
git at videolan.org
Sun Mar 12 18:03:39 EET 2017
ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Thu Jul 14 12:52:20 2016 +0200| [0956fd460681e8ccbdae19f135f0d3970bf95c2f] | committer: Anton Khirnov
qsvenc: do not re-execute encoding on all positive status codes
It should only be done for DEVICE_BUSY/IN_EXECUTION
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0956fd460681e8ccbdae19f135f0d3970bf95c2f
---
libavcodec/qsvenc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c
index fbbe23c..4697e1d 100644
--- a/libavcodec/qsvenc.c
+++ b/libavcodec/qsvenc.c
@@ -972,7 +972,7 @@ static int encode_frame(AVCodecContext *avctx, QSVEncContext *q,
ret = MFXVideoENCODE_EncodeFrameAsync(q->session, NULL, surf, bs, sync);
if (ret == MFX_WRN_DEVICE_BUSY)
av_usleep(1);
- } while (ret > 0);
+ } while (ret == MFX_WRN_DEVICE_BUSY || ret == MFX_WRN_IN_EXECUTION);
if (ret < 0) {
av_packet_unref(&new_pkt);
More information about the ffmpeg-cvslog
mailing list