static void type_instance_init (GTypeInstance *instance, gpointer g_class) { GstOmxBaseSrc *self; self = GST_OMX_BASE_SRC (instance); GST_LOG_OBJECT (self, "begin"); self->gomx = gstomx_core_new (self, G_TYPE_FROM_CLASS (g_class)); self->out_port = g_omx_core_new_port (self->gomx, 1); GST_LOG_OBJECT (self, "end"); }
static void type_instance_init (GTypeInstance * instance, gpointer g_class) { GstOmxBaseFilter *self; GstElementClass *element_class; element_class = GST_ELEMENT_CLASS (g_class); self = GST_OMX_BASE_FILTER (instance); GST_LOG_OBJECT (self, "begin"); self->use_timestamps = TRUE; self->gomx = gstomx_core_new (self, G_TYPE_FROM_CLASS (g_class)); self->in_port = g_omx_core_new_port (self->gomx, 0); self->out_port = g_omx_core_new_port (self->gomx, 1); self->ready_lock = g_mutex_new (); self->sinkpad = gst_pad_new_from_template (gst_element_class_get_pad_template (element_class, "sink"), "sink"); gst_pad_set_chain_function (self->sinkpad, pad_chain); gst_pad_set_event_function (self->sinkpad, pad_event); self->srcpad = gst_pad_new_from_template (gst_element_class_get_pad_template (element_class, "src"), "src"); gst_pad_set_activatepush_function (self->srcpad, activate_push); gst_pad_use_fixed_caps (self->srcpad); gst_element_add_pad (GST_ELEMENT (self), self->sinkpad); gst_element_add_pad (GST_ELEMENT (self), self->srcpad); GST_LOG_OBJECT (self, "end"); }
static void type_instance_init (GTypeInstance * instance, gpointer g_class) { GstOmxBaseSink *self; self = GST_OMX_BASE_SINK (instance); GST_LOG_OBJECT (self, "begin"); self->gomx = gstomx_core_new (self, G_TYPE_FROM_CLASS (g_class)); self->in_port = g_omx_core_new_port (self->gomx, 0); { GstPad *sinkpad; self->sinkpad = sinkpad = GST_BASE_SINK_PAD (self); self->base_activatepush = GST_PAD_ACTIVATEPUSHFUNC (sinkpad); gst_pad_set_activatepush_function (sinkpad, activate_push); gst_pad_set_link_function (sinkpad, pad_sink_link); } GST_LOG_OBJECT (self, "end"); }