Documentation Index
Fetch the complete documentation index at: https://mintlify.com/moq-dev/moq/llms.txt
Use this file to discover all available pages before exploring further.
GStreamer Plugin
The Moq GStreamer plugin providesmoqsrc and moqsink elements for integrating Moq into GStreamer pipelines. This enables efficient media processing and streaming with full control over encoding, decoding, and transformations.
Overview
The GStreamer plugin provides two main elements:- moqsink: Publish media to Moq relays
- moqsrc: Subscribe to Moq broadcasts
Repository
The plugin is maintained in a separate repository:Moq GStreamer Plugin
View source code, installation instructions, and examples
Installation
Publishing with moqsink
Basic Publishing Pipeline
Publish a test video pattern:Publish from Webcam
Stream from a video device:Publish with Audio
Include audio in your stream:Publish a File
Stream a video file:Subscribing with moqsrc
Basic Playback Pipeline
Subscribe and play a Moq broadcast:Save to File
Record a Moq broadcast to a file:Transcode and Republish
Subscribe, transcode, and republish:moqsink Properties
Configure themoqsink element:
| Property | Type | Default | Description |
|---|---|---|---|
url | string | required | Relay server URL |
broadcast | string | required | Broadcast name |
jwt | string | - | Authentication token |
Example with Properties
moqsrc Properties
Configure themoqsrc element:
| Property | Type | Default | Description |
|---|---|---|---|
url | string | required | Relay server URL |
broadcast | string | required | Broadcast name |
jwt | string | - | Authentication token |
Advanced Pipelines
Multi-Bitrate Publishing
Publish multiple quality levels:Screen Capture
Capture and stream your screen:Low Latency Configuration
Optimize for minimal latency:Key parameters for low latency:
tune=zerolatency: Disables lookaheadkey-int-max=30: Frequent keyframes (every 1 second at 30fps)bframes=0: No B-frameschunk-duration=1: 1-second fragments
Debugging
Enable Debug Output
Set GStreamer debug level:Inspect Pipeline
Visualize your pipeline:More Examples
Check the repository’sjustfile for additional examples:
Troubleshooting
Plugin Not Found
- Verify plugin is in GStreamer plugins directory
- Run
gst-inspect-1.0 moqsinkto check installation - Set
GST_PLUGIN_PATHif using custom location
Connection Errors
- Check relay URL is accessible
- Verify firewall allows UDP traffic
- Ensure JWT token is valid if using authentication
Pipeline Errors
- Verify all elements are installed (
gst-inspect-1.0 <element>) - Check element capabilities match (use
gst-inspect-1.0) - Enable debug output to identify bottlenecks
Next Steps
Deploy a Relay
Set up your own relay server
FFmpeg Integration
Alternative command-line publishing
Web Playback
Watch streams in the browser
OBS Plugin
Stream using OBS Studio