Skip to content
This repository has been archived by the owner on Oct 20, 2022. It is now read-only.

handling of MSS Live Stream with duration #236

Closed
IcoDeveloper opened this issue May 2, 2018 · 1 comment
Closed

handling of MSS Live Stream with duration #236

IcoDeveloper opened this issue May 2, 2018 · 1 comment

Comments

@IcoDeveloper
Copy link
Contributor

IcoDeveloper commented May 2, 2018

MSS Live Streams with duration specified in the manifest are special-cased as "startOver" stream(s).

  • mediaPlayer.isLive returns false
  • DVRWindowRange / DVRWindowSize don't returnn values
  • if paused/skipped back, fragementInfo requests are only sent until duration has been reached
  • DVRWindow is assumed to cover full duration.

I think this opens room for some errors:
To my knowledge, the "duration" for a live stream is meant as an estimate to , for example, allow players to scale a timeline control. It is not actually a hard limit for the duration of the stream, nor does it imply a DVR Window size.

<SmoothStreamingMedia MajorVersion="2" MinorVersion="2" Duration="3000000000" TimeScale="10000000" IsLive="TRUE" LookAheadFragmentCount="2" DVRWindowLength="0" CanSeek="TRUE" CanPause="TRUE">
<StreamIndex Type="video" Name="video" Subtype="H264" Chunks="0" TimeScale="10000000" Url="Events(2018_4_3_9_2_32)/QualityLevels({bitrate})/Fragments(video={start time})">
<QualityLevel Index="0" Bitrate="1000000" CodecPrivateData="00000001674D401F9656020024DFF82000200284000003000400000300C9810003D090001E849FC638C08001E848000F424FE31C3B4244A70000000168EA5352" FourCC="H264" MaxWidth="1024" MaxHeight="576" />
<c t="0" d="20073555" />
<c d="20000000" r="413" />

This manifest has an estimated duration of 5 minutes, an actual duration of ~13 minutes and a DVR Window covering the whole event.

<SmoothStreamingMedia MajorVersion="2" MinorVersion="2" Duration="36000000000" TimeScale="10000000" IsLive="TRUE" LookAheadFragmentCount="2" DVRWindowLength="3000000000" CanSeek="TRUE" CanPause="TRUE">
<StreamIndex Type="video" Name="video" Subtype="H264" Chunks="0" TimeScale="10000000" Url="Events(2018_4_3_9_2_32)/QualityLevels({bitrate})/Fragments(video={start time})">
<QualityLevel Index="0" Bitrate="1000000" CodecPrivateData="00000001674D401F9656020024DFF82000200284000003000400000300C9810003D090001E849FC638C08001E848000F424FE31C3B4244A70000000168EA5352" FourCC="H264" MaxWidth="1024" MaxHeight="576" />
<c d="20000000" r="150" t="620124323" />
</StreamIndex>

This one has an estimated duration of 60 minutes, current duration ~6 minutes and a DVR Window of 5 Minutes, so first 62 seconds are no longer accessible.

I'm really not sure how to properly handle this, but my feeling is that trying to treat live streams w/ duration as static is just not a good fit.

continuing fragemntinfo requests when hitting the estimated duration would make things better, but still wouldn't cover DVRWindowSize smaller than estimated duration.

@bbert
Copy link

bbert commented May 7, 2018

Hi,
Yes, we made the choice to consider start-over streams as 'static' streams with progressive duration.
One reason was to enable 'ended' event to be raised at end of content.
It seems not to be easy to be compatible with all use cases and encoders.
If you have any official specification about MSS start-over streams, please let us know.
Also if you have any suggestion to improve support for start-over streams, please do not hesitate.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants