From card buffer to GstBuffer

BogdanS bodyaf at gmail.com
Thu Sep 1 08:55:48 UTC 2016


>That function takes ownership of the memory you pass it and will call 
>g_free() on it after its no longer in use. 

>Your API looks like the outbuf is only valid in the scope of the 
>function, so you would have to copy it first before putting it into a 
>GstBuffer or GstMemory. 


>If you had API that has refcounting or otherwise allows you to notify 
>the caller about when the memory is not in use anymore, you could use 
>gst_buffer_new_wrapped_full() without copying but a custom function to 
>"free" the memory. 

Firts of all Thank You!

In the end I used:

*buffer=gst_buffer_new_allocate(NULL,outsize,NULL);
gst_buffer_fill(buffer,0,outbuf,outsize);
gst_app_src_push_buffer(appsrc,buffer);*

Now it's works, but if it is Ok?





--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/From-card-buffer-to-GstBuffer-tp4679321p4679343.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list