Recommendations for DAI
Important
The Recommendations for Live should be followed first.
Preparing your media for OTT delivery is important to achieve efficiency and quality of experience.
Media alignment at splice boundaries
We recommend alignment between audio and video fragments, constant fragment durations and efficient encoding (one GOP per fragment). This will optimize the media for streaming delivery, in terms of bandwidth usage, manifest sizes and for clipping and archiving of the content.
However, the introduction of SCTE 35 markers and additional IDR frames can have an impact on the alignment of your output. This is due to the fact AVC video (with a framerate of 25 FPS) & AAC audio (with a sample rate of 48kHz) only fully align at a 0,32s interval. If the SCTE marker does not match this interval (which is often won't) the resulting audio and video duration will not be fully aligned. The same issue can also occur with other framerates (such as 23.97, 24, 30) resulting in a different alignment interval.
Whilst normally this has no impact on quality of experience, it should be noted that poor quality of experience can occur (depending upon content, platform, and player behavior).
One example would be any large change in audio level between main program and advertisement at splice points. Therefore it is recommended to review content creation guidelines and test your content before deploying in production.
Unified Origin requirements
The following requirements are separated into two sections. Ingress relates to the formatting, structure, and method of delivery to Packager or Origin, to ensure data is processed as efficiently as possible. The 'ingress' requirements apply to the encoding platform generating the SCTE 35 message and stream. Egress relates to options configured within for Packager or Origin to ensure successful delivery to the Ad Insertion Service.
Ingress
Received as event messages (contained in a fMP4 track) OR Cablelabs ESAM (XML contained in an
mdat
inside a fMP4 container)Received ahead of the desired presentation. At least 2x ahead of the target fragment length. If this is not available time shift can be used to delay the presentation live edge, allowing for correct calculation of segment duration.
Received as a metadata separate track, preferably based on ISO/IEC 23001-18
Each message received must have a corresponding IDR frame for at each timestamp that is signaled in a SCTE 35 message.
When Inserting an IDR frame the encoder should not shorten or lengthen any of the media segments but keep the original length intact.
When multiple segmentation descriptors are contained in a single SCTE 35 message, the duration of the event that contains the SCTE 35 message data should be equal to the longest duration signaled across the different segmentation descriptors.
Ensure
urn:scte:scte35:2013:bin
is used when delivering event messages.
Attention
In accordance with DVB-DASH, SCTE 35 ad insertion opportunities in a VOD
stream must signal a break duration of 0
(otherwise they’ll be interpreted
as a replacement opportunity and signaled in the client manifest as such).
As the value for the PLANNED-DURATION attribute in the HLS EXT-X-DATERANGE tag
for a splicing opportunity is taken from the break duration specified in the
SCTE 35 message, this means that signaling a PLANNED-DURATION other than 0
is not possible for an ad insertion opportunity.
Egress
Always set
--hls.minimum_fragment_length
and--mpd.minimum_fragment_length
equal to or at multiple of the GOP--dvr_window_length
is shorter than--archive_length
to mitigate fragment length changes when transitioning from between dvr windows.Only splice_insert() OR time_signal() messages can be acted upon, not both.
Important configurable options
--timed_metadata
(Packager and Origin)--splice_media
(Packager and Origin)--time_signal
(Packager and Origin)--[hls|mpd].minimum_fragment_length
(Origin only)--mpd.segment_template=[time|number]
(Origin only)
When only --splice_media
is used, Packager or Origin may slice a media
segment (at the times specified by the splice_insert() message).
When both --splice_media
and --time_signal
are used, splice_insert()
messages will be ignored and time_signal() messages will be used instead. When
relying on time_signal() messages make sure that specify the types of messages
that Origin needs to act on.
This results in the following (example):
Option A - splice_insert()
--timed_metadata --splice_media
Option B - time_signal()
--timed_metadata --splice_media --time_signal=34,35
Note
It is not possible to use a query parameter to filter out the timed
metadata track, or to disable it. If the stream ingested by Origin contains
SCTE 35 messages you can either enable pass through using the
--timed_metadata
option when creating the server manifest, or disable it
by not specifying it.
Must Fix: receive SCTE markers 2x ahead
SCTE markers are received by the Origin ahead of the desired presentation. At least 2x ahead of the target fragment length. If this is not possible, time shift can be used to delay the presentation live edge allowing time for stream conditioning. [Example]
Must Fix: set hls.minimum_fragment_length
and mpd.minimum_fragment_length
Always set --hls.minimum_fragment_length
and
--mpd.minimum_fragment_length
equal to or at multiple of the GOP.
Must Fix: set mpd_segment_template
Should mpd_minimum_fragment_length
be set ensure mpd_segment_template
is also set to equal either time
or number
.
Must Fix: set dvr_window_length
dvr_window_length should always be set to a duration greater than the longest duration advertisement.
SCTE 35 test streams
The test streams available are the following:
Learn more
Check our tutorial on Getting Started with Live.
Read our Unified Origin - DAI documentation.
Read our How to do SCTE 35-based Dynamic Ad Insertion for Live streaming with Unified Origin blog.