Add configurable logging backends
This commit is contained in:
parent
0d46f0df12
commit
6269a01b4e
14 changed files with 408 additions and 22 deletions
|
@ -126,7 +126,12 @@ int main(int argc, char** argv) {
|
|||
#endif
|
||||
|
||||
Log::Filter log_filter(Log::Level::Debug);
|
||||
Log::SetFilter(&log_filter);
|
||||
Log::SetGlobalFilter(log_filter);
|
||||
|
||||
Log::AddBackend(std::make_unique<Log::ColorConsoleBackend>());
|
||||
FileUtil::CreateFullPath(FileUtil::GetUserPath(D_LOGS_IDX));
|
||||
Log::AddBackend(
|
||||
std::make_unique<Log::FileBackend>(FileUtil::GetUserPath(D_LOGS_IDX) + LOG_FILE));
|
||||
|
||||
MicroProfileOnThreadCreate("EmuThread");
|
||||
SCOPE_EXIT({ MicroProfileShutdown(); });
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue