mirror of
https://github.com/bluenviron/mediamtx.git
synced 2025-12-20 02:00:05 -08:00
add GStreamer + WHEP instructions (#4117)
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_highlevel (push) Waiting to run
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_highlevel (push) Waiting to run
This commit is contained in:
parent
d8720d8e5e
commit
b88f81cb2d
1 changed files with 26 additions and 0 deletions
26
README.md
26
README.md
|
|
@ -894,6 +894,32 @@ If encryption is enabled, set `tls-validation-flags` to `0`:
|
|||
gst-launch-1.0 rtspsrc tls-validation-flags=0 location=rtsps://ip:8322/...
|
||||
```
|
||||
|
||||
GStreamer also supports reading streams with WebRTC/WHEP, although track codecs must be specified in advance through the `video-caps` and `audio-caps` parameters. Furthermore, if audio is not present, `audio-caps` must be set anyway and must point to a PCMU codec. For instance, the command for reading a video-only H264 stream is:
|
||||
|
||||
```sh
|
||||
gst-launch-1.0 whepsrc whep-endpoint=http://127.0.0.1:8889/stream/whep use-link-headers=true \
|
||||
video-caps="application/x-rtp,media=video,encoding-name=H264,payload=127,clock-rate=90000" \
|
||||
audio-caps="application/x-rtp,media=audio,encoding-name=PCMU,payload=0,clock-rate=8000" \
|
||||
! rtph264depay ! decodebin ! autovideosink
|
||||
```
|
||||
|
||||
While the command for reading an audio-only Opus stream is:
|
||||
|
||||
```sh
|
||||
gst-launch-1.0 whepsrc whep-endpoint="http://127.0.0.1:8889/stream/whep" use-link-headers=true \
|
||||
audio-caps="application/x-rtp,media=audio,encoding-name=OPUS,payload=111,clock-rate=48000,encoding-params=(string)2" \
|
||||
! rtpopusdepay ! decodebin ! autoaudiosink
|
||||
```
|
||||
|
||||
While the command for reading a H264 and Opus stream is:
|
||||
|
||||
```sh
|
||||
gst-launch-1.0 whepsrc whep-endpoint=http://127.0.0.1:8889/stream/whep use-link-headers=true \
|
||||
video-caps="application/x-rtp,media=video,encoding-name=H264,payload=127,clock-rate=90000" \
|
||||
audio-caps="application/x-rtp,media=audio,encoding-name=OPUS,payload=111,clock-rate=48000,encoding-params=(string)2" \
|
||||
! decodebin ! autovideosink
|
||||
```
|
||||
|
||||
#### VLC
|
||||
|
||||
VLC can read a stream from the server in multiple ways (RTSP, RTMP, HLS, SRT). The recommended one consists in reading with [RTSP](#rtsp):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue