libgpac
Documentation of the core library of GPAC
|
#include "module_wrap.h"
#include <gpac/config_file.h>
#include <gpac/tools.h>
#include <gpac/network.h>
#include <gpac/modules/video_out.h>
#include <gpac/modules/audio_out.h>
#include <gpac/modules/font.h>
Macros | |
#define | LOAD_PLUGIN(__name) |
Functions | |
static void | load_all_modules (GF_ModuleManager *mgr) |
GF_EXPORT GF_Err | gf_module_load_static (GF_InterfaceRegister *(*register_module)()) |
load a static module given its interface function More... | |
u32 | gf_modules_refresh (GF_ModuleManager *pm) |
static void | gf_modules_check_load () |
void | gf_modules_refresh_module_directories () |
void | gf_modules_new (GF_Config *config) |
module manager construtcor More... | |
void | gf_module_reload_dirs () |
void | gf_modules_del () |
module manager destructor More... | |
Bool | gf_module_is_loaded (GF_ModuleManager *pm, char *filename) |
GF_EXPORT u32 | gf_modules_count () |
get module count More... | |
GF_EXPORT GF_BaseInterface * | gf_modules_load (u32 whichplug, u32 InterfaceFamily) |
loads an interface More... | |
void * | gf_modules_load_filter (u32 whichplug, void *fsess) |
filter module load More... | |
GF_EXPORT GF_BaseInterface * | gf_modules_load_by_name (const char *plug_name, u32 InterfaceFamily, Bool rebrowse_all) |
loads an interface by module name More... | |
GF_EXPORT GF_Err | gf_modules_close_interface (GF_BaseInterface *ifce) |
interface shutdown More... | |
GF_EXPORT const char * | gf_modules_get_file_name (u32 i) |
get module file name More... | |
GF_EXPORT const char * | gf_module_get_file_name (GF_BaseInterface *ifce) |
get module file name More... | |
static Bool | module_check_ifce (GF_BaseInterface *ifce, u32 ifce_type) |
GF_BaseInterface * | gf_module_load (u32 ifce_type, const char *name) |
module load More... | |
GF_EXPORT const char * | gf_module_get_key (GF_BaseInterface *dr, char *key_name) |
query module option More... | |
GF_EXPORT Bool | gf_module_get_bool (GF_BaseInterface *dr, char *key_name) |
query module option as boolean More... | |
GF_EXPORT Bool | gf_module_get_int (GF_BaseInterface *dr, char *key_name) |
query module option as int More... | |
Variables | |
GF_ModuleManager * | gpac_modules_static = NULL |
#define LOAD_PLUGIN | ( | __name | ) |
|
static |
GF_EXPORT GF_Err gf_module_load_static | ( | GF_InterfaceRegister *(*)() | register_module | ) |
register_module | the register interface function |
u32 gf_modules_refresh | ( | GF_ModuleManager * | pm | ) |
|
static |
void gf_modules_refresh_module_directories | ( | ) |
void gf_modules_new | ( | GF_Config * | config | ) |
Constructs a module manager object.
config | GPAC configuration file handle. If this is NULL, the modules won't be able to share the configuration file with the rest of the GPAC framework. |
void gf_module_reload_dirs | ( | ) |
void gf_modules_del | ( | ) |
Destroys the module manager
Bool gf_module_is_loaded | ( | GF_ModuleManager * | pm, |
char * | filename | ||
) |
Gets the number of modules found in the manager directory
GF_EXPORT GF_BaseInterface* gf_modules_load | ( | u32 | index, |
u32 | InterfaceFamily | ||
) |
Loads an interface in the desired module.
index | the 0-based index of the module to load the interface from |
InterfaceFamily | type of the interface to load |
void* gf_modules_load_filter | ( | u32 | index, |
void * | fsess | ||
) |
Loads a filter module (not using GF_BaseInterface) from its index. Returns NULL if no such filter.
index | index of the filter module to load |
fsess | opaque handle passed to the filter loader |
GF_EXPORT GF_BaseInterface* gf_modules_load_by_name | ( | const char * | mod_name, |
u32 | InterfaceFamily, | ||
Bool | rebrowse_all | ||
) |
Loads an interface in the desired module
mod_name | the name of the module (shared library file) or of the interface as declared when registered. |
InterfaceFamily | type of the interface to load |
rebrowse_all | if GF_TRUE, locate an interface for this type if not found by name |
GF_EXPORT GF_Err gf_modules_close_interface | ( | GF_BaseInterface * | interface_obj | ) |
Closes an interface
interface_obj | the interface to close |
Gets a module shared library file name based on its index
index | the 0-based index of the module to query |
GF_EXPORT const char* gf_module_get_file_name | ( | GF_BaseInterface * | ifce | ) |
Gets a module shared library file name based on its index
ifce | the module instance to query |
|
static |
GF_BaseInterface* gf_module_load | ( | u32 | ifce_type, |
const char * | name | ||
) |
Loads a module based on a preferred name. If not found, check for predefined names for the given interface type in fthe global config and loads by predefined name. If still not found, enumerate modules.
ifce_type | type of module interface to load |
name | name of preferred module |
GF_EXPORT const char* gf_module_get_key | ( | GF_BaseInterface * | ifce, |
char * | key | ||
) |
Loads a key from config in the module options.
ifce | the module instance to query |
key | the key to query |
GF_EXPORT Bool gf_module_get_bool | ( | GF_BaseInterface * | ifce, |
char * | key_name | ||
) |
Loads a boolean key from config in the module options.
ifce | the module instance to query |
key_name | the key to query |
GF_EXPORT Bool gf_module_get_int | ( | GF_BaseInterface * | ifce, |
char * | key_name | ||
) |
Loads an integer key from config in the module options.
ifce | the module instance to query |
key_name | the key to query |
GF_ModuleManager* gpac_modules_static = NULL |