Regarding buffer size

Shilpa Chandrappa elites.shilpa at gmail.com
Fri Jan 3 05:07:15 PST 2014


I am looking into GstAdapter. I couldn't find any sample code, so starting it
from the beginning. I declared GStAdapter  and did compilation(Please refer
to code below). 

I am getting t below message after compilation.
*
undefined reference to `gst_adapter_new'
collect2: error: ld returned 1 exit status*


static void new_buffer (GstElement *sink, CustomData *data) {
  GstBuffer *buffer;
  FILE *fp;
*  GstAdapter *adapter;
  adapter = gst_adapter_new();*
   g_signal_emit_by_name (sink, "pull-buffer", &buffer);
   if (buffer) {

    gint size=GST_BUFFER_SIZE(buffer);
    g_print("\nsize=%d \n",size);


    fwrite(GST_BUFFER_DATA(buffer), 1, GST_BUFFER_SIZE(buffer),data->fp);
    gst_buffer_unref (buffer);
  }
}

Am I declaring GstAdapter in wrong way ?

Thanks,
Shilpa Chandrappa




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Regarding-buffer-size-tp4664396p4664430.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list