<div style="line-height:1.7;color:#000000;font-size:14px;font-family:Arial"><div>First, use queue, not queue2. queue2 is overkill for this, and typically </div><div>used for network buffering. </div><div><br></div><div>----------------------------------</div><div><span style="color: rgb(255, 0, 0);">OK, I'll try to use queue.</span></div><div><br></div><div>Second, try what happens if you put base.mp4 in tmpfs (meaning it is </div><div>placed in RAM) and also write new.h264 to tmpfs. The idea here is to </div><div>rule out I/O as a bottleneck.  </div><div><br></div><div>--------------------------------</div><div><span style="color: rgb(255, 0, 0);">I've tried to put base.mp4 to tmpfs, and write new.h264 to tmpfs, buf the</span></div><div><span style="color: rgb(255, 0, 0);">result is as the same as before.  So I think that I/O is not a bottleneck.</span></div><div><br></div><div>Third, what happens if you set sync=false in imxg2dvideosink? </div><div><br></div><div>--------------------------------</div><div><span style="color: rgb(255, 0, 0);">OK, I've  got a smooth play of the base.mp4 after setting sync=false in imxg2dvideosink,</span></div><div><span style="color: rgb(255, 0, 0);">but I found that the playing time(33 seconds) is longer than the normal(30 seconds). </span></div><div><span style="color: rgb(255, 0, 0);">We can't stand the latency.</span></div><div><br></div><div><br></div><div><span style="color: rgb(255, 0, 0);">Now I'm trying to use mxc_vpu_test demonstration example to optimize this, I think</span></div><div><span style="color: rgb(255, 0, 0);">some memory copys happened in Gstreamer, so it should be OK if I avoid memory copys, espically </span></div><div><span style="color: rgb(255, 0, 0);">the decoded YUV data.</span></div><div><span style="color: rgb(255, 0, 0);">I'll use only a thread to run VPU encodec and decode. If I have some good result, I'll show you.</span></div><div><span style="color: rgb(255, 0, 0);">I am not working in company, because a New Year in China. and Happy New Year to you.</span></div><br><br><br><br><div style="position:relative;zoom:1">--<br><div>夫君子之行,静以修身,俭以养德。</div><div style="clear:both"></div></div><div id="divNeteaseMailCard"></div><br>At 2017-01-25 18:26:08, "Carlos Rafael Giani [via GStreamer-devel]" <<a href="/user/SendEmail.jtp?type=node&node=4681642&i=0" target="_top" rel="nofollow" link="external">[hidden email]</a>> wrote:<br> <blockquote style='border-left:2px solid #CCCCCC;padding:0 1em' id="isReplyContent" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">

        Several possibilities.
