Querying caps

Andrey Nechypurenko andreynech at googlemail.com
Wed Jul 13 13:32:00 UTC 2016


>> I was trying to follow your suggestion with "notify::caps" (please see
>> my complete python script below). Unfortunately I am still getting ANY
>> as a stringified caps. I am wondering if I am doing something wrong or
>> is there a bug or maybe the signal is not an appropriate mechanism in
>> this particular case and I should try your second suggestion with the
>> probe?
>
> You are using a 'query_caps' function that does a caps query on the pad.
> This will return all the possible caps that the pad can accept, in this case
> (appsink's sinkpad) it will be ANY. You want to use pad.get_current_caps
> (https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#gst-pad-get-current-caps)
> that will return the currently set caps on that pad.

Thank you very much Thiago!
It was exactly my mistake. Now I can see the caps!

Regards,
Andrey.


More information about the gstreamer-devel mailing list