mirror of
https://github.com/jellyfin/jellyfin-ffmpeg.git
synced 2026-09-03 05:09:58 +03:00
lavc/videotoolbox: don't return external error for invalid vt frame
Some video sources are not reliable and will contain frames that is not decodable with hardware accelerators. Current ffmpeg's scheduling has low tolarance for decoder errors it does not understand. Just return 0 after unref the frame instead so that ffmpeg will no longer abort early due to videotoolbox is not able to decode a frame.
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
Index: ffmpeg/libavcodec/videotoolbox.c
|
||||
===================================================================
|
||||
--- ffmpeg.orig/libavcodec/videotoolbox.c
|
||||
+++ ffmpeg/libavcodec/videotoolbox.c
|
||||
@@ -124,7 +124,7 @@ static int videotoolbox_postproc_frame(v
|
||||
if (!ref->pixbuf) {
|
||||
av_log(avctx, AV_LOG_ERROR, "No frame decoded?\n");
|
||||
av_frame_unref(frame);
|
||||
- return AVERROR_EXTERNAL;
|
||||
+ return 0;
|
||||
}
|
||||
|
||||
frame->crop_right = 0;
|
||||
Vendored
+1
@@ -89,3 +89,4 @@
|
||||
0089-fix-display-matrix-not-removed-after-autorotation.patch
|
||||
0090-unbreak-build-with-latest-svtav1-3-0.patch
|
||||
0091-backport-fix-for-missing-h264-sei-build-deps.patch
|
||||
0092-dont-return-ext-error-for-invalid-vt-frame
|
||||
|
||||
Reference in New Issue
Block a user