DashManifestParser

Parses a DASH MPD into a DashManifest.

Functions

Link copied to clipboard
fun parse(xml: String, manifestUrl: String, policy: DashUrlPolicy = DashUrlPolicy.Default): DashManifest

Parses xml fetched from manifestUrl; the URL anchors every relative BaseURL, and policy decides what the manifest is allowed to point at. A document longer than 8 Mi characters, with more than 262,144 elements or 1,048,576 attributes, or with an element that carries more than 128 attributes, is refused with io.github.yuroyami.kiteplayer.network.xml.XmlException.

Link copied to clipboard
fun segmentPlan(manifest: DashManifest, period: DashPeriod, representation: DashRepresentation, policy: DashUrlPolicy = DashUrlPolicy.Default): DashSegmentPlan

The fetch plan for representation inside period: template substitution with $RepresentationID$, $Number$ (its %0Nd width form included), $Bandwidth$, $Time$ and $$, counted from the timeline when one speaks and from the period (or presentation) duration otherwise. An explicit SegmentList wins over any template.