<div dir="ltr">Thanks for the workaround. We've tested it and it works in our environment, but it leaves us wondering at its necessity. Will we have to do this in production, or is there some other fix that could be applied to jpegpay/depay?<br><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 13, 2017 at 3:35 PM, Nicolas Dufresne <span dir="ltr"><<a href="mailto:nicolas@ndufresne.ca" target="_blank">nicolas@ndufresne.ca</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<span class=""><br>
Le jeudi 13 juillet 2017 à 13:25 -0400, Stirling Westrup a écrit :<br>
> It seems that one or the other of the two elements has trouble<br>
> correctly dealing with fragmented jpeg images. As the size of the<br>
> images increase, one starts getting lots and lots of warnings and<br>
> dropped frames from rtpjepgdepay:<br>
><br>
> 0:00:14.129355327 19338      0x1b11370 WARN            rtpjpegdepay<br>
> gstrtpjpegdepay.c:760:gst_rtp_<wbr>jpeg_depay_process:<<wbr>rtpjpegdepay0><br>
> discarding data packets received when we have no header<br>
<br>
</span>I was testing your scripts, and notice that packets are dropped by the<br>
receiving socket. I could workaround the issue locally.<br>
<br>
1. By increasing kernel UDP memory: sysctl -w net.core.rmem_max=26214400<br>
2. Increase client socket buffer size in client: buffer-size=$((512*1024))<br>
<br>
Note that it works with smaller rmem_max value. It also seems to work<br>
with receiver buffer-size of 256 kb. I'm not sure how one calculate the<br>
requirement for these.<br>
<br>
regards,<br>
Nicolas<br>
<div><div class="h5"><br>
><br>
> Here are our test pipelines. Please let us know if this is an actual<br>
> bug, or if we are doing something wrong. We've found that with<br>
> MTU=1400 and QUAL=75, we start dropping long (multi-second) sequences<br>
> of frames. If we set MTU to 64000, we have almost no dropped frames,<br>
> and if we set QUAL=5 we have no trouble with dropped frames (although<br>
> the image is terrible).<br>
><br>
> SERVER:<br>
> #!/bin/bash<br>
><br>
> PATH="/home/sti/Videos/BBB"<br>
> FILE="bbb_sunflower_1080p_<wbr>30fps_normal.mp4"<br>
> MTU=1400<br>
> QUAL=75<br>
> PATHNAME="$PATH/$FILE"<br>
><br>
> /usr/bin/gst-launch-1.0                             \<br>
>   rtpbin ntp-time-source=1 ntp-sync=true buffer-mode=synced<br>
> name=sendbin \<br>
>   filesrc location="$PATHNAME" ! qtdemux ! h264parse ! avdec_h264<br>
>  \<br>
>     ! videoconvert ! queue ! jpegenc quality=$QUAL ! rtpjpegpay<br>
> mtu=$MTU \<br>
>     ! sendbin.send_rtp_sink_0                         \<br>
>   sendbin.send_rtp_src_0                         \<br>
>     ! udpsink port=25000 host="127.0.0.1"                 \<br>
>   sendbin.send_rtcp_src_0                         \<br>
>     ! udpsink port=25001 host="127.0.0.1" sync=false async=false<br>
>  \<br>
>   udpsrc port=25005 ! sendbin.recv_rtcp_sink_0<br>
><br>
> --8<---CUT HERE--->8--<br>
> CLIENT:<br>
><br>
> #!/bin/bash<br>
><br>
> /usr/bin/gst-launch-1.0   \<br>
>   rtpbin name=rtpbin                            \<br>
>   udpsrc port=25000                             \<br>
>     ! application/x-rtp,media=video,<wbr>payload=26,encoding-name=JPEG<br>
> \<br>
>     ,clock-rate=90000 ! rtpbin.recv_rtp_sink_0                \<br>
>   rtpbin. ! rtpjpegdepay ! queue ! jpegparse ! jpegdec ! videoconvert<br>
>     \<br>
>     ! ximagesink display=:0                        \<br>
>   udpsrc port=25001 ! rtpbin.recv_rtcp_sink_0                \<br>
>   rtpbin.send_rtcp_src_0                        \<br>
>     ! udpsink port=25005 host="127.0.0.1" sync=false async=false<br>
><br>
><br>
><br>
</div></div>> ______________________________<wbr>_________________<br>
> gstreamer-devel mailing list<br>
> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.<wbr>freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/gstreamer-<wbr>devel</a></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Stirling Westrup<br>Programmer, Entrepreneur.<br><a href="https://www.linkedin.com/e/fpf/77228" target="_blank">https://www.linkedin.com/e/fpf/77228</a><br><a href="http://www.linkedin.com/in/swestrup" target="_blank">http://www.linkedin.com/in/swestrup</a><br><a href="http://technaut.livejournal.com" target="_blank">http://technaut.livejournal.com</a><br><a href="http://sourceforge.net/users/stirlingwestrup" target="_blank">http://sourceforge.net/users/stirlingwestrup</a></div>
</div>