ffmpegencoder: use avfilter instead of swscale for pixel format conversions

This commit is contained in:
itsmattkc
2022-08-07 14:00:12 -07:00
parent 91eaa759b7
commit 73fa930f02
4 changed files with 90 additions and 86 deletions
+6
View File
@@ -59,6 +59,12 @@ public:
static AVSampleFormat GetFFmpegSampleFormat(const AudioParams::Format &smp_fmt);
};
using AVFramePtr = std::shared_ptr<AVFrame>;
inline AVFramePtr CreateAVFramePtr(AVFrame *f)
{
return std::shared_ptr<AVFrame>(f, [](AVFrame *g){ av_frame_free(&g); });
}
}
#endif // FFMPEGABSTRACTION_H