/**
* Module descriptor
*/
+#ifndef __PLUGIN__
/* FIXME: scheduled for privatization */
struct module_t
{
vlc_bool_t b_builtin; /* Set to true if the module is built in */
vlc_bool_t b_loaded; /* Set to true if the dll is loaded */
};
+#endif
/*****************************************************************************
* Exported functions.
VLC_MODULE_NAME
};
-VLC_EXPORT( vlc_bool_t, module_IsCapable, ( const module_t *, const char *cap ) );
+VLC_EXPORT( vlc_bool_t, module_IsCapable, ( const module_t *m, const char *cap ) );
+VLC_EXPORT( const char *, module_GetObjName, ( const module_t *m ) );
+VLC_EXPORT( const char *, module_GetName, ( const module_t *m, vlc_bool_t long_name ) );
+
return !strcmp( m->psz_capability, cap );
}
+/*****************************************************************************
+ * module_GetObjName: internal name of a module.
+ *****************************************************************************/
+const char *module_GetObjName( const module_t *m )
+{
+ return m->psz_object_name;
+}
+
+/*****************************************************************************
+ * module_GetName: human-friendly name of a module.
+ *****************************************************************************/
+const char *module_GetName(const module_t *m, vlc_bool_t long_name )
+{
+ if( long_name && ( m->psz_longname != NULL) )
+ return m->psz_longname;
+
+ return m->psz_shortname ?: m->psz_object_name;
+}
+
/*****************************************************************************
* module_Need: return the best module function, given a capability list.
*****************************************************************************