summaryrefslogtreecommitdiff
path: root/gst/gstpad.c
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@collabora.co.uk>2011-11-10 10:58:42 +0100
committerWim Taymans <wim.taymans@collabora.co.uk>2011-11-10 10:58:42 +0100
commit37318a8cd23c61db2dd146047b21a79c140d4207 (patch)
tree1d0de613f9ba9fd4730e572f808947f769274884 /gst/gstpad.c
parentb133bea426fc1239f21dd8b509754a925b5e2066 (diff)
downloadgstreamer-37318a8cd23c61db2dd146047b21a79c140d4207.tar.gz
pad: remove GstPadFixateCapsFunction
The fixate caps function was not used externally and we have vmethods in the base classes where it is needed. Update some docs. simplify some fixate functions in the base classes. Also pass the untruncated caps to the vmethod.
Diffstat (limited to 'gst/gstpad.c')
-rw-r--r--gst/gstpad.c57
1 files changed, 0 insertions, 57 deletions
diff --git a/gst/gstpad.c b/gst/gstpad.c
index 8ac8d98e5e..2b807630fa 100644
--- a/gst/gstpad.c
+++ b/gst/gstpad.c
@@ -142,7 +142,6 @@ static void gst_pad_get_property (GObject * object, guint prop_id,
static GstCaps *gst_pad_get_caps_unlocked (GstPad * pad, GstCaps * filter);
static void gst_pad_set_pad_template (GstPad * pad, GstPadTemplate * templ);
static gboolean gst_pad_activate_default (GstPad * pad);
-static void gst_pad_fixate_caps_default (GstPad * pad, GstCaps * caps);
static GstFlowReturn gst_pad_chain_list_default (GstPad * pad,
GstBufferList * list);
@@ -302,7 +301,6 @@ gst_pad_class_init (GstPadClass * klass)
GST_DEBUG_REGISTER_FUNCPTR (gst_pad_query_default);
GST_DEBUG_REGISTER_FUNCPTR (gst_pad_iterate_internal_links_default);
GST_DEBUG_REGISTER_FUNCPTR (gst_pad_chain_list_default);
- GST_DEBUG_REGISTER_FUNCPTR (gst_pad_fixate_caps_default);
}
static void
@@ -316,7 +314,6 @@ gst_pad_init (GstPad * pad)
GST_PAD_EVENTFUNC (pad) = gst_pad_event_default;
GST_PAD_QUERYFUNC (pad) = gst_pad_query_default;
GST_PAD_ITERINTLINKFUNC (pad) = gst_pad_iterate_internal_links_default;
- GST_PAD_FIXATECAPSFUNC (pad) = gst_pad_fixate_caps_default;
GST_PAD_CHAINLISTFUNC (pad) = gst_pad_chain_list_default;
GST_PAD_SET_FLUSHING (pad);
@@ -1543,26 +1540,6 @@ gst_pad_set_getcaps_function (GstPad * pad, GstPadGetCapsFunction getcaps)
}
/**
- * gst_pad_set_fixatecaps_function:
- * @pad: a #GstPad.
- * @fixatecaps: the #GstPadFixateCapsFunction to set.
- *
- * Sets the given fixatecaps function for the pad. The fixatecaps function
- * will be called whenever the default values for a GstCaps needs to be
- * filled in.
- */
-void
-gst_pad_set_fixatecaps_function (GstPad * pad,
- GstPadFixateCapsFunction fixatecaps)
-{
- g_return_if_fail (GST_IS_PAD (pad));
-
- GST_PAD_FIXATECAPSFUNC (pad) = fixatecaps;
- GST_CAT_DEBUG_OBJECT (GST_CAT_PADS, pad, "fixatecapsfunc set to %s",
- GST_DEBUG_FUNCPTR_NAME (fixatecaps));
-}
-
-/**
* gst_pad_unlink:
* @srcpad: the source #GstPad to unlink.
* @sinkpad: the sink #GstPad to unlink.
@@ -2389,40 +2366,6 @@ no_peer:
}
}
-static void
-gst_pad_fixate_caps_default (GstPad * pad, GstCaps * caps)
-{
- /* default fixation */
- gst_caps_fixate (caps);
-}
-
-/**
- * gst_pad_fixate_caps:
- * @pad: a #GstPad to fixate
- * @caps: the #GstCaps to fixate
- *
- * Fixate a caps on the given pad. Modifies the caps in place, so you should
- * make sure that the caps are actually writable (see gst_caps_make_writable()).
- */
-void
-gst_pad_fixate_caps (GstPad * pad, GstCaps * caps)
-{
- GstPadFixateCapsFunction fixatefunc;
-
- g_return_if_fail (GST_IS_PAD (pad));
- g_return_if_fail (caps != NULL);
- g_return_if_fail (!gst_caps_is_empty (caps));
- g_return_if_fail (!gst_caps_is_any (caps));
-
- if (gst_caps_is_fixed (caps) || gst_caps_is_any (caps))
- return;
-
- g_return_if_fail (gst_caps_is_writable (caps));
-
- if (G_LIKELY ((fixatefunc = GST_PAD_FIXATECAPSFUNC (pad))))
- fixatefunc (pad, caps);
-}
-
/**
* gst_pad_accept_caps:
* @pad: a #GstPad to check