欢迎访问 生活随笔!

生活随笔

当前位置: 首页 > 编程资源 > 编程问答 >内容正文

编程问答

FFMPEG结构体分析之AVFrame

发布时间:2024/2/28 编程问答 38 豆豆
生活随笔 收集整理的这篇文章主要介绍了 FFMPEG结构体分析之AVFrame 小编觉得挺不错的,现在分享给大家,帮大家做个参考.

AVFrame结构体一般用于存储解码后的原始数据(即非压缩数据,例如对视频来说是YUV,RGB,对音频来说是PCM),此外还包含了一些相关的信息。比如说,解码的时候存储了宏块类型表,QP表,运动矢量表等数据。

AVFrame 结构体定义位于libavutil/frame.h中,如下 /*** This structure describes decoded (raw) audio or video data.** AVFrame must be allocated using av_frame_alloc(). Note that this only* allocates the AVFrame itself, the buffers for the data must be managed* through other means (see below).* AVFrame must be freed with av_frame_free().** AVFrame is typically allocated once and then reused multiple times to hold* different data (e.g. a single AVFrame to hold frames received from a* decoder). In such a case, av_frame_unref() will free any references held by* the frame and reset it to its original clean state before it* is reused again.** The data described by an AVFrame is usually reference counted through the* AVBuffer API. The underlying buffer

总结

以上是生活随笔为你收集整理的FFMPEG结构体分析之AVFrame的全部内容,希望文章能够帮你解决所遇到的问题。

如果觉得生活随笔网站内容还不错,欢迎将生活随笔推荐给好友。