mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-31 20:48:56 +00:00
registry: API: Add gst_{default,}_registry_get_feature_list_cookie()
This returns the internal feature list cookie, which changes every time a feature is added or removed. This can be used by elements to check if they should update their cached feature lists.
This commit is contained in:
parent
1a50186630
commit
039ef83523
4 changed files with 35 additions and 0 deletions
|
@ -1945,6 +1945,7 @@ gst_buffering_mode_get_type
|
|||
GstRegistry
|
||||
gst_registry_get_default
|
||||
gst_registry_get_feature_list
|
||||
gst_registry_get_feature_list_cookie
|
||||
gst_registry_get_feature_list_by_plugin
|
||||
gst_registry_get_path_list
|
||||
gst_registry_get_plugin_list
|
||||
|
@ -1972,6 +1973,7 @@ gst_default_registry_add_path
|
|||
gst_default_registry_find_plugin
|
||||
gst_default_registry_find_feature
|
||||
gst_default_registry_get_plugin_list
|
||||
gst_default_registry_get_feature_list_cookie
|
||||
gst_default_registry_feature_filter
|
||||
<SUBSECTION Standard>
|
||||
GstRegistryClass
|
||||
|
|
|
@ -1653,3 +1653,21 @@ gst_update_registry (void)
|
|||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* gst_registry_get_feature_list_cookie:
|
||||
*
|
||||
* Returns the 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
|
||||
*/
|
||||
guint32
|
||||
gst_registry_get_feature_list_cookie (GstRegistry * registry)
|
||||
{
|
||||
g_return_val_if_fail (GST_IS_REGISTRY (registry), 0);
|
||||
|
||||
return registry->priv->cookie;
|
||||
}
|
||||
|
|
|
@ -107,6 +107,7 @@ GList* gst_registry_feature_filter (GstRegistry *registry,
|
|||
GList * gst_registry_get_feature_list (GstRegistry *registry,
|
||||
GType type);
|
||||
GList * gst_registry_get_feature_list_by_plugin (GstRegistry *registry, const gchar *name);
|
||||
guint32 gst_registry_get_feature_list_cookie (GstRegistry *registry);
|
||||
|
||||
GstPlugin* gst_registry_find_plugin (GstRegistry *registry, const gchar *name);
|
||||
GstPluginFeature* gst_registry_find_feature (GstRegistry *registry, const gchar *name, GType type);
|
||||
|
@ -204,6 +205,19 @@ gboolean gst_registry_xml_write_cache (GstRegistry * registry, const char *lo
|
|||
#define gst_default_registry_feature_filter(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 gchar *feature_name,
|
||||
guint min_major,
|
||||
guint min_minor,
|
||||
|
|
|
@ -827,6 +827,7 @@ EXPORTS
|
|||
gst_registry_get_default
|
||||
gst_registry_get_feature_list
|
||||
gst_registry_get_feature_list_by_plugin
|
||||
gst_registry_get_feature_list_cookie
|
||||
gst_registry_get_path_list
|
||||
gst_registry_get_plugin_list
|
||||
gst_registry_get_type
|
||||
|
|
Loading…
Reference in a new issue