[gst-devel] Getting the complete caps from rtph264pay

Wai-Ming Ho waiming at ailuropoda.net
Wed Jun 3 09:44:57 CEST 2009

On Monday 01 June 2009 21:59:23 Florent wrote:
> > Within the notify::caps callback function try print the caps as below.
> >
> > caps = GST_PAD_CAPS (pad);
> > g_print ("Caps = %s\n, gst_caps_to_string (caps));
> >
> > Refer the link below for more info:
> > http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/G
> >stPad.html#gst-pad-get-caps
> Thanks for the info. However, i use pygst, and the closest equivalent
> i used returned the same caps as when i do get_pad boefore
> negociation.
> Flo

with pygst, you can try set a callback on the pad whose negotiated caps you 
are interested in:


then you define mypad_src_set_caps:

def mypad_src_set_caps(pad, caps):
  capstr = caps.to_string()
  print capstr
  return TRUE

The callback is called just before the buffer is pushed through the pad, when 
the caps is newly negotiated. 


More information about the gstreamer-devel mailing list