<div dir="ltr"><div><div><div>So go ahead and create one single pipeline, one for machine A and one for machine B, for capturing audio and video, encoding, muxing, rtp-encapsulating and udp-sending.<br><br></div>Then create a single pipeline, one for host A and one for host B, for udp-receiving, rtp-decap, demux, decode (audio and video) and play audio and video with sync=true.<br><br></div>That'll give you minimal delay, although depending on codec, and it will provide synchronization. Note that not all muxers can take all kind of formats. gst-inspect-1.0 used on the muxer module name will list what kind of formats it accept. Note that <b>sometimes</b>, running a parse after encoding and before muxing can be necessary. Like this<br><br><div style="margin-left:40px"> ... x264enc tune=zerolatency ! <b>h264parse</b> ! queue ! mpegtsmux name=muxer ! ..... faac ! <b>aacparse</b> ! queue ! mux.<br></div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jun 23, 2015 at 1:21 PM, Lab work <span dir="ltr"><<a href="mailto:480437@gmail.com" target="_blank">480437@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Peter<div><br></div><div>I was also thinking that synchronizing audio and video would be a problem.  </div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jun 23, 2015 at 4:07 PM, Peter Maersk-Moller <span dir="ltr"><<a href="mailto:pmaersk@gmail.com" target="_blank">pmaersk@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi Nicholas.<br><br></div>Unless you mux (multiplex) audio and video into a single multiplexed stream or use rtspserver with two rtp streams and the rtspserver telling clients how audio and video is synchronized or you use a more complicated setup rtpsession/rtpbin and RTCP and NTP, you will not have audio and video synchronized. Why not use a multiplexer like mpegtsmux and have audio/video encoded and muxed and sent in a single pipeline and then in another pipeline receiving multiplexed stream, demuxing it, decoding it and then played?<br><br></div>regards<span><font color="#888888"><br></font></span></div><span><font color="#888888">Peter<br></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jun 23, 2015 at 8:28 AM, Lab work <span dir="ltr"><<a href="mailto:480437@gmail.com" target="_blank">480437@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi <div><br></div><div>Thanks for the replay.</div><div>Your answer left me a bit confused. </div><div><br></div><div>><span style="font-size:12.8000001907349px">Finally, </span><span style="font-size:12.8000001907349px">each streams should be sent to it's down socket in RTP, you may multi</span><span style="font-size:12.8000001907349px">plex them but this is a lot more work.</span></div><div><br></div><div><span style="font-size:12.8000001907349px">Do you mean that I should not mux them and do something like:</span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">pipeline 1:</span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">gst-launch-1.0 v4l2src !  video/x-raw,width=640,height=480 !  timeoverlay !  tee name="local" !  queue !  autovideosink local. !  queue ! x264enc tune=zerolatency byte-stream=true bitrate=500 threads=1 ! h264parse config-interval=1  ! rtph264pay !  udpsink host=192.168.100.3 port= 5000 udpsrc port=5000 caps=\"application/x-rtp,payload=96,encoding-name=H264\" ! queue ! rtph264depay ! h264parse ! decodebin ! autovideosink</span><br></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">pipeline 2 :</span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">gst-launch-1.0 pulsesrc ! audioconvert ! audioresample ! speexenc ! rtpspeexpay ! udpsink host=192.168.100.3 port=4444 udpsrc port=4444 caps="application/x-rtp, media=(string)audio, clock-rate=(int)16000, encoding-name=(string)SPEEX, encoding-params=(string)1, payload=(int)110" ! rtpjitterbuffer ! rtpspeexdepay ! speexdec ! audioconvert ! audioresample ! autoaudiosink</span><br></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">And playing similar pipelines on other PC. I have tried this type of approach and the video part was working but audio part was creating problem</span><span style="font-size:12.8000001907349px">. when I run the second pipeline there is no audio at either end while they work fine independently. Can you please explain the reason. And me out of this problem. </span></div><div><span style="font-size:12.8000001907349px">Thank you.</span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 22, 2015 at 7:32 PM, Nicolas Dufresne <span dir="ltr"><<a href="mailto:nicolas.dufresne@collabora.com" target="_blank">nicolas.dufresne@collabora.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>Le lundi 22 juin 2015 à 17:00 +0530, Lab work a écrit :<br>
> gst-launch-1.0  oggmux name="muxer"  v4l2src ! video/x-raw,<br>
> framerate=30/1, width=640, height=480 ! videoconvert ! x264enc !<br>
> multiqueue ! muxer.  videotestsrc ! video/x-raw, framerate=30/1,<br>
> width=640, height=480 ! videoconvert ! x264enc ! multiqueue ! muxer.<br>
> autoaudiosrc ! audioconvert ! speexenc ! queue ! muxer.  udpsink<br>
> host=127.0.0.1 port=5000<br>
<br>
</span>So you want to stream in RTP over UDP. First you need to drop this<br>
unlinked oggmux. OGG is not RTP. Also it does not work with variable<br>
framerate (which most Logitech camera produces). Second, pick a preset<br>
on x264enc that is suited for live (like tune=zerolatency). Finally,<br>
each streams should be sent to it's down socket in RTP, you may multi<br>
-plex them but this is a lot more work.<br>
<span><font color="#888888"><br>
Nicolas</font></span><br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>