1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
// Logging free functions defined in Logger.cpp
#pragma once
// python style format specified logging
extern void vFLOG(const char * a_Format, fmt::format_args a_ArgList);
template <typename... Args>
void FLOG(const char * a_Format, const Args & ... args)
{
vFLOG(a_Format, fmt::make_format_args(args...));
}
extern void vFLOGINFO(const char * a_Format, fmt::format_args a_ArgList);
template <typename... Args>
void FLOGINFO(const char * a_Format, const Args & ... args)
{
vFLOGINFO(a_Format, fmt::make_format_args(args...));
}
extern void vFLOGWARNING(const char * a_Format, fmt::format_args a_ArgList);
template <typename... Args>
void FLOGWARNING(const char * a_Format, const Args & ... args)
{
vFLOGWARNING(a_Format, fmt::make_format_args(args...));
}
extern void vFLOGERROR(const char * a_Format, fmt::format_args a_ArgList);
template <typename... Args>
void FLOGERROR(const char * a_Format, const Args & ... args)
{
vFLOGERROR(a_Format, fmt::make_format_args(args...));
}
// printf style format specified logging (DEPRECATED)
extern void vLOG(const char * a_Format, fmt::printf_args a_ArgList);
template <typename... Args>
void LOG(const char * a_Format, const Args & ... args)
{
vLOG(a_Format, fmt::make_printf_args(args...));
}
extern void vLOGINFO(const char * a_Format, fmt::printf_args a_ArgList);
template <typename... Args>
void LOGINFO(const char * a_Format, const Args & ... args)
{
vLOGINFO(a_Format, fmt::make_printf_args(args...));
}
extern void vLOGWARNING(const char * a_Format, fmt::printf_args a_ArgList);
template <typename... Args>
void LOGWARNING(const char * a_Format, const Args & ... args)
{
vLOGWARNING(a_Format, fmt::make_printf_args(args...));
}
extern void vLOGERROR(const char * a_Format, fmt::printf_args a_ArgList);
template <typename... Args>
void LOGERROR(const char * a_Format, const Args & ... args)
{
vLOGERROR(a_Format, fmt::make_printf_args(args...));
}
// Macro variants
// In debug builds, translate LOGD to LOG, otherwise leave it out altogether:
#ifdef _DEBUG
#define LOGD LOG
#else
#define LOGD(...)
#endif // _DEBUG
#define LOGWARN LOGWARNING
#ifdef _DEBUG
#define FLOGD FLOG
#else
#define FLOGD(...)
#endif // _DEBUG
#define FLOGWARN FLOGWARNING
|