updated rtp-receiver.sh script

This commit is contained in:
wt
2026-03-12 02:07:07 +07:00
parent abf91b151c
commit ebfd768a82
+15 -6
View File
@@ -1,7 +1,16 @@
#!/bin/bash
gst-launch-1.0 udpsrc port=46000 buffer-size=65536 ! \
application/x-rtp,media=audio,payload=127,clock-rate=48000,encoding-name=L16,channels=2 ! \
rtpjitterbuffer latency=200 ! \
rtpL16depay ! \
audioconvert ! \
autoaudiosink
action=$1
case $action in
load)
pactl load-module module-rtp-recv \
codec=audio/L16 \
channels=2 \
rate=48000 \
format=s16be \
sap=0
;;
unload)
pactl unload-module module-rtp-recv
;;
esac