How Does the SMIL seq Element Work?

The <seq> (sequence) timing container in Synchronized Multimedia Integration Language (SMIL) defines a timeline where child elements play strictly one after another in chronological order. Unlike parallel containers that trigger simultaneous playback, the <seq> element establishes automatic temporal dependencies between siblings, advancing playback only after each preceding item concludes. Understanding how SMIL manages implicit start times, active durations, and end conditions within a <seq> container is fundamental for creating structured multimedia playlists and presentations.

Core Mechanics of Sequential Playback

At its foundation, <seq> coordinates the playback flow by evaluating the completion of each nested element. The first child element begins playing immediately when the parent <seq> container becomes active, unless an explicit delay is configured.

Each subsequent child element’s implicit start time is tied directly to the active end of the element immediately preceding it. Once the current media element finishes its active duration—whether through intrinsic file duration or explicit SMIL timing attributes—the SMIL timing engine resolves the next sibling's start condition and initiates its playback.

Implicit vs. Explicit Start Times

In a standard parallel container (<par>), child elements without explicit timing start at time zero relative to the container. Within a <seq> container, the default timing semantics change:

Handling Element Duration and container End

The total duration of a <seq> container is determined by the cumulative sum of the active durations of all its children, including any explicit delays between them.

Several key timing attributes influence how the sequence completes: