馃摑 Identify and document the use of on_caps_cb_t and on_delete_t callbacks
Summary
Understand better the GstTreeUpdater
mechanisms and add recommendations when some gst
wrappers are made. For example, the methods on_delete_t
and on_caps_cb_t
aren't documented and never called explicitly in the switcher code base.
Motivation
The GstTreeUpdate
is an important helper in the switcher
life cycle, as it is used by a lot of plugins in order to manager their internal InfoTree
. However, this class suffers from lack of documentation that could slow the maintenance efficiency.
As the gst
wrapping is an essential part of switcher
adding recommendation about this kind of helper could improve the stabilization and the extension of its code base and its functionalities. The gst wrapper
is equivalent of all kinds of quiddities that use the gstreamer
library.
Specifically, the methods on_delete_t
and on_caps_cb_t
should be used in order to manage the caps, but they are missing points about their mechanisms:
-
on_caps_cb_t
is called when caps are updated or added? What are its arguments? Is this the caps ID, their full specification? -
on_delete_t
is called when caps are deleted or when the quiddity itself is deleted? Why any argument are passed to this function?
Proposal
- Identify where and why these functions are used
- Understand and improve the document about these callbacks
Impact on already existing code
- Reduce the learning curve about the
switcher
code base - Make new contributions more focus with an easy-to-follow strategy