send buffer through udpsink

enricom enri_marne87 at msn.com
Thu May 24 02:56:10 PDT 2012


Hello, to do so first of all you need to create the buffer, for instance
with: buffer  =  gst_buffer_new_and_alloc (sizeof(your_data)): this way you
create a buffer with required size. Then you have to put your data into it
by using memcpy(GST_BUFFER_DATA(buffer) , your_data, sizeof(your_data)). 
After this step you need to inject it into your pipeline by using an appsrc
element, with gst_app_src_push_buffer(GST_APP_SRC(appsrc), buffer)). Of
course appsrc needs to be connected to the udpsink element. On the other
side you can use udpsrc, then an identity element. This one, by means of the
handoff signal, tells you when a buffer has been received and so you can
extract data from it.

	



dennis wrote
> 
> hi everyone...
> 
> i have a buffer and i want to be able to stream it using udpsink but, i
> don't know how it's done i know i have to use gstbuffer but i don't know
> how can i link them together........
> 
> any help please.....
> 


--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/send-buffer-through-udpsink-tp4591140p4652774.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list