Hi all, I'm having some problems with Gstreamer in a Ubuntu 10.04 desktop. I'm trying to make an H.264 streaming application but there is a delay about 2-3 seconds.
My current pipelines are: Server: #!/bin/sh DEST=127.0.0.1 VOFFSET=0 AOFFSET=0 VELEM="v4l2src device=/dev/video0" VCAPS="ffmpegcolorspace" VSOURCE="$VELEM ! $VCAPS" VENC=" timeoverlay ! x264enc byte-stream=true bitrate=2000 cabac=false ! rtph264pay mtu=1438 " VRTPSINK="udpsink port=5000 host=$DEST ts-offset=$VOFFSET name=vrtpsink" VRTCPSINK="udpsink port=5001 host=$DEST sync=false async=false name=vrtcpsink" VRTCPSRC="udpsrc port=5005 name=vrtpsrc" PIPELINE="gstrtpbin name=rtpbin $VSOURCE ! $VENC ! rtpbin.send_rtp_sink_2 rtpbin.send_rtp_src_2 ! $VRTPSINK rtpbin.send_rtcp_src_2 ! $VRTCPSINK $VRTCPSRC ! rtpbin.recv_rtcp_sink_2" echo $PIPELINE gst-launch -v $PIPELINE Client: #!/bin/sh VIDEO_CAPS="application/x-rtp,media=(string)video,clock-rate=(int)90000,encoding-name=(string)H264" DEST=127.0.0.1 gst-launch -v gstrtpbin name=rtpbin \ udpsrc caps=$VIDEO_CAPS port=5000 ! rtpbin.recv_rtp_sink_0 \ rtpbin. ! rtph264depay ! ffdec_h264 ! autovideosink \ udpsrc port=5001 ! rtpbin.recv_rtcp_sink_0 \ rtpbin.send_rtcp_src_0 ! udpsink host=$DEST port=5005 sync=false async=false Thank you in advance. ------------------------------------------------------------------------------ Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/gstreamer-devel |
On 27 August 2010 21:23, Thomaz Barros <[hidden email]> wrote:
> Hi all, I'm having some problems with Gstreamer in a Ubuntu 10.04 desktop. > I'm trying to make an H.264 streaming application but there is a delay about > 2-3 seconds. > VENC=" timeoverlay ! x264enc byte-stream=true bitrate=2000 cabac=false ! I'm not certain but I suspect it could be x264enc introducing the delay. Ideally you need an x264 newer than the one in 10.04 (newer than API version 85) and then the next GStreamer release compiled against it. Then you could use the tune=0x4 option which enables a zero latency tuning. However, the zero latency tuning corresponds to: else if( !strncasecmp( s, "zerolatency", 11 ) ) { param->rc.i_lookahead = 0; param->i_sync_lookahead = 0; param->i_bframe = 0; param->b_sliced_threads = 1; param->b_vfr_input = 0; param->rc.b_mb_tree = 0; } (from x264/common/common.c) Which, in GStreamer properties with newer -ugly from the GStreamer developers' PPA could also be given as: rc-lookahead=0 sync-lookahead=0 bframes=0 sliced-threads=1 mb-tree=0 (variable frame rate input is not exposed through the properties). Perhaps some of those options are only available in newer x264 APIs and so are not relevant to older x264 as they were not yet implemented. Give it a go. Hopefully it will help. :) I think lookahead introduces the largest delay when encoding. Regards, Rob ------------------------------------------------------------------------------ Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/gstreamer-devel |
Hi Rob, thanks for your response. I just tried your suspect today because i had other problems during the week. I built the lastest gstreamer core and plugins version and the latest libx264 release but it didn't work as well but your options aren't displayed to me.
2010/8/28 Rob <[hidden email]>
------------------------------------------------------------------------------ This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/gstreamer-devel |
On 3 September 2010 13:37, Thomaz Barros <[hidden email]> wrote:
> Hi Rob, thanks for your response. I just tried your suspect today because i > had other problems during the week. I built the lastest gstreamer core and > plugins version and the latest libx264 release but it didn't work as well > but your options aren't displayed to me. Which packages did you build? How did you build them? Did you install them or are you running them uninstalled or using JHBuild? What do you mean by the latest libx264 release? The latest release as far as the x264 developers are concerned is always the current tip of the x264 git repository. With current x264 (from git) and current core -base and -ugly (also from git repositories) I see all the options I mentioned. Regards, Rob ------------------------------------------------------------------------------ This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/gstreamer-devel |
Hi, I've already tried two alternatives but could not see the x264enc options you told me before:
1) I compiled all the Gstreamer packages (always the latest versions) and the latest daily tarball of libx264 from VideoLan. 2) I compiled libx264 and tested it with the latest Gstreamer packages from PPA. As I told before, none of these options worked for me. Do you know if I'm making any mistake? I'm using Ubuntu 10.04 32 bits. 2010/9/3 Rob <[hidden email]>
------------------------------------------------------------------------------ Start uncovering the many advantages of virtual appliances and start using them to simplify application deployment and accelerate your shift to cloud computing. http://p.sf.net/sfu/novell-sfdev2dev _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/gstreamer-devel |
Free forum by Nabble | Edit this page |