在iOS中添加FFMPEG库 [英] Add FFMPEG library in iOS

查看:132
本文介绍了在iOS中添加FFMPEG库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用FFMPEG库的功能(例如 libavcodec.a,libavformat.a,libavutil.a和libswresample.a 但我对如何将FFMPEG库添加到我的项目感到困惑。

I am trying to use features of the FFMPEG library (such like libavcodec.a, libavformat.a, libavutil.a and libswresample.a) but I am confused on how to add the FFMPEG library to my project.

为什么选择FFMPEG库? => 因为在我的项目中我想播放实时URL流,这个URL是Window Media Audio文件 (。wma) ,因为iOS没有直接支持' .wma '文件,我需要将此实时网址流转换为iOS设备支持的格式。为此,我使用的是 RadioTunes SDK,所有内容都是好不好除了我不知道 FFMPEG库的安装

WHY FFMPEG library? => Because in my project I want to play Live URL Streaming, This URL is Window Media Audio file (.wma) since iOS has no direct support for '.wma' files, I need to convert this Live URL Streaming to an iOS device supported format. For doing this I am using RadioTunes SDK, All things are well and good except I don't know about the installation of FFMPEG library

有很多与我有关的问题,但没有人可以帮助我。

There are many question related to mine but none can help me.

如何构建FFMPEG并将其链接到iOS?

在iOS上使用ffmpeg

我从这里下载 FFMPEG库以获取10.5.x

推荐答案

我不完全理解如何将FFMPEG库添加到我的项目中的含义,但是我想你想构建FFMPEG库并在你的项目中使用它?
如果是这种情况,您必须执行以下操作:

I don't totally understand what you mean by "how to add the FFMPEG library to my project" but I think you want to build the FFMPEG library and use it in your project? If that's the case you have to do the following:


  1. 下载FFMPEG源并根据您想要的体系结构编译它们支持(armv6,armv7 arm64,...)。

  2. 使用lipo将不同体系结构的库放在一起(什么能使你获得通用库)

  3. 将通用库与所需的FFMPEG头文件一起添加到项目中。

完成这三个步骤后,您可以使用FFMPEG你代码中的库。

After those three steps you can use the FFMPEG library in you code.

不幸的是,第1步是一种痛苦。您将不得不挖掘一些教程以获得FFMPEG源代码进行编译。有几个堆栈溢出问题可能对您有所帮助:

Unfortunately step 1 is kind of a pain. You will have to dig a bit for tutorials to get the FFMPEG sources to compile. There are several stack overflow questions that might help you:

使用xCode 5构建FFmpeg
FFMPEG iOS 7 Library
安装ffmpeg ios库armv7,armv7s,i386和Mac上的通用10.8

最后一个链接似乎是最有希望的。祝你好运!

The last link seems to be the most promising one. Good luck!

这篇关于在iOS中添加FFMPEG库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