ZippyCastJournal
← All articles

Streaming explained

Reading SegmentBase and SegmentList in a DASH MPD

A practical guide to how MPEG-DASH MPD files point at media segments through SegmentBase, SegmentList and SegmentTemplate, and how to read them in ZippyCast.

Why the segment description matters

An MPEG-DASH MPD is an XML document that tells a player where the pieces of a stream live. MDN describes the MPD as holding information on the various streams and the bandwidths they are associated with, including metadata such as mimeType and codecs, and details such as byte ranges. The part that decides how a player actually fetches media is the segment description inside each Representation.

When a channel in ZippyCast stalls, fails to start, or seeks badly, the segment description is one of the first things worth inspecting. It tells you whether the player is expected to request whole files, byte ranges inside a single file, or a numbered list of separate segment URLs. Those three shapes fail in different ways, so recognising which one you are looking at narrows the diagnosis quickly.

SegmentBase: one file, byte ranges

SegmentBase appears in the MDN example of a live-profile MPD. Inside it, an Initialization element carries a sourceURL pointing at the first segment and a range attribute such as 0-862. That range marks the bytes of the initialisation data, the part a player must read before it can decode anything.

The practical consequence is that the media is not split into many files. The player fetches the initialisation bytes, then requests further byte ranges of the same resource as playback advances. If a stream described this way starts and then freezes, the interesting question is whether the server honours range requests reliably. MDN notes that range-request support is one reason to choose the LIVE profile over the on-demand profile, which is a useful hint about how much a stream depends on that behaviour.

SegmentList: an explicit list of URLs

SegmentList takes the opposite approach. In the same MDN example, each Representation contains a SegmentBase with an Initialization sourceURL and range, followed by a SegmentList with a duration attribute and a series of SegmentURL entries. Each SegmentURL names a media file and a mediaRange, for example media="main/news100/2.m4s" with mediaRange="863-7113".

This is the most readable form of segment description because every segment is spelled out. If a channel fails partway through, you can see whether the list is short, whether the URLs point into folders that look consistent with the BaseURL, and whether the ranges are contiguous. A gap or an obviously truncated list is a strong signal that the MPD itself, rather than the player, is the problem.

SegmentTemplate and the numbered-folder layout

MDN also shows the file layout that commonly accompanies template-style addressing: a playlist such as /segments/news.mp4.mpd, a main segment folder, and per-bitrate folders named for their bandwidth, each containing numbered files like 1.m4s, 2.m4s, 3.m4s. The MPD then explicitly lists where the various bitrate files reside.

When you see this structure, the segment description is effectively a pattern rather than a list. That makes the folder naming the thing to check. If the MPD refers to a bitrate folder that does not exist, or the numbering starts somewhere unexpected, playback will fail even though the MPD parses cleanly. Because ZippyCast is an empty-shell player that fetches streams directly from your provider, this kind of mismatch is a provider-side packaging issue, not something the player can repair.

Initialisation data and startup

Across all three shapes, the Initialization element recurs. It identifies the resource and byte range holding the setup data a decoder needs before the first frame. MDN's on-demand example instead uses a BaseURL per Representation pointing at a .dash file, which serves a similar purpose in a different packaging style.

For troubleshooting, the useful rule is simple: if a stream never produces a picture at all, suspect the initialisation reference. If it starts and then degrades, suspect the segment list or the range handling. That split saves time before you escalate to your provider.

A short inspection routine

Open the MPD and find a single Representation. Note whether it contains SegmentBase, SegmentList, or neither because a template is used. Check that any Initialization sourceURL resolves against the MPD's BaseURL. Then check that the media references, whether ranges or URLs, form an unbroken sequence.

Finally, compare what you see with what actually happens in ZippyCast. A stream that plays but will not seek points at range or list problems; a stream that never starts points at initialisation or at the provider's server. ZippyCast supplies no content of its own, so anything you find in the MPD belongs to the provider whose credentials you entered, and the fix belongs with them.

Make yourself at home.

Try ZippyCast with your own authorized IPTV provider.

Open ZippyCast →