From 907602eab5d6071e0b979807b697e1d3fd6ac6c3 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Wed, 19 Dec 2018 01:20:26 +0200 Subject: libcamera: log: Add a debug log level Many of the message logged by the library will be debug messages, we thus need a debug log level. Signed-off-by: Laurent Pinchart --- src/libcamera/include/log.h | 1 + src/libcamera/log.cpp | 3 +++ 2 files changed, 4 insertions(+) (limited to 'src') diff --git a/src/libcamera/include/log.h b/src/libcamera/include/log.h index 41f8a756..74439848 100644 --- a/src/libcamera/include/log.h +++ b/src/libcamera/include/log.h @@ -12,6 +12,7 @@ namespace libcamera { enum LogSeverity { + LogDebug, LogInfo, LogWarning, LogError, diff --git a/src/libcamera/log.cpp b/src/libcamera/log.cpp index 3715e69d..44b3a5bb 100644 --- a/src/libcamera/log.cpp +++ b/src/libcamera/log.cpp @@ -23,6 +23,8 @@ namespace libcamera { /** * \enum LogSeverity * Log message severity + * \var LogDebug + * Debug message * \var LogInfo * Informational message * \var LogWarning @@ -43,6 +45,7 @@ namespace libcamera { static const char *log_severity_name(LogSeverity severity) { static const char * const names[] = { + " DBG", "INFO", "WARN", " ERR", -- cgit v1.2.1