<br><br>First, use queue, not queue2. queue2 is overkill for this, and typically 
<br>used for network buffering.
<br><br>Second, try what happens if you put base.mp4 in tmpfs (meaning it is 
<br>placed in RAM) and also write new.h264 to tmpfs. The idea here is to 
<br>rule out I/O as a bottleneck.
<br><br>Third, what happens if you set sync=false in imxg2dvideosink?
<br><br><br>On 2017-01-23 04:10, qqk wrote:
<div class="shrinkable-quote"><div class='shrinkable-quote'><br>> Hi, everyone.
<br>>
<br>> I have posted this topic on NXP community.
<br>> The website is :
<br>> <a href="https://community.nxp.com/message/868167" target="_top" rel="nofollow" link="external">https://community.nxp.com/message/868167</a><br>>
<br>> BUT nobody can answer it.
<br>> So  I post it here for help.
<br>>
<br>> --------------------------------------------------------------------------------------------------------
<br>>
<br>> Hello,
<br>> I have a question about VPU codec on IMX6Q.
<br>>
<br>> First, a MP4 file is loaded into memmory, then it is be demuxed to the H264.
<br>> After that, we get the input H264 data. OK, now we need doing 3 things
<br>> simultaneously.
<br>> 1. H264 is send to VPU, then VPU decodes it to YUV. YUV is send to IPU or
<br>> G2D for display.
<br>> 2. At the same time, H264 is also send to VPU for re-encoding to a new H264
<br>> file.
<br>> 3. At the same time, H264 is also send to a remote PC for RTP/UDP streaming
<br>> simultaneously.
<br>>
<br>> I use Gstreamer to finish that. the GST commond is :
<br>> gst-launch-1.0  -v filesrc location=`pwd`/base.mp4 ! qtdemux ! h264parse !
<br>> tee name=tt tt. ! queue2 ! rtph264pay ! udpsink host=192.168.1.110 port=5000
<br>> tt. ! queue2 ! imxvpudec ! tee name=t t. ! queue2 ! imxg2dvideosink t. !
<br>> queue2 ! imxvpuenc_h264 bitrate=10240 ! filesink location=new.h264
<br>>
<br>>   
<br>> Now , we found that the IMX6Q has not a smooth play of the MP4 file on the
<br>> LCD by using IPU or G2D. but the remote PC can play smoothly by using
<br>> RTP/UDP.
<br>> How can I optimize that ?
<br>>
<br>> thanks!
<br>>
<br>>
<br>>
<br>> --
<br>> View this message in context: <a href="http://gstreamer-devel.966125.n4.nabble.com/About-Freescale-i-MX6Q-VPU-codec-simultaneously-tp4681586.html" target="_top" rel="nofollow" link="external">http://gstreamer-devel.966125.n4.nabble.com/About-Freescale-i-MX6Q-VPU-codec-simultaneously-tp4681586.html</a><br>> Sent from the GStreamer-devel mailing list archive at Nabble.com.
<br>> _______________________________________________
<br>> gstreamer-devel mailing list
<br>> <a href="/user/SendEmail.jtp?type=node&node=4681631&i=0" target="_top" rel="nofollow" link="external">[hidden email]</a>
<br>> <a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_top" rel="nofollow" link="external">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a></div></div>_______________________________________________
<br>gstreamer-devel mailing list
<br><a href="/user/SendEmail.jtp?type=node&node=4681631&i=1" target="_top" rel="nofollow" link="external">[hidden email]</a>
<br><a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_top" rel="nofollow" link="external">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>

        
        
        
        <br>
        <br>
        <hr noshade size="1" color="#cccccc">
        <div style="color:#444; font: 12px tahoma,geneva,helvetica,arial,sans-serif;">
                <div style="font-weight:bold">If you reply to this email, your message will be added to the discussion below:</div>
                <a href="http://gstreamer-devel.966125.n4.nabble.com/About-Freescale-i-MX6Q-VPU-codec-simultaneously-tp4681586p4681631.html" target="_top" rel="nofollow" link="external">http://gstreamer-devel.966125.n4.nabble.com/About-Freescale-i-MX6Q-VPU-codec-simultaneously-tp4681586p4681631.html</a>
        </div>
        <div style="color:#666; font: 11px tahoma,geneva,helvetica,arial,sans-serif;margin-top:.4em;line-height:1.5em">
                
                To unsubscribe from About  Freescale i.MX6Q VPU codec simultaneously, <a href="" target="_top" rel="nofollow" link="external">click here</a>.<br>
                <a href="http://gstreamer-devel.966125.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml" rel="nofollow" style="font:9px serif" target="_top" link="external">NAML</a>
        </div></blockquote></div><br><br><span title="neteasefooter"><p> </p></span>

        
        
        
<br/><hr align="left" width="300" />
View this message in context: <a href="http://gstreamer-devel.966125.n4.nabble.com/About-Freescale-i-MX6Q-VPU-codec-simultaneously-tp4681586p4681642.html">Re:Re: About Freescale i.MX6Q VPU codec simultaneously</a><br/>
Sent from the <a href="http://gstreamer-devel.966125.n4.nabble.com/">GStreamer-devel mailing list archive</a> at Nabble.com.<br/>