image-source: Add a macro for logging info messages
This commit is contained in:
parent
c5b8c744ed
commit
52ff7b9734
@ -1,9 +1,16 @@
|
||||
#include <obs-module.h>
|
||||
|
||||
#define warn(format, ...) \
|
||||
blog(LOG_WARNING, "[image_source: '%s'] " format, \
|
||||
#define blog(log_level, format, ...) \
|
||||
blog(log_level, "[image_source: '%s'] " format, \
|
||||
obs_source_get_name(context->source), ##__VA_ARGS__)
|
||||
|
||||
#define debug(format, ...) \
|
||||
blog(LOG_DEBUG, format, ##__VA_ARGS__)
|
||||
#define info(format, ...) \
|
||||
blog(LOG_INFO, format, ##__VA_ARGS__)
|
||||
#define warn(format, ...) \
|
||||
blog(LOG_WARNING, format, ##__VA_ARGS__)
|
||||
|
||||
struct image_source {
|
||||
obs_source_t *source;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user