ffmpeg只转封装不转码的代码实现

在有些场景下,其实只须要转封装,不须要转码, 大概步骤以下: 1. 打开输入的formatcontext 2. 打开输出文件 3. 打开输出的formatcontext 4. 写文件头 5. 复制codec信息 6. 读取输入frame 7. 写输出frame 8. 写文件尾 9. 关闭输出文件 代码以下: #include <stdio.h> #include <stdlib.h> #inclu
相关文章
相关标签/搜索