您当前的位置: 首页 >  windows

编译WINDOWS版FFmpeg:编译FFmpeg

柳鲲鹏 发布时间:2020-04-13 11:39:36 ,浏览量:0

  其实简单。吾之所以费了这么大的事情,关键就在于,试图在WIN7虚拟机上编译,于是有各种莫名其妙的错误。

参考:https://www.jianshu.com/p/5f175dec9109。

  • 下载FFmpegInterop

https://github.com/microsoft/FFmpegInterop

  • 下载ffmpeg

下载、解压、改名ffmpeg,放在FFmpegInterop下。

  • MSYS2环境准备

https://quantum6.blog.csdn.net/article/details/105431904

  • 编译x264

https://quantum6.blog.csdn.net/article/details/105484929

  • 编译SDL2

https://blog.csdn.net/quantum7/article/details/105487140

  • configure

修改FFmpegConfig.sh

--enable-gpl \
--enable-nonfree \
--enable-libx264 \
--enable-sdl \
--extra-cflags="-I${BUILD_LIBS}/include" \
--extra-ldflags="-LIBPATH:${BUILD_LIBS}/lib"

执行:

./FFmpegConfig.sh Win10 x64

说是把新生成的config.h文件打开后转换为UTF-8格式。这样可以避免非常多的警告。

  • make
./BuildFFmpeg.bat win10 x64
  • 检查32位还是64位:
查看32位还是64位:
dumpbin /headers libx264.dll

查看符号清单(导出函数)
dumpbin /exports libx264.dll > libx264-exports.txt
关注
打赏
1688896170
查看更多评论

柳鲲鹏

暂无认证

  • 0浏览

    0关注

    4641博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文
立即登录/注册

微信扫码登录

0.0569s