[gst-devel] help: udpsrc with ip address.

lyang oxcsnicho at gmail.com
Fri Mar 27 07:35:59 CET 2009


Hi shirie,

Just tested your pipeline on my machine. It crashes in the latter 3 cases.

However, if we specify the host first and then the port in the udpsink
properties of server side, the pipeline works just fine. That is, to write
"host=...." first and  then "port=...."

IMHO, there seems to be a default order in the modification of udpsink's
properties. I don't know if this is true, but you can refer to the following
source: $PLUGIN_GOOD/gst/udp/gstudpsink.c, in function
gst_udpsink_set_property(). The code is modifying host iff parameter prop_id
=1, while prop_id is susceptible to be the order of the modification
expression.
I'm using the latest release of plugins-good. Don't know if it is the same
case for more stable versions.

I'll be very happy to see anyone to prove or disprove my guess.


Regards,
Lin


shirie wrote:
> 
> Hi, all. I am a newbie to gstreamer.  I am now trying build a simple
> pipeline to transmit video with udp between two machines.
> Here are what I have done now.
> 
> server:
> gst-launch filesrc location=new0.mpg ! mpegdemux mpegdemux0.video_00 ! {
> queue ! udpsink port=4400 } \
> mpegdemux0.audio_00 ! { queue ! udpsink port=4401 }
> 
> client:
> gst-launch udpsrc port=4400 ! { queue ! mpeg2dec ! xvimagesink } \
> udpsrc port=4401 ! { queue ! decodebin ! audioconvert ! audioresample !
> autoaudiosink }
> 
> I test them in one machine. They work well.
> 
> But when I tried to specify the ip address as:
> 
> server:
> gst-launch filesrc location=new0.mpg ! mpegdemux mpegdemux0.video_00 ! {
> queue ! udpsink port=4400 host=192.168.0.1} \
> mpegdemux0.audio_00 ! { queue ! udpsink port=4401 host=192.168.0.1 }
> client:
> gst-launch udpsrc uri=udp://192.168.0.1:4400 ! { queue ! mpeg2dec !
> xvimagesink } \
> udpsrc uri=udp://192.168.0.1:4401 ! { queue ! decodebin ! audioconvert !
> audioresample ! autoaudiosink }
> 
> Error occurs in the client.
> error: from element /pipeline0/udpsrc0:can't get the resource specified.
> (I
> translate the message from my local language)
> 
> gstudpsrc.c(825): gst_udpsrc_start (): /pipeline0/udpsrc0:
> could add membership -1: invalid parameter (22)
> 
> 
> Even cannot work with using 127.0.0.1 in one machine.
> server:
> gst-launch filesrc location=new0.mpg ! mpegdemux mpegdemux0.video_00 ! {
> queue ! udpsink port=4400 host=127.0.0.1 } \
> mpegdemux0.audio_00 ! { queue ! udpsink port=4401 host=127.0.0.1 }
> client:
> gst-launch udpsrc uri=udp://127.0.0.1 :4400 ! { queue ! mpeg2dec !
> xvimagesink } \
> udpsrc uri=udp://127.0.0.1 :4401 ! { queue ! decodebin ! audioconvert !
> audioresample ! autoaudiosink }
> 
> But using "localhost" works,
> gst-launch filesrc location=new0.mpg ! mpegdemux mpegdemux0.video_00 ! {
> queue ! udpsink port=4400 host=localhost } \
> mpegdemux0.audio_00 ! { queue ! udpsink port=4401 host=localhost }
> client:
> gst-launch udpsrc uri=udp://localhost :4400 ! { queue ! mpeg2dec !
> xvimagesink } \
> udpsrc uri=udp://localhost :4401 ! { queue ! decodebin ! audioconvert !
> audioresample ! autoaudiosink }
> 
> I'm confused. Can anybody help me?
> Thanks very much.
> 
> ------------------------------------------------------------------------------
> 
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
> 
> 

-- 
View this message in context: http://www.nabble.com/help%3A-udpsrc-with-ip-address.-tp22735354p22736689.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.





More information about the gstreamer-devel mailing list