|
Hello,
I am trying to test an rtp streaming application on localhost, i wrote two scripts : one for server and one for client. When I launch the two scripts, no video is displayed, can someone please tell me what i am doing wrong ?
Server.sh:
FPS=24
SERVER_IP=127.0.0.1
SEND_RTP_PORT=5000
SEND_BUFFER=0
X264_BITRATE=600
X264_PARAM="byte-stream=true bframes=4 ref=4 me=hex subme=4 weightb=true threads=0 sliced-threads=1 vbv-buf-capacity=300"
# With RTCP
SEND_RTCP_PORT=5001
RECV_RTCP_PORT=5002
gst-launch -v gstrtpbin name=rtpbin videotestsrc
! queue ! videoscale method=1 ! video/x-raw-yuv,width=352,height=288
! queue ! videorate ! video/x-raw-yuv,framerate=FPS/1
! queue ! x264enc bitrate=$X264_BITRATE $X264_PARAM ! rtph264pay
! rtpbin.send_rtp_sink_0
rtpbin.send_rtp_src_0 ! udpsink port=$SEND_RTP_PORT host=$SERVER_IP
rtpbin.send_rtcp_src_0 ! udpsink port=$SEND_RTCP_PORT host=$SERVER_IP sync=false async=false
udpsrc port=$RECV_RTCP_PORT ! rtpbin.recv_rtcp_sink_0
Client.sh:
RECV_RTP_PORT=5000
RECV_BUFFER=300
CLIENT_IP=127.0.0.1
RECV_RTCP_PORT=5001
SEND_RTCP_PORT=5002
gst-launch -tv gstrtpbin name=rtpbin latency=$RECV_BUFFER
udpsrc caps="application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264, payload=(int)96" port=$RECV_RTP_PORT
! rtpbin.recv_rtp_sink_0
rtpbin. ! rtph264depay ! ffdec_h264 ! ffmpegcolorspace ! autovideosink
udpsrc port=$RECV_RTCP_PORT ! rtpbin.recv_rtcp_sink_0
rtpbin.send_rtcp_src_0 ! udpsink port=$SEND_RTCP_PORT host=$CLIENT_IP sync=false async=false
gst-launch -tv gstrtpbin name=rtpbin latency=$RECV_BUFFER udpsrc caps="application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H264, payload=(int)96" port=$RECV_RTP_PORT ! rtpbin.recv_rtp_sink_0 rtpbin. ! rtph264depay ! ffdec_h264 ! ffmpegcolorspace ! autovideosink udpsrc port=$RECV_RTCP_PORT ! rtpbin.recv_rtcp_sink_0 rtpbin.send_rtcp_src_0 ! udpsink port=$SEND_RTCP_PORT host=$CLIENT_IP sync=false async=false
Thank you in advance
Markus
|