A context for controlling logging behavior, for example to handle
logging once or periodic logging, avoiding to
spam the terminal with the same log message multiple times.
Simple log context using static macros
// At global/file scope: GST_LOG_CONTEXT_STATIC_DEFINE(my_context, GST_LOG_CONTEXT_FLAG_THROTTLE, ); #define MY_CONTEXT GST_LOG_CONTEXT_LAZY_INIT(my_context)
// Then in code: GST_CTX_INFO(MY_CONTEXT, "This will only appear once per file/line");
Periodic logging
For messages that should be logged periodically (e.g., maximum once per minute):
A context for controlling logging behavior, for example to handle logging once or periodic logging, avoiding to spam the terminal with the same log message multiple times.
Simple log context using static macros
Periodic logging
For messages that should be logged periodically (e.g., maximum once per minute):
Customizing Message hash with custom flags and category
By default, a message's hash is determined by the file name, object pointer, and format string. You can customize this with builder operations:
Since
1.28