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

Feature request: Custom variables #13

Open
kont-ta-prova opened this issue Oct 16, 2023 · 2 comments
Open

Feature request: Custom variables #13

kont-ta-prova opened this issue Oct 16, 2023 · 2 comments

Comments

@kont-ta-prova
Copy link

kont-ta-prova commented Oct 16, 2023

Hi,

Can you add an option to provide formats which are not present in the original mpd?

For example:

If for example, from I want to download "$RepresentationID$" called VIDEO1 and from I want to download "$RepresentationID$" called AUDIO1 which are not present in the MPD, would it be possible to override the variables in the mpd?

For example the MPD might offer a lower quality version of video and audio, but the server still has a higher quality version available which is hidden (due to geo locks) but still accessible.

I'm thinking of such an option:

dash-mpd-cli --override "AdaptationSet=1 RepresentationID=VIDEO1" --override "AdaptationSet=2 RepresentationID=AUDIO1" [url]

@emarsden
Copy link
Owner

Thanks for the suggestion.

I will think about whether to implement something along the lines of what you suggest, which is quite a narrow functionality, or whether it would be better to implement a more general "MPD rewriting" functionality using rules for XML tree rewrites.

@emarsden
Copy link
Owner

emarsden commented Nov 8, 2023

There is a preliminary implementation of an MPD rewriting functionality in the latest release. This uses XSLT stylesheets, which are very powerful though certainly less intuitive than the syntax you are proposing. There is a sample stylesheet that does some rewriting similar to what your example does at test/fixtures/rewrite-resolution.xslt.

https://github.com/emarsden/dash-mpd-cli/blob/main/tests/fixtures/rewrite-resolution.xslt

I hope that helps, but will leave this issue open to keep in mind the simpler (but not very general) API you proposed.

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

No branches or pull requests

2 participants