Timestamp based extraction of audio data from GstAdapter

dingoegret sephvelut at gmail.com
Thu Apr 13 09:39:36 UTC 2017


Is there a plugin that would allow me to pull 100ms pts of audio every 100ms
of real time? I was looking at audiorate but nothing I've tried accomplished
what I wanted. My program is simple filesrc to appsink where I have set
'new-sample' signal' with the following callback 

static void new_sample(GstElement *sink) { 
    GstSample *sample; 
    g_signal_emit_by_name(sink, "pull-sample", &sample); 

    if(sample) { 
        GstBuffer* buffer = gst_sample_get_buffer(sample); 
        gst_adapter_push(adapter, buffer); 
    } 
} 

I have another thread that reads off the adapter. Don't worry I've left out
thread syncing mutex code for the example.



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Timestamp-based-extraction-of-audio-data-from-GstAdapter-tp4682646.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list