17 #include "elementfactory.h"
24 ElementFactoryPtr ElementFactory::find(
const char *factoryName)
30 ElementPtr ElementFactory::make(
const char *factoryName,
const char *elementName)
32 GstElement *e = gst_element_factory_make(factoryName, elementName);
34 gst_object_ref_sink(e);
41 return gst_element_factory_get_element_type(object<GstElementFactory>());
44 QString ElementFactory::metadata(
const char *key)
const
46 return QString::fromUtf8(gst_element_factory_get_metadata(object<GstElementFactory>(), key));
49 uint ElementFactory::padTemplatesCount()
const
51 return gst_element_factory_get_num_pad_templates(object<GstElementFactory>());
54 int ElementFactory::uriType()
const
56 return gst_element_factory_get_uri_type(object<GstElementFactory>());
59 bool ElementFactory::hasInterface(
const char *interfaceName)
const
61 return gst_element_factory_has_interface(object<GstElementFactory>(), interfaceName);
64 bool ElementFactory::canSinkAllCaps(
const CapsPtr & caps)
const
66 return gst_element_factory_can_sink_all_caps(object<GstElementFactory>(), caps);
69 bool ElementFactory::canSrcAllCaps(
const CapsPtr & caps)
const
71 return gst_element_factory_can_src_all_caps(object<GstElementFactory>(), caps);
74 bool ElementFactory::canSinkAnyCaps(
const CapsPtr & caps)
const
76 return gst_element_factory_can_sink_any_caps(object<GstElementFactory>(), caps);
79 bool ElementFactory::canSrcAnyCaps(
const CapsPtr & caps)
const
81 return gst_element_factory_can_src_any_caps(object<GstElementFactory>(), caps);
84 ElementPtr ElementFactory::create(
const char *elementName)
const
86 GstElement *e = gst_element_factory_create(object<GstElementFactory>(), elementName);
88 gst_object_ref_sink(e);
static RefPointer< T > wrap(typename T::CType *nativePtr, bool increaseRef=true)
Wrappers for GStreamer classes.