![]() |
UltraGrid
UltraGrid Low-Latency High-Resolution Transmission System
|
Files | |
| file | module.h |
Classes | |
| struct | module |
| class | module_raii |
Macros | |
| #define | CAST_MODULE(x) |
| #define | MODULE_MAGIC to_fourcc('M', 'O', 'D', ' ') |
Typedefs | |
| typedef void(* | module_deleter_t) (struct module *) |
| typedef void(* | notify_t) (struct module *) |
Functions | |
| void | append_message_path (char *buf, int buflen, const enum module_class *modules) |
| void | dump_parents (struct module *node) |
| void | dump_tree (struct module *root_node, int indent) |
| struct module * | get_matching_child (struct module *node, const char *path) |
| struct module * | get_module (struct module *root, const char *path) |
| struct module * | get_parent_module (struct module *node) |
| struct module * | get_root_module (struct module *node) |
| const char * | module_class_name (enum module_class cls) |
| void | module_done (struct module *module_data) |
| bool | module_get_path_str (struct module *mod, char *buf, size_t buflen) |
| void | module_init_default (struct module *module_data) |
| void | module_register (struct module *module_data, struct module *parent) |
Example:
| #define CAST_MODULE | ( | x | ) |
Definition at line 197 of file module.h.
Referenced by am_participant::~am_participant(), rtp_video_rxtx::~rtp_video_rxtx(), audio_done(), and audio_init().
Definition at line 79 of file module.h.
Referenced by module_done(), and module_init_default().
| enum module_class |
| void append_message_path | ( | char * | buf, |
| int | buflen, | ||
| const enum module_class * | modules ) |
Definition at line 187 of file module.c.
References module_class_name(), and MODULE_CLASS_NONE.
Referenced by BasicRTSPOnlySubsession::deleteStream(), process_msg(), sdp_send_change_address_message(), and BasicRTSPOnlySubsession::startStream().

| void dump_parents | ( | struct module * | node | ) |
Definition at line 348 of file module.c.
References cls, first, get_parent_module(), and module_class_name().
Referenced by module_done().

| void dump_tree | ( | struct module * | root_node, |
| int | indent ) |
Dumps modules' tree.
Definition at line 333 of file module.c.
References children, cls, dump_tree(), lock, module_class_name(), module_mutex_lock(), module_mutex_unlock(), simple_linked_list_it_init(), and simple_linked_list_it_next().
Referenced by dump_tree(), module_done(), and process_msg().

IMPORTANT: module given as parameter should be locked within the calling thread.
| NULL | if not found |
| non-NULL | pointer to the module |
Definition at line 300 of file module.c.
References find_child(), and get_receiver_index().
Referenced by get_module(), module_check_undelivered_messages(), and send_message_common().

| NULL | if not found |
| non-NULL | pointer to the module |
Definition at line 264 of file module.c.
References get_matching_child(), lock, module_mutex_lock(), and module_mutex_unlock().
Referenced by state_controlport_stats::state_controlport_stats(), state_video_decoder::state_video_decoder(), ultragrid_rtp_video_rxtx::ultragrid_rtp_video_rxtx(), audio_decoder_init(), display_sdl_init(), and tx_init().

Definition at line 214 of file module.c.
References parent.
Referenced by dump_parents(), get_module_identifier(), set_fec(), and tx_update().
Returns pointer to root module.
| root | module |
Definition at line 203 of file module.c.
References cls, MODULE_CLASS_ROOT, and parent.
Referenced by keyboard_control::impl::impl(), state_controlport_stats::state_controlport_stats(), state_video_decoder::state_video_decoder(), ultragrid_rtp_video_rxtx::ultragrid_rtp_video_rxtx(), audio_decoder_init(), audio_done(), h264_sdp_video_rxtx::change_address_callback(), display_decklink_init(), display_sdl2_run(), display_sdl_init(), glfw_key_callback(), keycontrol_register_key(), h264_sdp_video_rxtx::send_frame(), h264_sdp_video_rxtx::set_audio_spec(), tx_init(), and vidcap_switcher_register_keyboard_ctl().
| const char * module_class_name | ( | enum module_class | cls | ) |
Definition at line 178 of file module.c.
References cls, and module_class_name_pairs.
Referenced by append_message_path(), dump_parents(), dump_tree(), find_child(), get_module_identifier(), and process_msg().
| void module_done | ( | struct module * | module_data | ) |
Definition at line 93 of file module.c.
References check_message(), children, cls, deleter, dump_parents(), dump_tree(), free_message(), free_message_for_child(), lock, log_level, LOG_LEVEL_VERBOSE, LOG_LEVEL_WARNING, log_msg(), magic, MODULE_CLASS_NONE, MODULE_MAGIC, module_mutex_lock(), module_mutex_unlock(), msg_queue, msg_queue_children, name, parent, simple_linked_list_destroy(), simple_linked_list_it_init(), simple_linked_list_it_next(), simple_linked_list_pop(), simple_linked_list_remove(), and simple_linked_list_size().
Referenced by video_rxtx::video_rxtx(), am_participant::~am_participant(), hd_rum_translator_state::~hd_rum_translator_state(), module_raii::~module_raii(), replica::~replica(), rtp_video_rxtx::~rtp_video_rxtx(), state_gl::~state_gl(), state_sdl::~state_sdl(), state_uv::~state_uv(), state_video_decoder::~state_video_decoder(), video_rxtx::~video_rxtx(), audio_decoder_destroy(), audio_done(), audio_init(), capture_filter_destroy(), capture_filter_init(), cleanup_common(), compress_done(), control_done(), display_done(), display_sdl2_done(), done(), export_destroy(), initialize_video_capture(), initialize_video_display(), keyboard_control::impl::stop(), tx_init(), vidcap_done(), vidcap_file_common_cleanup(), and vidcap_switcher_done().

| bool module_get_path_str | ( | struct module * | mod, |
| char * | buf, | ||
| size_t | buflen ) |
Gets textual representation of path from root to module.
Currently only simple paths are created (class names only)
Definition at line 408 of file module.c.
References get_module_identifier(), and parent.
Referenced by keycontrol_register_key().

| void module_init_default | ( | struct module * | module_data | ) |
Definition at line 48 of file module.c.
References children, lock, magic, MODULE_MAGIC, msg_queue, msg_queue_children, msg_queue_lock, and simple_linked_list_init().
Referenced by keyboard_control::impl::impl(), module_raii::module_raii(), replica::replica(), state_gl::state_gl(), state_sdl::state_sdl(), state_video_decoder::state_video_decoder(), video_rxtx::video_rxtx(), audio_decoder_init(), capture_filter_init(), cineform_compress_init(), compress_init(), control_init(), display_sdl2_init(), export_init(), init(), init_root_module(), initialize_import(), initialize_video_capture(), initialize_video_display(), j2k_compress_init(), tx_init(), vidcap_file_init(), and vidcap_switcher_init().

Definition at line 82 of file module.c.
References children, lock, module_check_undelivered_messages(), module_mutex_lock(), module_mutex_unlock(), parent, parent, and simple_linked_list_append().
Referenced by keyboard_control::impl::impl(), module_raii::module_raii(), replica::replica(), state_gl::state_gl(), state_sdl::state_sdl(), state_video_decoder::state_video_decoder(), video_rxtx::video_rxtx(), audio_decoder_init(), capture_filter_init(), cineform_compress_init(), compress_init(), control_init(), display_sdl2_init(), export_init(), init(), initialize_import(), initialize_video_capture(), initialize_video_display(), j2k_compress_init(), tx_init(), vidcap_file_init(), and vidcap_switcher_init().
