mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 00:31:13 +00:00
closes #333510.
Original commit message from CVS: * ext/pango/gsttextoverlay.c: (gst_text_overlay_init): * ext/pango/gsttextrender.c: (gst_text_render_init): * gst/adder/gstadder.c: (gst_adder_init): Don't leak padtemplates, patch by Christophe Fergeau, closes #333510.
This commit is contained in:
parent
b57078cd60
commit
66db4c0a0a
4 changed files with 32 additions and 18 deletions
|
@ -1,3 +1,11 @@
|
|||
2006-03-09 Wim Taymans <wim@fluendo.com>
|
||||
|
||||
* ext/pango/gsttextoverlay.c: (gst_text_overlay_init):
|
||||
* ext/pango/gsttextrender.c: (gst_text_render_init):
|
||||
* gst/adder/gstadder.c: (gst_adder_init):
|
||||
Don't leak padtemplates, patch by Christophe Fergeau,
|
||||
closes #333510.
|
||||
|
||||
2006-03-09 Tim-Philipp Müller <tim at centricular dot net>
|
||||
|
||||
* gst/subparse/gstsubparse.c: (gst_subparse_type_find):
|
||||
|
|
|
@ -391,10 +391,12 @@ gst_text_overlay_finalize (GObject * object)
|
|||
static void
|
||||
gst_text_overlay_init (GstTextOverlay * overlay, GstTextOverlayClass * klass)
|
||||
{
|
||||
GstPadTemplate *template;
|
||||
|
||||
/* video sink */
|
||||
overlay->video_sinkpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&video_sink_template_factory), "video_sink");
|
||||
template = gst_static_pad_template_get (&video_sink_template_factory);
|
||||
overlay->video_sinkpad = gst_pad_new_from_template (template, "video_sink");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_getcaps_function (overlay->video_sinkpad,
|
||||
GST_DEBUG_FUNCPTR (gst_text_overlay_getcaps));
|
||||
gst_pad_set_setcaps_function (overlay->video_sinkpad,
|
||||
|
@ -407,9 +409,9 @@ gst_text_overlay_init (GstTextOverlay * overlay, GstTextOverlayClass * klass)
|
|||
|
||||
if (!GST_IS_TIME_OVERLAY_CLASS (klass) && !GST_IS_CLOCK_OVERLAY_CLASS (klass)) {
|
||||
/* text sink */
|
||||
overlay->text_sinkpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&text_sink_template_factory), "text_sink");
|
||||
template = gst_static_pad_template_get (&text_sink_template_factory);
|
||||
overlay->text_sinkpad = gst_pad_new_from_template (template, "text_sink");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_setcaps_function (overlay->text_sinkpad,
|
||||
GST_DEBUG_FUNCPTR (gst_text_overlay_setcaps_txt));
|
||||
gst_pad_set_event_function (overlay->text_sinkpad,
|
||||
|
@ -424,9 +426,9 @@ gst_text_overlay_init (GstTextOverlay * overlay, GstTextOverlayClass * klass)
|
|||
}
|
||||
|
||||
/* (video) source */
|
||||
overlay->srcpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&src_template_factory), "src");
|
||||
template = gst_static_pad_template_get (&src_template_factory);
|
||||
overlay->srcpad = gst_pad_new_from_template (template, "src");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_getcaps_function (overlay->srcpad,
|
||||
GST_DEBUG_FUNCPTR (gst_text_overlay_getcaps));
|
||||
gst_pad_set_event_function (overlay->srcpad,
|
||||
|
|
|
@ -326,18 +326,20 @@ gst_text_render_finalize (GObject * object)
|
|||
static void
|
||||
gst_text_render_init (GstTextRender * render, GstTextRenderClass * klass)
|
||||
{
|
||||
GstPadTemplate *template;
|
||||
|
||||
/* sink */
|
||||
render->sinkpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&sink_template_factory), "sink");
|
||||
template = gst_static_pad_template_get (&sink_template_factory);
|
||||
render->sinkpad = gst_pad_new_from_template (template, "sink");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_chain_function (render->sinkpad,
|
||||
GST_DEBUG_FUNCPTR (gst_text_render_chain));
|
||||
gst_element_add_pad (GST_ELEMENT (render), render->sinkpad);
|
||||
|
||||
/* source */
|
||||
render->srcpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&src_template_factory), "src");
|
||||
template = gst_static_pad_template_get (&src_template_factory);
|
||||
render->srcpad = gst_pad_new_from_template (template, "src");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_fixatecaps_function (render->srcpad,
|
||||
GST_DEBUG_FUNCPTR (gst_text_render_fixate_caps));
|
||||
gst_pad_set_setcaps_function (render->srcpad,
|
||||
|
|
|
@ -272,9 +272,11 @@ gst_adder_class_init (GstAdderClass * klass)
|
|||
static void
|
||||
gst_adder_init (GstAdder * adder)
|
||||
{
|
||||
adder->srcpad =
|
||||
gst_pad_new_from_template (gst_static_pad_template_get
|
||||
(&gst_adder_src_template), "src");
|
||||
GstPadTemplate *template;
|
||||
|
||||
template = gst_static_pad_template_get (&gst_adder_src_template);
|
||||
adder->srcpad = gst_pad_new_from_template (template, "src");
|
||||
gst_object_unref (template);
|
||||
gst_pad_set_getcaps_function (adder->srcpad,
|
||||
GST_DEBUG_FUNCPTR (gst_pad_proxy_getcaps));
|
||||
gst_pad_set_setcaps_function (adder->srcpad,
|
||||
|
|
Loading…
Reference in a new issue