Service: SRT Stream Generator - EyevinnOSC/community GitHub Wiki

SRT Stream Generator

SRT Stream Generator (serviceId bjowestman-srt-stream-generator) is an FFmpeg-powered test stream generator that produces synthetic MPEG-TS video test patterns and audio tones with SRT output. It needs no input source. In Eyevinn Open Source Cloud (OSC) it is a long-running service instance with a web UI for managing streams.

What it can do

  • Generate test patterns (color bars, SMPTE bars and others) and audio tones with SRT output in caller or listener mode.
  • Run several streams in parallel and monitor them in real time in the web UI.
  • Configure codecs, bitrates and resolutions, up to 3 audio tracks, audio generators (sine waves at different frequencies, white/pink/brown noise) and an audio-only mode.
  • Test SRT-based ingest pipelines and validate decoders before a real camera or encoder is available.
  • Be controlled programmatically through a REST API with Swagger documentation.

Creating an instance

SRT Stream Generator has no dependencies on other OSC services. Create it with create-service-instance, serviceId: "bjowestman-srt-stream-generator":

{ "name": "mytestsrc" }

Use wait-for-service-ready or get-instance-status, then describe-service-instance for the instance URL. The instance starts automatically. With the OSC CLI:

osc create bjowestman-srt-stream-generator my-test-src

Options

Option Required Type Meaning
name Yes string Name of the instance. Alphanumeric (underscores are also accepted by the catalog validator ^\w+$), at most 20 characters.

There are no other options; streams are configured in the web UI or through the REST API after the instance is running.

Using the instance

Open the instance URL to reach the web UI. Use New Stream to configure a stream:

Field Description
SRT URL Destination SRT URL, for example srt://receiver-host:9000?mode=caller
Video pattern Test pattern type (SMPTE bars, color bars, etc.)
Resolution / Bitrate Output video quality
Audio Sine tone frequency, noise, or audio-only mode

Then start the stream. Point your SRT-capable player, encoder or ingest service at the SRT URL. For listener mode, use the instance's public URL and the port you configured.

ffplay srt://your-instance-url:9000

In VLC, open srt://your-instance-url:9000 from Media > Open Network Stream.

The REST API has interactive Swagger documentation at https://your-instance-url/api-docs:

# List active streams
curl https://your-instance-url/api/streams

# Start a new stream
curl -X POST https://your-instance-url/api/streams \
  -H "Content-Type: application/json" \
  -d '{"srtUrl":"srt://receiver:9000","pattern":"smptebars"}'

Resources