<div dir="ltr"><div><div>According to the documentation for PCAPPARSE, you need to supply the source and destination IP address and port, so it can pick out the correct packets. You also need to specify the payload type to the depayloader. Here is my pipeline:<br>
<br>gst-launch filesrc location=$1 ! 'raw/x-pcap' ! queue ! pcapparse src-ip=$2 src-port=$3 dst-ip=$4 dst-port=$5 ! \<br> 'application/x-rtp,media=video,payload=104,clock-rate=90000,encoding-name=H264' ! \<br>
rtph264depay byte-stream=true ! video/x-h264 ! ffdec_h264 ! xvimagesink<br><br></div>My pipeline doesn't play well. It plays way too fast, but I haven't had the time to figure out how to slow it down. Perhaps some else can make a suggestion? The problem is that there isn't a clock, so the filesrc reads as fast as it can.<br>
<br></div>Chuck<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Aug 14, 2013 at 4:48 PM, Manfred Ehgartner <span dir="ltr"><<a href="mailto:manfred.ehgartner@gmx.net" target="_blank">manfred.ehgartner@gmx.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div link="blue" vlink="purple" lang="DE-AT"><div><p class="MsoNormal">Hello,<u></u><u></u></p><p>I am currently working in a project, where I have pcaps containing h263, h264 and mpeg I/II audio streams. For some of them I have additionally signaling info with a session description (SDP), for some of them just the rtp streams. I need to create something playable out oft it (mpeg, AVI container file).<u></u><u></u></p>
<p>So I think I have two situations<u></u><u></u></p><p style="margin-left:36.0pt"><u></u><span>1)<span style="font:7.0pt "Times New Roman""> </span></span><u></u>SDP not available (the hard case)<u></u><u></u></p>
<p>After trying several things, I succeeded for H264 using the tool videosnarf combined with ffmpeg. The output raw file of videosnarf could be converted to a MPEG or avi file using ffmpeg. Unfortunately, videosnarf doesn't support h263 and mpeg audio, so I thought gstreamer could help me in this case even if I know, that without SDP and with dynamic payload it might be quite hard or impossible to get something playable.<u></u><u></u></p>
<p>So using wireshark I separated the pcap just containing the udp packets for a single rtp stream and I tried to feed gstreamer using:<u></u><u></u></p><p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Courier New"">gst-launch-0.10 filesrc location=input.pcap ! pcapparse ! rtph264depay<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Courier New"">! ffdec_h264 ! </span>filesink location=output.mpeg, but for almost every pcap I got an error. Even just using the simple pipe <span style="font-size:10.0pt;font-family:"Courier New"">gst-launch-0.10 filesrc location=input.pcap ! pcapparse was not working for most pcaps (and I know, that they are ok). The error is always something like </span>ERROR: pipeline doesn't want to preroll.<u></u><u></u></p>
<p class="MsoNormal">So I think the problem is already in the pcapparse plugin. I tried to use the attributes for ip and port, but the same behaviour. Maybe I am missing something?<u></u><u></u></p><p class="MsoNormal">But I could skip the pcap part, as I have a script which is just taking the udp payload (rtp header + rtp payload) and dumping these rtp packets in a file. Could I maybe use some gstreamer pipeline using this rtp packet file as input?<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p><p style="margin-left:36.0pt"><u></u><span>2)<span style="font:7.0pt "Times New Roman""> </span></span><u></u>SDP available: When I use my script, I have a file containing rtp packets of a video streaming session (e.g. h263) and additionally the sdp file, my goal is to create a playable video file out of it (the container doesn't matter) using gstreamer.<u></u><u></u></p>
<p>I am not experienced using sdp, but as far as I understood, inside the sdp file the parameter c = IN IP4 Host defines the network parameters for the player which is opening the sdp. So the player is using this parameters to wait for incoming rtp packets fitting to the description inside the SDP, am I right?<u></u><u></u></p>
<p>So I would need to replay the rtp stream locally and use gstreamer to capture the packets on the NIC for writing the container file? Or is it possible somehow directly feed gstreamer with the sdp + the file containing the already captured rtp packets and take this two input parameters for generating the output container directly?<u></u><u></u></p>
<p><u></u> <u></u></p><p>Thanks in advance for your help<span class="HOEnZb"><font color="#888888"><u></u><u></u></font></span></p><span class="HOEnZb"><font color="#888888"><p><u></u> <u></u></p><p>Manfred<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p></font></span></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" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>