Introduction
Latency is the time lag between the when something is recorded in real life and when it is seen in a video player. There is, of course, some real time required to transmit a signal from the source through the internet to a viewers player. Latency is aggravated by the fact that online video is transmitted in discreet chunks, called segments.
Latency can be reduced by shortening the length of the video segments, and the following sections will detail how you can do this. Be aware, however, that there is a tradeoff: to insure uninterrupted playback, the player downloads a few video segments ahead of the current playback position (this is called buffering), so that they are ready when needed. If you shorten the length of segments, the player will be pre-fetching less video data, and chances of playback pausing while the player buffers additional segments will be increased.
Requirements
The following player versions support Low Latency HLS with live streams:
- Brightcove Player (web) release 6.62.0 and newer
- Native SDK for iOS release 6.10.3 and newer
- Native SDK for Android release 7.0.1 and newer
Additional limitations
The following limitations apply to Live streams using reduced latency:
- SSAI is not supported
- DRM is not supported
- The DVR window must be less than 5 minutes
- No more than 4 renditions
Creating Reduced Latency Live Profile
To reduce latency, you will need to create a custom Live profile. Follow the steps below:
- Login to Studio
- Go to Admin > Ingest Profiles:
Go to Ingest Profiles - Select one of the Live ingest profiles with no more than 4 renditions:
Select a Live Profile - Click on the link to open the profile
- Click on the Duplicate button to create a new profile based on this one
- In the new profile, change the
name
to "Low Latency Profile" (or whatever you want to call it) - For each of the
renditions
, change thesegment_seconds
to2
to reduce the length of the segments to 2 seconds - Your whole profile should look something like this:
{ "model_version": 1, "name": "Low Latency Profile", "description": "Deliver high-quality renditions to maximize quality for desktop and OTT.", "account_id": "57838016001", "renditions": [ { "media_type": "video", "format": "ts", "segment_seconds": 2, "label": "hls1080p", "live_stream": true, "video_codec": "h264", "video_bitrate": 4000, "keyframe_interval": 60, "width": 1920, "height": 1080, "h264_profile": "high" }, { "media_type": "video", "format": "ts", "segment_seconds": 2, "label": "hls720p", "live_stream": true, "video_codec": "h264", "video_bitrate": 2400, "keyframe_interval": 60, "width": 1280, "height": 720, "h264_profile": "high" }, { "media_type": "video", "format": "ts", "segment_seconds": 2, "label": "hls540p", "live_stream": true, "video_codec": "h264", "video_bitrate": 1700, "keyframe_interval": 60, "width": 960, "height": 540, "h264_profile": "main" }, { "media_type": "video", "format": "ts", "segment_seconds": 2, "label": "hls360p", "live_stream": true, "video_codec": "h264", "video_bitrate": 900, "keyframe_interval": 60, "width": 640, "height": 360, "h264_profile": "main" } ], "packages": [] }
- To use this profile, select when you create a new Live Event in the Live module:
Create Live Event
Using the Live API
If you want reduced latency, and you use the Live API to create your live jobs, just create the job as you normally do, but include no more than 4 renditions, and set segment_seconds
for each rendition to 2
. Also, make sure that observe the other limitations listed in the Introduction.