Example #1
0
static void
gst_arts_init (GstARTS * arts)
{
  arts->sinkpad =
      gst_pad_new_from_template (gst_element_get_pad_template (GST_ELEMENT
          (arts), "sink"), "sink");
  gst_element_add_pad (GST_ELEMENT (arts), arts->sinkpad);

  arts->srcpad =
      gst_pad_new_from_template (gst_element_get_pad_template (GST_ELEMENT
          (arts), "src"), "src");
  gst_element_add_pad (GST_ELEMENT (arts), arts->srcpad);

  gst_element_set_loop_function (GST_ELEMENT (arts), gst_arts_loop);

  arts->wrapper = gst_arts_wrapper_new (arts->sinkpad, arts->srcpad);
}
Example #2
0
static void
gst_artsdsink_init (GstArtsdsink * artsdsink)
{
  artsdsink->sinkpad =
      gst_pad_new_from_template (gst_element_get_pad_template (GST_ELEMENT
          (artsdsink), "sink"), "sink");
  gst_element_add_pad (GST_ELEMENT (artsdsink), artsdsink->sinkpad);
  gst_pad_set_chain_function (artsdsink->sinkpad, gst_artsdsink_chain);
  gst_pad_set_link_function (artsdsink->sinkpad, gst_artsdsink_link);

  artsdsink->connected = FALSE;
  artsdsink->mute = FALSE;
  artsdsink->connect_name = NULL;
}