Commit 1cc0f51c by ljx0305 Committed by GitHub

replace ffmpeg deprecated api avpicture_fill to av_image_fill_arrays (#2279)

parent cba46e2c
...@@ -672,7 +672,7 @@ FFmpegFrame::Ptr FFmpegSws::inputFrame(const FFmpegFrame::Ptr &frame, int &ret, ...@@ -672,7 +672,7 @@ FFmpegFrame::Ptr FFmpegSws::inputFrame(const FFmpegFrame::Ptr &frame, int &ret,
auto out = std::make_shared<FFmpegFrame>(); auto out = std::make_shared<FFmpegFrame>();
if (!out->get()->data[0]) { if (!out->get()->data[0]) {
if (data) { 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 { } else {
out->fillPicture(_target_format, target_width, target_height); out->fillPicture(_target_format, target_width, target_height);
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论