I have some Audio files in mp4 format - which I used thinking this would be the best format for use on both iOS and Android devices. However they do not play with either AVAudioPlayer or AVPlayer. Is there another player that may handle it, or some way (in Swift) to covert them to mp3? Note this only an issue with mp4 audio only files - mp4 videos are fine.
AvPlayer CAN play mp4 files, but not if they are encoded as AMR_NB they need to be encoded as AAC.
Related
I want to turn an ogg-audio file together with a jpeg-File into a video with a single frame, so that youtube will accept this as a valid upload. How can I accomplish this with VLC?
I need to play 3gp, FLV, avi Video file format in my application.
I had searched lot about it.
Got some library like "FFmpeg" Library. But could not find any sample code for it.
Any other ways for it are also appreciated.
Does any body have done it before?
I am even not sure that if it is possible or not in iOS.
Please give me solution for it.
UPDATE :
I tried one 3gp Video in my AVquePlaye but it is not play in my code,
While i use same Video in WhatsApp in my iPhone, Surprisingly video is playing there.
I found out that playing 3gp in the SIMULATOR does not work (because on my mac it uses QuickTime which does not support 3gp, I guess).
When I run my app on a real device, it CAN play 3gp video, using the default video player. So be warned ;)
We're building an iPhone game using PhoneGap.
iOS devices support many audio formats, and we are thinking about using .mp3 or .caf files for the sound effects.
Does it matter which audio format is used? What are the differences between using one versus another?
CAF for Sound Effects
MP3 for soundtracks (mp3 files can't be loop, it has a small pause in between)
I'm trying to cache srt files and play them with mp4 video files using AVFoundation AVPlayer.
Streaming works fine with webVTT subtitles but I also need to cache videos and subtitles.
I was wondering if this is even possible or a possible workaround exists?
Thanks in advance.
I am trying to capture video from iPhone camera and save the movie mixed with an audio file.
I can capture the video with the audio (from mic) with no problems. What I want to do is capture the video but instead of mic audio, use a music track (a .caf file).
I am capturing the video with AVAssetWriter. I've tried to set up an AVAssetReader to read the audio file, but I couldn't make it work with the AVAssetWriter (maybe because the decoding of audio happens real fast).
Also, I don't want to save the movie without audio and mix it afterwards with an AVAssetExportSession. It would be to slow for my purpose.
Any Ideas ? Thanks in advance.
Capture the video using AVAssetWriter, Capture audio lets say with AvAudioRecorder , then mix audio and video using AVExportSession , lots of posts on this topic.
If you do it after (with AVAssetExportSession) , you will problem with the sync. and short delay (time...) between the video and the audio...didn't find better solution