开发者

Is it possible to create a .m3u8 playlist of playlists for the iPhone

开发者 https://www.devze.com 2023-02-12 15:43 出处:网络
I am looking to stream to the iPhone using a .m3u8 playlist for a case that is a VOD.The use case is streaming a movie using a .m3u8 playlist.

I am looking to stream to the iPhone using a .m3u8 playlist for a case that is a VOD. The use case is streaming a movie using a .m3u8 playlist.

Each segment in the playlist is 10 seconds long and so for a 1h and 30 minute movis this would mean 90 mins * 6 segments/minute = 540 segments. To me, this seems like a lot to add to one .m3u8 playlist.

With this said, I was wondering if there is a way and whether it's supported by the iPhone to create a .m3u8 playl开发者_StackOverflow中文版ist that contains another playlist. So the format would be something of the form:

#EXTM3U
#EXT-X-TARGETDURATION:5220
#EXTINF:5220,
http://media.example.com/entire.ts
#EXTINF:5221,
http://media.example.com/therest.m3u8
#EXT-X-ENDLIST

So my questions are: is there a way to do the aforementioned? And if not, what's the maximum size or length of a .m3u8 file.

Note that I checked the following:

https://datatracker.ietf.org/doc/html/draft-pantos-http-live-streaming-05

http://developer.apple.com/library/ios/#documentation/NetworkingInternet/Conceptual/StreamingMediaGuide/Introduction/Introduction.html

and did not find the answers.


There is easy way to create the m3u8 playlist on a mac.

I used this tool called one click m3u8 from the mac App store.

The steps are simple.

  1. Select the input video file
  2. Select where you want m3u8 to be created.
  3. Select the options, gears etc.,
  4. Click create.

The .m3u8 and .ts files are created and ready to deploy


I have tried something like you and this is what mediastreamvalidator says:

    ERROR: Invalid media segment: The validator helper exited due to a fatal error: failed to create format reader: [errno: -12847] format reader file not recognized.
21:    videos/high.m3u8

Also when tested on iphone it stopped when reaching the m3u8 (which was the last "segment") and that the video length was not correct (obviously).

You can create a playlist of playlists (which is usually called "variant" playlist) but this is for bandwidth issues.

Anyways, you can use "mediafilesegmenter" which segments and creates the playlist for you. No need to create the playlist yourself.

0

精彩评论

暂无评论...
验证码 换一张
取 消