gstregistry.h   gstregistry.h 
skipping to change at line 26 skipping to change at line 26
* *
* You should have received a copy of the GNU Library General Public * You should have received a copy of the GNU Library General Public
* License along with this library; if not, write to the * License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA. * Boston, MA 02111-1307, USA.
*/ */
#ifndef __GST_REGISTRY_H__ #ifndef __GST_REGISTRY_H__
#define __GST_REGISTRY_H__ #define __GST_REGISTRY_H__
#include <stdio.h> /* FIXME: because of cache_file below */
#include <gst/gstconfig.h> #include <gst/gstconfig.h>
#include <gst/gstplugin.h> #include <gst/gstplugin.h>
#include <gst/gstpluginfeature.h> #include <gst/gstpluginfeature.h>
G_BEGIN_DECLS G_BEGIN_DECLS
#define GST_TYPE_REGISTRY (gst_registry_get_type ()) #define GST_TYPE_REGISTRY (gst_registry_get_type ())
#define GST_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_REGISTRY, GstRegistry)) #define GST_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_REGISTRY, GstRegistry))
#define GST_IS_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_REGISTRY)) #define GST_IS_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_REGISTRY))
#define GST_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), G ST_TYPE_REGISTRY, GstRegistryClass)) #define GST_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), G ST_TYPE_REGISTRY, GstRegistryClass))
#define GST_IS_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), G ST_TYPE_REGISTRY)) #define GST_IS_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), G ST_TYPE_REGISTRY))
#define GST_REGISTRY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), G ST_TYPE_REGISTRY, GstRegistryClass)) #define GST_REGISTRY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), G ST_TYPE_REGISTRY, GstRegistryClass))
typedef struct _GstRegistry GstRegistry; typedef struct _GstRegistry GstRegistry;
typedef struct _GstRegistryClass GstRegistryClass; typedef struct _GstRegistryClass GstRegistryClass;
typedef struct _GstRegistryPrivate GstRegistryPrivate;
/** /**
* GstRegistry: * GstRegistry:
* *
* Opaque #GstRegistry structure. * Opaque #GstRegistry structure.
*/ */
struct _GstRegistry { struct _GstRegistry {
GstObject object; GstObject object;
/*< private >*/ /*< private >*/
GList *plugins; GList *plugins;
GList *features; GList *features;
GList *paths; GList *paths;
/* FIXME move these elsewhere */ /* FIXME move these elsewhere */
int cache_file; int cache_file;
/* hash to speedup _lookup_feature_locked() */ /* hash to speedup _lookup_feature_locked() */
GHashTable *feature_hash; GHashTable *feature_hash;
/* hash to speedup _lookup */
GHashTable *basename_hash;
GstRegistryPrivate *priv;
/*< private >*/ /*< private >*/
gpointer _gst_reserved[GST_PADDING-1]; gpointer _gst_reserved[GST_PADDING-3];
}; };
struct _GstRegistryClass { struct _GstRegistryClass {
GstObjectClass parent_class; GstObjectClass parent_class;
/* signals */ /* signals */
void (*plugin_added) (GstRegistry *regist ry, GstPlugin *plugin); void (*plugin_added) (GstRegistry *regist ry, GstPlugin *plugin);
void (*feature_added) (GstRegistry *regist ry, GstPluginFeature *feature); void (*feature_added) (GstRegistry *regist ry, GstPluginFeature *feature);
/*< private >*/ /*< private >*/
skipping to change at line 104 skipping to change at line 108
GstPluginFilter fil ter, GstPluginFilter fil ter,
gboolean first, gboolean first,
gpointer user_data) ; gpointer user_data) ;
GList* gst_registry_feature_filter (GstRegistry *regist ry, GList* gst_registry_feature_filter (GstRegistry *regist ry,
GstPluginFeatureFil ter filter, GstPluginFeatureFil ter filter,
gboolean first, gboolean first,
gpointer user_data) ; gpointer user_data) ;
GList * gst_registry_get_feature_list (GstRegistry *regis try, GList * gst_registry_get_feature_list (GstRegistry *regis try,
GType type); GType type);
GList * gst_registry_get_feature_list_by_plugin (GstRegistr y *registry, const gchar *name); GList * gst_registry_get_feature_list_by_plugin (GstRegistr y *registry, const gchar *name);
guint32 gst_registry_get_feature_list_cookie (GstRegistry * registry);
GstPlugin* gst_registry_find_plugin (GstRegistry *regist ry, const gchar *name); GstPlugin* gst_registry_find_plugin (GstRegistry *regist ry, const gchar *name);
GstPluginFeature* gst_registry_find_feature (GstRegistry *regist ry, const gchar *name, GType type); GstPluginFeature* gst_registry_find_feature (GstRegistry *regist ry, const gchar *name, GType type);
GstPlugin * gst_registry_lookup (GstRegistry *regist ry, const char *filename); GstPlugin * gst_registry_lookup (GstRegistry *regist ry, const char *filename);
GstPluginFeature * gst_registry_lookup_feature (GstRegistry *regist ry, const char *name); GstPluginFeature * gst_registry_lookup_feature (GstRegistry *regist ry, const char *name);
/* FIXME 0.11: do we really want to export these? (If yes, we should add a /* These are only here because at some point they were in a public header
GError argument) */ * (even though they should have been private) and we can't really remove
* them now (FIXME: 0.11). They don't do anything other than return FALSE.
*/
#ifndef GST_DISABLE_DEPRECATED
gboolean gst_registry_xml_read_cache (GstRegistry * regis try, const char *location); gboolean gst_registry_xml_read_cache (GstRegistry * regis try, const char *location);
gboolean gst_registry_xml_write_cache (GstRegistry * regis try, const char *location); gboolean gst_registry_xml_write_cache (GstRegistry * regis try, const char *location);
#endif
/* convinience defines for the default registry */ /* convinience defines for the default registry */
/** /**
* gst_default_registry_add_plugin: * gst_default_registry_add_plugin:
* @plugin: the plugin to add * @plugin: (transfer full): the plugin to add
* *
* Add the plugin to the default registry. * Add the plugin to the default registry.
* The plugin-added signal will be emitted. * The plugin-added signal will be emitted.
* *
* Returns: TRUE on success. * Returns: TRUE on success.
*/ */
#define gst_default_registry_add_plugin(plugin) \ #define gst_default_registry_add_plugin(plugin) \
gst_registry_add_plugin (gst_registry_get_default(), plugin) gst_registry_add_plugin (gst_registry_get_default(), plugin)
/** /**
skipping to change at line 145 skipping to change at line 154
* added, do nothing. * added, do nothing.
*/ */
#define gst_default_registry_add_path(path) \ #define gst_default_registry_add_path(path) \
gst_registry_add_path (gst_registry_get_default(), path) gst_registry_add_path (gst_registry_get_default(), path)
/** /**
* gst_default_registry_get_path_list: * gst_default_registry_get_path_list:
* *
* Get the list of paths for the default registry. * Get the list of paths for the default registry.
* *
* Returns: A Glist of paths as strings. g_list_free after use. * Returns: (transfer container) (element-type char*): a #GList of paths as
* strings. g_list_free() after use.
*/ */
#define gst_default_registry_get_path_list() \ #define gst_default_registry_get_path_list() \
gst_registry_get_path_list (gst_registry_get_default()) gst_registry_get_path_list (gst_registry_get_default())
/** /**
* gst_default_registry_get_plugin_list: * gst_default_registry_get_plugin_list:
* *
* Get a copy of all plugins registered in the default registry. * Get a copy of all plugins registered in the default registry.
* *
* Returns: a copy of the list. Free after use. * Returns: (transfer full) (element-type Gst.Plugin): a copy of the list.
* Free after use.
*/ */
#define gst_default_registry_get_plugin_list() \ #define gst_default_registry_get_plugin_list() \
gst_registry_get_plugin_list (gst_registry_get_default()) gst_registry_get_plugin_list (gst_registry_get_default())
/** /**
* gst_default_registry_find_feature: * gst_default_registry_find_feature:
* @name: the pluginfeature name to find * @name: the pluginfeature name to find
* @type: the pluginfeature type to find * @type: the pluginfeature type to find
* *
* Find the pluginfeature with the given name and type in the default regis try. * Find the pluginfeature with the given name and type in the default regis try.
* *
* Returns: The pluginfeature with the given name and type or NULL * Returns: (transfer full): the pluginfeature with the given name and type
* if the plugin was not found. or
* NULL if the plugin was not found.
*/ */
#define gst_default_registry_find_feature(name,type) \ #define gst_default_registry_find_feature(name,type) \
gst_registry_find_feature (gst_registry_get_default(),name,type) gst_registry_find_feature (gst_registry_get_default(),name,type)
/** /**
* gst_default_registry_find_plugin: * gst_default_registry_find_plugin:
* @name: the plugin name to find * @name: the plugin name to find
* *
* Find the plugin with the given name in the default registry. * Find the plugin with the given name in the default registry.
* The plugin will be reffed; caller is responsible for unreffing. * The plugin will be reffed; caller is responsible for unreffing.
* *
* Returns: The plugin with the given name or NULL if the plugin was not fo * Returns: (transfer full): The plugin with the given name or NULL if the
und. * plugin was not found.
*/ */
#define gst_default_registry_find_plugin(name) \ #define gst_default_registry_find_plugin(name) \
gst_registry_find_plugin (gst_registry_get_default(),name) gst_registry_find_plugin (gst_registry_get_default(),name)
/** /**
* gst_default_registry_feature_filter: * gst_default_registry_feature_filter:
* @filter: the filter to use * @filter: the filter to use
* @first: only return first match * @first: only return first match
* @user_data: user data passed to the filter function * @user_data: user data passed to the filter function
* *
* Runs a filter against all features of the plugins in the default registr y * Runs a filter against all features of the plugins in the default registr y
* and returns a GList with the results. * and returns a GList with the results.
* If the first flag is set, only the first match is * If the first flag is set, only the first match is
* returned (as a list with a single object). * returned (as a list with a single object).
* *
* Returns: a GList of plugin features, gst_plugin_feature_list_free after * Returns: (transfer full) (element-type Gst.PluginFeature): a #GList of
use. * plugin features, gst_plugin_feature_list_free after use.
*/ */
#define gst_default_registry_feature_filter(filter,first,user_data) \ #define gst_default_registry_feature_filter(filter,first,user_data) \
gst_registry_feature_filter (gst_registry_get_default(),filter,first,user _data) gst_registry_feature_filter (gst_registry_get_default(),filter,first,user _data)
/**
* gst_default_registry_get_feature_list_cookie:
*
* Returns the default registrys feature list cookie. This changes
* every time a feature is added or removed from the registry.
*
* Returns: the feature list cookie.
*
* Since: 0.10.26
*/
#define gst_default_registry_get_feature_list_cookie() \
gst_registry_get_feature_list_cookie (gst_registry_get_default())
gboolean gst_default_registry_check_feature_version (const g char *feature_name, gboolean gst_default_registry_check_feature_version (const g char *feature_name,
guint min_major, guint min_major,
guint min_minor, guint min_minor,
guint min_micro); guint min_micro);
G_END_DECLS G_END_DECLS
#endif /* __GST_REGISTRY_H__ */ #endif /* __GST_REGISTRY_H__ */
 End of changes. 14 change blocks. 
13 lines changed or deleted 38 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/