From 1cc0f51c076b4071a31eda0031708daac88bac64 Mon Sep 17 00:00:00 2001 From: ljx0305 Date: Thu, 9 Mar 2023 15:24:32 +0800 Subject: [PATCH] replace ffmpeg deprecated api avpicture_fill to av_image_fill_arrays (#2279) --- src/Codec/Transcode.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Codec/Transcode.cpp b/src/Codec/Transcode.cpp index eb92015f..bab515cc 100644 --- a/src/Codec/Transcode.cpp +++ b/src/Codec/Transcode.cpp @@ -672,7 +672,7 @@ FFmpegFrame::Ptr FFmpegSws::inputFrame(const FFmpegFrame::Ptr &frame, int &ret, auto out = std::make_shared(); if (!out->get()->data[0]) { if (data) { - avpicture_fill((AVPicture *) out->get(), data, _target_format, target_width, target_height); + av_image_fill_arrays(out->get()->data, out->get()->linesize, data, _target_format, target_width, target_height, 1); } else { out->fillPicture(_target_format, target_width, target_height); }