Skip to main content

gst-signalling-py: Gstreamer WebRTC signalling in Python

Code style: black linter pytest coverage

This repository provides a Python implementation of the Gstreamer WebRTC signalling protocol.

It provides an API close to the gstreamer API with a producer and a consumer. This allows to simply write producer/consumer examples using gstreamer signalling. It works with single producer and multiple consumers for exchanging data. See the data producer example for more details.

It also provides tools to list and monitor the peers connected to a signalling server.

Note that there is no example of audiovideo streaming. Gstreamer provides rust plugins that directly communicate with a signalling server

Installation

Simply install the package using pip:

pip install -e .

Usage

See the examples for more details.

Protocol

Roles

Gstreamer signalling defines 3 roles (so the WebRTC peers are not symmetrical)

  • producer (produces data, video or audio streams)
  • consumer (access to a producer stream, can access all or a subset of its streams)
  • listener (gets notified by the server of new producers status)

Protocol sequence diagram

sequenceDiagram
  Server-->>Producer: Welcome (PeerId)
	Server-->>Consumer: Welcome (PeerId)
  Producer->>Server: PeerStatusChanged  # declare yourself as producer
	Consumer->>Server: StartSession # with producer PeerId
	Server-->>Producer: StartSession (SessionId)
	Server-->>Consumer: SessionStarted (SessionId)
	Producer->>Server: Peer (offer sdp)
	Server-->>Consumer: Peer (offer sdp)
	Consumer->>Server: Peer (answer sdp)
	Server-->>Producer: Peer (answer sdp)

See this page for more details.

Contribute

Please refer to our template repository for guidlines and coding style.

Development tools can be installed with

pip install -e .[dev]

Unit tests

The gstreamer signalling server is required to run on the localhost. Then run

pytest

Metadata

Release files for gst-signalling 1.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gst-signalling 1.1.2
File Size Uploaded
gst_signalling-1.1.2.tar.gz 16.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for gst-signalling 1.1.2
File Interpreter ABI Platform
gst_signalling-1.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 36.1 kB

Release files / gst_signalling-1.1.2.tar.gz

Download URL gst_signalling-1.1.2.tar.gz
Size 16.5 kB
Tags Source
SHA-256 checksum
How to use checksums
45c7bb3d6801b2704cd4c743130f60d2991b39aa91b6220873ef53ffe9910b98
BLAKE2b-256 checksum
How to use checksums
3f770c45062d07bb6ad8f940a8a8bc3acd7968cc145be354a566e897d4a6753c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.19

Release files / gst_signalling-1.1.2-py3-none-any.whl

Download URL gst_signalling-1.1.2-py3-none-any.whl
Size 19.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
39ebb6eac597933504334d4c1f835abd873cbd42fe31896515e3a0db368db78c
BLAKE2b-256 checksum
How to use checksums
847a4ac380ce2e7e9ea1e055460648d6c562eb554cdc0dd9b6536b38934b9ef4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.19

Release history Release notifications | RSS feed

This release

1.1.2 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page