Sharpeye500
Sharpeye500

Reputation: 9073

Playing .flv files on iphone

I have a webservice returning .flv file, it has to be played in iphone application, how do i play a .flv (flash file) in iphone?

Does anyone has faced this scenario? Programmatically is it possible to convert to some format and play in iphone?

Thanks.

Upvotes: 7

Views: 22042

Answers (6)

UseR2001
UseR2001

Reputation: 29

For FLV files, what I do is I upload them on Google Drive and watch them from Google Drive app.

Upvotes: -3

Alterscape
Alterscape

Reputation: 1546

Pioto and Josaih are on the right track in suggesting that you should convert the video server-side using a tool like FFMpeg. As far as I know there is zero support for flv in any part of iOS, so you'd be unable to transcode it locally. Even if you could, it would make your users angry, since transcoding is a resource-intensive process that would kill their battery life and take a significant amount of time.

So, your solution is to transcode your videos to h.264 server-side. However, I'd caution against transcoding from flv->h.264 if there are any other options available. If you have the original, uncompressed (or at least less-compressed) source video available, you'll get higher-quality video by transcoding that to h.264. Each time lossy compression (eg, squeeze or h.264) is used on a file, you lose some information and quality. If you've ever seen a 3rd or 4th generation copy of a VHS tape, you can understand what I'm getting at.

Once you have a h.264 formatted video, you can play it on iOS. Not sure about the exact details of this.

Upvotes: 1

SInce the video is probably already h.264 encoded inside the FLV container, you may want to try FLV Extract on the server to avoid recompression:

http://www.videohelp.com/tools/FLV_Extract

Basically you just need to run it once for each of the videos on the server and keep the results around.

Upvotes: 3

pioto
pioto

Reputation: 2582

You may be able to use ffmpeg or something on your server to transcode it to H.264. I'm not so sure you would really want to do that transcoding on the phone. Given Apple's current stance on Flash, this is probably your best option.

Upvotes: 0

code_burgar
code_burgar

Reputation: 12323

IPhone doesn't and judging by the Apple official statements won't ever (or at least in the forseeable future) support flash content.

Converting the content to another format on the server side should be easy to do and would allow content playback on an iDevice.

Upvotes: 7

Josiah
Josiah

Reputation: 4854

I would recommend setting up your webservice to use something like ffmpeg ( http://www.ffmpeg.org/ ) to convert the .flv file to an mp4 file which can be played directly from the iPhone's web browser.

Upvotes: 1

Related Questions