How to MPEG-DASH video streaming in iOS?

14,511

Solution 1

  1. You can’t.

  2. Yes they use HLS. iOS 10 and above support fmp4 in HLS. so the only difference between dash and hls is the manifest.

Solution 2

Try providing both HLS and DASH containers and let media queries choose the appropriate one.

Share:
14,511

Related videos on Youtube

user2986042
Author by

user2986042

Updated on June 04, 2022

Comments

  • user2986042
    user2986042 almost 2 years

    I am trying to write a JavaScript-based implementation of MPEG-DASH for video streaming. I have referenced the following documents:

    These libraries are using MSE (Media Source Extensions).

    My understanding

    MPEG-DASH is an international standard for streaming video, but it is currently not natively supported in iOS devices. In other browsers and devices, it requires a JavaScript library or a video player that supports MPEG-DASH (eg: Dash.Js, Shaka player).

    And another streaming technology is HLS. It is an adaptive streaming communications protocol created by Apple. The Safari browser can play HLS streams within a web page, iPhone, and iPod touch devices.

    Here, we can see that MPEG-DASH (because of MSE) is currently not natively supported in iOS devices.

    Now, my doubts:

    1. How can we stream MPEG-DASH videos in iOS without MSE?
    2. How Facebook and other streaming media services play their videos? is it with HLS only ?

    Any suggestion/explanations would be more than helpful!

  • Ryan
    Ryan about 5 years
    Is this still true? viblast.com/player claims "You are looking at one of the very few existing solutions that tackle DASH playback in iOS."
  • szatmary
    szatmary about 5 years
    Is still true-ish. It may be possible to convert a mpd to m3u8 in a service worker now. Not sure.
  • brasofilo
    brasofilo almost 5 years
    Hi Cary, if you need clarification about the question, you should post a comment below the question. Answers should provide a solution to the problem presented. I took the liberty of changing the wording of your answer so it's more "answer-like" than "comment-like"
  • Ray Foss
    Ray Foss about 3 years
    @szatmary Is this really all there is to it? there is no difference in the fragments when using Mp4/AV1?
  • szatmary
    szatmary about 3 years
    @RayFoss iOS will not play AV1. It will only play AVC and HEVC.
  • Ray Foss
    Ray Foss about 3 years
    @szatmary Yesterday they merged AVIF support into WebKit, which is AV1... AV1 video is coming soon to newer devices. My question was about what it would take to convert a library of DASH H.264 format videos into HLS... is it just a single file of metadata?
  • szatmary
    szatmary about 3 years
    @RayFoss AVIF does not mean AV1 is coming soon. Decoding one AV1 frame to display on a web page is one thing. But decoding 60 per second for video is totally different. The WebKit team at Apple is NOT the HLS team. Apple will not support AV1 in HLS until the iPhone has a hardware decoder.
  • szatmary
    szatmary about 3 years
    @RayFoss To answer you question for DASH H.264 to HLS, Yes, just make an m3u8 that points to each fmp4 file, and put the init fragment in the #EXT-X-MAP
  • Ray Foss
    Ray Foss about 3 years
    @szatmary thank's for the answer! The iOS based Apple TV will have 4K playback support and the old one has been getting a lot of hate in the media. The M1 is already capable of handling AV1 decoding at low bitrate 4k. Apple knows how to squeeze it's 8-wide decode block and GPU's. anandtech.com/show/16226/apple-silicon-m1-a14-deep-dive/2
  • szatmary
    szatmary about 3 years
    @RayFoss Apple TV can decode pretty much anything in software. But that's because it has a power cord that plugs into the wall. The Phone which is expected to have good battery life will be the blocker for adoption in HLS. Decoding AV1 is not a massively parallel problem, The standard GPU wont cut it. It needs dedicated hardware primitives. This is why QuickSync / NVENC / VideoToolBox all exist. Also the M1 Pulls 40 Watts (which is very impressive) But the A14 pulls ten times less!