David 9 years atrás
parent
commit
6b002f688a
2 changed files with 8 additions and 2 deletions
  1. 6 2
      server/working-udp-audio.sh
  2. 2 0
      server/working-udp-video.sh

+ 6 - 2
server/working-udp-audio.sh

@@ -3,12 +3,16 @@
 SOURCE="audiotestsrc is-live=true"
 SOURCE='udpsrc port=5001 do-timestamp=true caps="application/x-rtp" ! queue ! rtppcmadepay ! alawdec'
 SOURCE='udpsrc port=5001 do-timestamp=true caps="application/x-rtp" ! queue ! rtppcmudepay ! mulawdec'
+SOURCE='udpsrc multicast-group=224.1.1.1 auto-multicast=true port=5001 do-timestamp=true caps="application/x-rtp" ! queue ! rtppcmudepay ! mulawdec'
+SOURCE='udpsrc multicast-group=192.168.2.255 auto-multicast=true port=5001 do-timestamp=true caps="application/x-rtp" ! queue ! rtppcmudepay ! mulawdec'
+SOURCE='udpsrc port=5001 do-timestamp=true caps="application/x-rtp" ! queue ! rtppcmudepay ! mulawdec'
 
-BANDPASS="audiochebband mode=band-pass lower-frequency=50 upper-frequency=4000"
+BANDPASS="audiochebband mode=band-pass lower-frequency=50 upper-frequency=4000 ! audioconvert "
 
 OUTPUT_FORMAT="audio/x-raw,format=S16LE,layout=interleaved, rate=44100, channels=2"
 
+# gst-launch-1.0 -q $SOURCE ! audioconvert ! audioresample ! $BANDPASS ! audioconvert ! $OUTPUT_FORMAT ! fdsink fd=1 sync=true 
 (
 	echo 'audio feed ctr isaudio 1';
-	gst-launch-1.0 -q $SOURCE ! audioconvert ! audioresample ! $BANDPASS ! audioconvert ! $OUTPUT_FORMAT ! fdsink fd=1 sync=true 
+	gst-launch-1.0 -q $SOURCE ! audioconvert ! audioresample ! $OUTPUT_FORMAT ! fdsink fd=1 sync=true 
 ) | nc 127.0.0.1 9999

+ 2 - 0
server/working-udp-video.sh

@@ -60,6 +60,8 @@ SHMSINK1="shmsink socket-path=$feed_control_pipe $SHMSIZE $SHMOPTION"
 #AUDIOFORMAT="$AUDIOS16LE"', rate='$feed_rate', channels='$feed_channels
 VIDEOFORMAT=$VIDEOBGRA', width='$feed_width', height='$feed_height', framerate=24/1'
 SRC="udpsrc multicast-group=224.1.1.1 auto-multicast=true port=5000 do-timestamp=true ! application/x-rtp, payload=96 ! rtpjitterbuffer ! rtph264depay ! avdec_h264 "
+SRC="udpsrc multicast-group=192.168.2.255 auto-multicast=true port=5000 do-timestamp=true ! application/x-rtp, payload=96 ! rtpjitterbuffer ! rtph264depay ! avdec_h264 "
+SRC="udpsrc port=5000 do-timestamp=true ! application/x-rtp, payload=96 ! rtpjitterbuffer ! rtph264depay ! avdec_h264 "
 while true ; do
     # Remove the named pipe if it exist
     rm -f $feed_control_pipe