Vaapidecode Format and OpenGL

Zelnes mehdi.ghesh at hotmail.fr
Mon Jun 26 07:29:27 UTC 2017


Zelnes wrote
> 
> Victor Jaquez wrote
>> On 06/12/17 at 04:32am, Zelnes wrote:
>>> Arjen Veenhuizen wrote
>>> > Your code was probably scrubbed from the mailinglist. 
>>> 
>>> Yes, it's also what I think. Could I post it here ?
>>> 
>>> 
>>> Arjen Veenhuizen wrote
>>> > You can run 
>>> 
>>> > to get an idea of the caps in use. In code, you could use the
>>> notify::caps
>>> > signal on a GstPad to figure out which caps are in use.
>>> 
>>> Thanks, I now have an idea about the format used whith autovideosink. Do
>>> you
>>> know how I can set the caps ? Whenever I try to create a caps :
>>> GstCaps * caps = gst_caps_new_simple("video/x-raw", "format,
>>> G_TYPE_STRING,
>>> "RGBA", "width", G_TYPE_INT, 1920, "height", G_TYPE_INT, 1080, NULL);
>>> I get a Segfault. I wanted to set this either by linking vaapidecode to
>>> appsink using this filter, or by setting the caps on the vaapidecode src
>>> pad.
>> 
>> If you are getting a segmentation fault when creating a GstCaps
>> instances,
>> that means that you have severe problems in you development
>> environment. Probably you're mixing libraries in run time.
> Now I am able to create GstCaps, it's okay, but I can't set it between
> vaapidecodebin and appsink, or I could not link them.
> 
> Do you have a piece of code showing how to draw a frame on GPU with
> OpenGL, with a frame coming directly from GPU (with vaapidecodebin) and
> which did not go to the CPU ? 
> I have found so many different ways, none of them worked, may be because
> they are out of date. I just want an access to the GPU data, in order to
> process it with OpenGL and the draw it on screen with SDL and OpenGL
> (textures).
> 
> I know it is possible, but I can't figure out why my attempts all fails.
> Victor Jaquez wrote
>>> Arjen Veenhuizen wrote
>>> > W.r.t. 
>>> > GstSample
>>> >
>>> <https://developer.gnome.org/gstreamer/stable/gstreamer-GstSample.html>  
>>> >  vs 
>>> > GstBuffer
>>> >
>>> <https://developer.gnome.org/gstreamer/stable/gstreamer-GstBuffer.html>  
>>> > , you should find everything you need in the linked docs.
>>> 
>>> I'm still confused. Let me explain.
>>> I understand that when appsink has a new frame, it sends "new-sample"
>>> signal. In the callback used for this signal, I'm able to retrieve this
>>> sample, but then I don't know what to do with it. As i said, some uses
>>> the
>>> sample as the data to paint, but I'm not sure this is the right to do. I
>>> know that I can get the buffer from this sample, but I can't find where
>>> I
>>> can then get the pointer to the data, as GstBuffer is a container for
>>> GStreamer.
>>> 
>>> 
>>> 
>>> --
>>> View this message in context:
>>> http://gstreamer-devel.966125.n4.nabble.com/Vaapidecode-Format-and-OpenGL-tp4683302p4683305.html
>>> Sent from the GStreamer-devel mailing list archive at Nabble.com.
>>> _______________________________________________
>>> gstreamer-devel mailing list
>>> 

>> gstreamer-devel at .freedesktop

>>> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>> _______________________________________________
>> gstreamer-devel mailing list

>> gstreamer-devel at .freedesktop

>> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

Is there anyone that knows if it is possible please ?



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Vaapidecode-Format-and-OpenGL-tp4683302p4683536.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list