I'm looking for a way to get a local file:/// url or a byte stream of audio data for a selected audio file using MPMediPickerController/MPMediaItem.
Anyone know if this is possible? So far it seems impossible based on the documentation I'm reading for MediaPlayer framework.
MPMediaItems raw song data
I am struck with the same problem. Please try the above link and let me know if that worked for you.
Related
I would like to ask you for help with HLS stream.
I would like to stream video in swift but problem is the format of downloaded file. I download m3u file from resource and there are links like:
http://192.168.2.100:8003/1:0:1:13F1:C87:3:EB0000:0:0:0:
Is it possible to play link like that or do I have to create an m3u8 file with link and then play it?
The stream is from enigma2 box.
Thank you and have a nice day.
The file name doesn't matter as long as the server returns the correct Content-Type http header.
I am writing audio content to a m4a file with ExtAudioFileWriteAsync and it is working perfectly. However, I would also like to add meta data to the exported file.
Is this at all possible? If so, how?
Any help would be much appreciated.
I ended up doing it with AVAssetExportSession, loaded the file I am trying to edit into an AVURLAsset, adding the metadata to the export session, then saving the export.
I have a case where i need to get audio out from video file. Is this possible in iOS ??
I need only the output file as an audio any type. I have the video file in my documents directory which I record earlier in application.
1.Convert Video Reverse
2.Extract audio from a video file
3.Add Audio & Video Together
Download Code From Here
may be helpful to you.
Yes, it can be done. See Extract audio from video file for ideas.
Extracting is probably the more accurate term.
I want to read a pdf file which is coming in URl from server. I am not using UIWebview.
So, i just want to know that is there any way to view that pdf file without downloading in to device. Just it be readable or buffered, not stored.
Any suggestions for that.
The easiest way to show a PDF outside of a UIWebView is using the QuickLook framework:
http://developer.apple.com/library/ios/#documentation/FileManagement/Conceptual/DocumentInteraction_TopicsForIOS/Articles/UsingtheQuickLookFramework.html
However, as isn't unreasonable, Quicklook requires URLs of a "file" type.
So without using a UIWebView, you'll need to add your own code to download/cache/display, which isn't hard. If you need sample code, let me know.
I have downloaded a mp3 file from a server successfully, but the problem I encountered is, I don't know how to play that file.. Should I use AVAudioPlayer or AudioQueue to play the file?? I will be appreciate if you could post some sample code here.
Both AVAudioPlayer and the Audio Queue API can be used to play MP3 files. The AVAudioPlayer is well documented and has a lot of sample code available. So why not give it try first and if that does not work, post a more specific question here.