00001
00002
00003 #ifndef _GSTREAMERMM_ELEMENTFACTORY_H
00004 #define _GSTREAMERMM_ELEMENTFACTORY_H
00005
00006
00007 #include <glibmm.h>
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #include <gst/gstelement.h>
00029 #include <gstreamermm/pluginfeature.h>
00030
00031
00032 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00033 typedef struct _GstElementFactory GstElementFactory;
00034 typedef struct _GstElementFactoryClass GstElementFactoryClass;
00035 #endif
00036
00037
00038 namespace Gst
00039 { class ElementFactory_Class; }
00040 namespace Gst
00041 {
00042
00043 class Caps;
00044 class Element;
00045 class PadTemplate;
00046 class Plugin;
00047
00089 class ElementFactory : public PluginFeature
00090 {
00091
00092 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00093
00094 public:
00095 typedef ElementFactory CppObjectType;
00096 typedef ElementFactory_Class CppClassType;
00097 typedef GstElementFactory BaseObjectType;
00098 typedef GstElementFactoryClass BaseClassType;
00099
00100 private: friend class ElementFactory_Class;
00101 static CppClassType elementfactory_class_;
00102
00103 private:
00104
00105 ElementFactory(const ElementFactory&);
00106 ElementFactory& operator=(const ElementFactory&);
00107
00108 protected:
00109 explicit ElementFactory(const Glib::ConstructParams& construct_params);
00110 explicit ElementFactory(GstElementFactory* castitem);
00111
00112 #endif
00113
00114 public:
00115 virtual ~ElementFactory();
00116
00117 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00118 static GType get_type() G_GNUC_CONST;
00119
00120
00121 static GType get_base_type() G_GNUC_CONST;
00122 #endif
00123
00125 GstElementFactory* gobj() { return reinterpret_cast<GstElementFactory*>(gobject_); }
00126
00128 const GstElementFactory* gobj() const { return reinterpret_cast<GstElementFactory*>(gobject_); }
00129
00131 GstElementFactory* gobj_copy();
00132
00133 private:
00134
00135
00136 public:
00137
00143 static Glib::RefPtr<Gst::ElementFactory> find(const Glib::ustring& name);
00144
00145
00146
00153 Glib::RefPtr<Gst::Element> create_named_element(const Glib::ustring& name);
00154
00155
00161 static Glib::RefPtr<Gst::Element> create_element(const Glib::ustring& factory_name, const Glib::ustring& name);
00162
00170 static Glib::RefPtr<Gst::Element> create_element(const Glib::ustring& factory_name);
00171
00172
00179 GType get_element_type() const;
00180
00184 Glib::ustring get_long_name() const;
00185
00189 Glib::ustring get_kclass() const;
00190
00194 Glib::ustring get_description() const;
00195
00199 Glib::ustring get_author() const;
00200
00204 guint get_num_pad_templates() const;
00205
00209 int get_uri_type() const;
00210
00211
00218 Glib::StringArrayHandle get_uri_protocols() const;
00219
00220
00227 bool has_interface(const Glib::ustring& name) const;
00228
00233 bool can_sink_caps(const Glib::RefPtr<const Gst::Caps>& caps) const;
00234
00239 bool can_src_caps(const Glib::RefPtr<const Gst::Caps>& caps) const;
00240
00241
00245 Glib::ListHandle< Glib::RefPtr<Gst::PadTemplate> > get_static_pad_templates();
00246
00247
00251 Glib::ListHandle< Glib::RefPtr<const Gst::PadTemplate> > get_static_pad_templates() const;
00252
00253
00254 public:
00255
00256 public:
00257
00258 #ifdef GLIBMM_VFUNCS_ENABLED
00259 #endif //GLIBMM_VFUNCS_ENABLED
00260
00261 protected:
00262
00263 #ifdef GLIBMM_VFUNCS_ENABLED
00264 #endif //GLIBMM_VFUNCS_ENABLED
00265
00266
00267 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00268 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00269
00270
00271 };
00272
00273 }
00274
00275
00276 namespace Glib
00277 {
00286 Glib::RefPtr<Gst::ElementFactory> wrap(GstElementFactory* object, bool take_copy = false);
00287 }
00288
00289
00290 #endif
00291