Gstreamer-1.0 - get data from GstSample in GstAppSink

akashjain akash.dhamasia12 at gmail.com
Tue Feb 16 09:00:30 UTC 2016


Hi,  Following is the way to get data from ( appsink name=sink ) element.

GstElement *sink = gst_bin_get_by_name (GST_BIN (pipeline1), "sink");
GstAppSink *appsink = GST_APP_SINK(sink);
GstSample *sample = gst_app_sink_pull_sample(appsink);
GstBuffer *buffer = gst_sample_get_buffer(sample);
GstMapInfo map;
gst_buffer_map (buffer, &map, GST_MAP_READ);

THROUGH map.data you can take out the data, after than unmap the buffer.







--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Gstreamer-1-0-get-data-from-GstSample-in-GstAppSink-tp4675842p4675874.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list