Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Direct download in mapped-mode with multi-sequence playlists #673

Closed
benweidig opened this issue Aug 15, 2017 · 2 comments
Closed

Direct download in mapped-mode with multi-sequence playlists #673

benweidig opened this issue Aug 15, 2017 · 2 comments

Comments

@benweidig
Copy link

Hi,
we're using the module in mapped mode for HLS streaming, and it's great.
But we also need to support legacy clients with direct MP4 delivery.

Our setup:

  • another location with "vod none;"
  • Requesting playlist with "http://.../direct/playlist.json"

If the playlist contains only one sequence it works, but we have multiple sequences...
How can we select the correct sequence of the playlist? We tried to give the sequences the property id, but how do we supply it with the URL?

Is it even possible to download a single playlist sequence from a multi-sequence playlist?

We're getting "ngx_http_vod_map_media_set_apply: unsupported - non-trivial mapping in progressive download", which is understandable, the module just don't know how to select the correct sequence.

If not possible we think about generating additional single-sequence-playlists for direct delivery.

Thx!

@erankor
Copy link
Contributor

erankor commented Aug 15, 2017

There are URL parameters for selecting a sequence (by index - -f1, or by id -s<id>), but unfortunately, it won't work for progressive download, since the file name part of the URL isn't parsed in this case.
In HLS, for example, you could pass index-f1.m3u8 to get the index playlist of the first sequence.
In progressive, the file name can be whatever you want, so nginx-vod-module doesn't parse it.
The only way to do it is to return a JSON with a single sequence.
In our setup, other than complex cases (e.g. playlist) we always return a single MP4 in the JSON, and we combine several of these JSON using urlset to achieve adaptive streaming.

@benweidig
Copy link
Author

Thx for the explanation.

Too bad the URL parameters aren't supported in progressive downloads.

We''ll give the "many many playlists" route a try, that looks easier in our case compared to URL-sets.

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

No branches or pull requests

2 participants