1

I need a to display a low latency (less than 5 seconds) video stream in my HTML5 app. The app is running in a webkit webview on iOS (not mobile Safari). I have explored and eliminated the below options.

Are there any options out there for displaying a low latency video stream in a webview?

WebRTC: JS API not implemented in webview (although now supported in mobile safari)

RTMP: Flash players not supported in webview

RTSP: Not supported on iOS even when tunneled through websockets (Streamedian).

HLS and/or DASH: Latency is too high

cdanzig
  • 11
  • 1
  • Beware: WebRTC is supported in Webviews. getUserMedia, i.e. access to camera is not. – Philipp Hancke Jun 07 '19 at 15:32
  • @PhilippHancke Is RTCPeerConnection implemented in the webview? – cdanzig Jun 07 '19 at 15:47
  • 1
    If only stupid apple would support media source extensions in iphone safari, this would be easy: https://stackoverflow.com/questions/54186634/sending-periodic-metadata-in-fragmented-live-mp4-stream – El Sampsa Dec 11 '19 at 15:57

1 Answers1

1

I've been working on a project that allows low latency HLS with any normal player all the way back in 2016 for that specific reason - no support for this from at that point any of the native players.

In HLS is actually quite easy to go quite low on latency, but it does require a server working in a bit different way than a normal file server - it should present the chunks on the playlist before they appear and wait until they show up when they're requested.

I have decided to open source my efforts so you can try this here: github.com:signicode/ahead-server.

There are things to be done, so all the help is welcome.

Michał Karpacki
  • 2,588
  • 21
  • 34