Follow the example in FFmpeg's doc, before calling the API `avcodec_send_frame`, always use `av_frame_alloc` to create a new frame. --------- Co-authored-by: Haibo Chen <495810242@qq.com>