Query regarding usage of GST_BUFFER_DATA

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Query regarding usage of GST_BUFFER_DATA

Irfan Shaikh-2

Hi all,

         I want to fill the tempbuf bellow after some processing as i have
explained below. Once the tempbuf is full i need to pass its base adres to
another function.
I just wanted to ask can i use 2 buffer poiters such as *data_one and
*data_two
         1. data_one :- For filling tempbuf
         2. data_two :- to send base address of buffer, to some fuction Y.

Please tell me if i can use it this way  and i am correct ...


Whether *data_two is pointing to initial position of data in tempbuf...And
tempbuf is filled properly with help of  *data_one...Can i use *data_one to
pass in function_Y...so as itz serving the purpose


    _chain(GstBuffer buf)
  {
        GstBuffer tmpbuf;
        guint8 *data_one, *data_two;
        tempbuf=gst_buffer_new_and_alloc(300*sizeof(guint8));
        data_one=GST_BUFFER_DATA(tempbuf);

        function_X()
        {
             memcpy(tempbufdata, buf, 100);
             tempbufdata += 100;

             /*Do some processing*/
             memcpy(tempbufdata, buf, 100);

             /*Do some procesing*/
             memcpy(tempbufdata, buf, 100);

            data_two=GST_BUFFER_DATA(tempbuf);

            function_Y(data_two);

        }
  }


Regards,
Irfan


The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments contained in it.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel