gstpad.override: Take a copy of gst_static_pad_template_get_caps()
authorEdward Hervey <bilboed@bilboed.com>
Fri, 20 Feb 2009 17:29:20 +0000 (18:29 +0100)
committerEdward Hervey <bilboed@bilboed.com>
Fri, 20 Feb 2009 17:29:20 +0000 (18:29 +0100)
commitd66033a19c860039ce4b4fbe0ba25cfa1e6c73ca
tree5a4b1af6446364a9476e1fcd50a8a5105cb93718
parentc4d785bc7b9d41f54b20eee5515b9fdfaa75e726
gstpad.override: Take a copy of gst_static_pad_template_get_caps()

This means that we take a completely new caps for the sole usage of
gst-python. The GstCaps return by gst_static_pad_template_get_caps() are
(surprise) static and therefore will always exist... as long as the
GstStaticPadTemplate (and the factory providing it) still exist.

This solves the case of getting the caps of a static pad template *before*
any element was created using the GstElementFactory. When the factory is
used to create an element, a new factory is created, replacing the old one,
and plainly discarding any static values (including those caps).
gst/gstpad.override