Flussonic Media Server documentation


Ad Insertion Markers

The dynamic ad insertion (DAI) technique is used for adding commercials into linear live streams, such as TV broadcasts. A regional TV provider can, by using DAI, embed "local" advertising into a broadcast.

The dynamic ad insertion method uses ad insertion markers to prepare a stream for ad insertion. Markers are stream's metadata that signals about the ad insertion event. This event means that you can embed a commercial of a certain duration in a certain place in a video stream. This place (a cue splice point) in a stream allows smooth switching to another stream (such as a commercial) and back to the main video.

Ad insertion markers are created according to various standards, the most popular standard is SCTE-35. Technically, they are tags in a client manifest, that is why markers must be added for each video transmission protocol (adaptive sreaming). Flussonic can do that.

Flussonic works with markers in the SCTE-35 format and recognizes the metadata about the splice_insert events.

Use case: You need to read the SCTE-35 markers in a transport stream and convert them to a format suitable for broadcasting via HLS. Flussonic can detect markers in the ingested stream, convert them to a specified format, and automatically add them to a client manifest.

Flussonic can work with the following marker formats in streams of different types:

  • HLS — markers in formats: SCTE-35, AWS (learn more in AWS Documentation), or simple cue-in and cue-out markers.
  • MPEG-TS — markers in formats: SCTE-35.

About converting ad insertion markers with Flussonic

Flussonic can convert ad insertion markers that come with an input stream into another format for usage in the output stream:

  • from MPEG-TS SCTE-35 to HLS AWS
  • from MPEG-TS SCTE-35 to HLS SCTE-35
  • from HLS cue markers, SCTE-35 or AWS to HLS AWS or HLS SCTE-35
  • from HLS cue markers, SCTE-35 or AWS to MPEG-TS SCTE-35

For incoming MPEG-TS streams, which come with markers in SCTE-35, you can specify that Flussonic should convert markers to AWS or SCTE-35 when a stream is accessed over HLS. Then, when the stream is accessed via HLS, it will contain markers in the specified format (AWS or SCTE-35).

Similarly, for incoming HLS streams, their markers can be converted to SCTE-35 or AWS for output streams accessed via HLS. For accessing this stream via MPEG-TS, markers can be converted to SCTE-35.

You can enable the processing of markers on the incoming stream and specify the required format of markers for the output stream. This can be done by editing stream settings.

Setting up conversion of ad insertion markers

First, you should enable the processing of ad insertion markers, and then you can specify which format of the markers you want to have in the stream when it's played back (output stream).

Reading markers in the input stream

To turn on processing of markers, add one of the options to the streams's URL:

  • scte35=true — turns on the processing of SСTE-35 markers in an MPEG-TS stream.

  • ad=true — turns on the processing of ad markers in an HLS stream (these can be simple cue markers or AWS markers).


url tshttp://FLUSSONIC-IP/STREAM_NAME scte35=true;

Flussonic will detect SСTE-35 markers in the input MPEG-TS stream.

Conversion of markers

Now you can specify the format of markers for output HLS streams. To do so, add the directive hls_scte35 into the input stream settings.

Note. For MPEG-TS, the output markers are the same as on the input (SCTE-35), so this directive makes sense only for HLS output.


hls_scte35 aws|scte35|false;

where: aws — ad markers in the AWS format for HLS output, scte35 — ad markers in the SСTE-35 format for HLS output, false — do not include markers into the output stream.


hls_scte35 scte35;

Flussonic will add markers in the SСTE-35 format to the output HLS stream.

Two-part example

In this example we:

  1. Get SСTE-35 markers from MPEG-TS
  2. Convert them to HLS AWS markers for use in output HLS streams.

Getting MPEG-TS SСTE-35 markers (scte35=true), preparing markers in AWS for this stream transmitted via HLS (hls_scte35 aws):

stream CTC {
    url tshttp://STREAMER:8080/ctcmosto/mpegts scte35=true;
    hls_scte35 aws;

Now when you access this stream via HLS, it will contain ad markers in the AWS format.

Let's access the resulting local stream via HLS, detect markers in it and specify the possibility to get these markers in the SCTE-35 format in output HLS streams:

stream CTCHLS {
    url hls://localhost/CTC/mono.m3u8 ad=true;
    hls_scte35 scte35;