Overview

Preview
Stream live video into Lattice with the Video Manager API.

The Lattice Video API manages the lifecycle of live video streams in the Lattice common operational picture (COP). Use it to register an ingress source, attach the stream to an asset entity, and list, retrieve, or stop streams as your scene evolves.

Concepts

IngressStream object

An IngressStream message represents a single live stream and carries the following fields:

ingress_id
string

Unique stream identifier returned by CreateIngressStream. Supply your own value at creation time, or let the server generate one.

title
string

Human-readable label for the stream, set at creation.

status
StreamStatus

Current lifecycle state of the stream. See Stream lifecycle for the full set of values.

created_at
Timestamp

Time the stream was registered.

updated_at
Timestamp

Time the stream’s status was last changed.

egress_ids
repeated string

Identifiers of any active egress streams that re-publish this stream downstream.

ingress
oneof

Holds an MpegTsIngress, RtspIngress or SrtIngress describing how Lattice receives frames.

Stream lifecycle

A stream moves through the following statuses during its lifetime:

1

STREAM_STATUS_LIVE

The upstream source is actively publishing frames.

2

STREAM_STATUS_INACTIVE

The stream exists but has not received frames recently (more than 10 seconds with no input) or the source has stopped publishing.

3

STREAM_STATUS_UNAVAILABLE

The stream exists but its current status is unknown — typically the initial state before Lattice has observed the stream, or returned when querying the stream status fails.

4

STREAM_STATUS_ARCHIVED

The stream has been stopped and the record is preserved for later retrieval through GetIngressStream.

Entity association

Attach a stream to a Lattice asset entity through the entity’s media.media[] field. Set a MediaItem with type = MEDIA_TYPE_VIDEO and its identifier set to the stream’s ingress_id, then call OverrideEntity with field_path = ["media.media"] to apply the change without disturbing other components.

Deprecated association field

The legacy VideoAssociation message on the stream and CreateIngressStreamRequest is deprecated. Instead, attach streams to entities through the media component instead.

Ingress protocols

Lattice supports the following video protocols:

  • RTSP: Provide a Real Time Streaming Protocol (RTSP), rtsp://, URL in RtspSettings.url. Lattice pulls frames from it; the response contains no additional connection details.
  • MPEG-TS: Send an empty MpegTsSettings. The response contains an MpegTsIngress with a URL; push MPEG transport stream (MPEG-TS) packets to that URL. Use this protocol when the source cannot accept inbound RTSP connections. MPEG-TS ingress is supported only at the edge, in closed networks. If you connect to Lattice over the public internet, you can’t start an MPEG-TS stream, but you can still list or inspect an existing IngressStream that uses it.
  • SRT: Send an SrtSettings with an optional passphrase. The response contains an SrtIngress with a URL and a session_id; push the SRT stream to that URL using the supplied session ID. Set a passphrase to apply AES encryption to the stream.

What’s next