18 #if !defined(__AI_FILE__)
19 #define __AI_FILE__ __FILE__
21 #if !defined(__AI_LINE__)
22 #define __AI_LINE__ __LINE__
24 #if !defined(__AI_FUNCTION__)
25 #define __AI_FUNCTION__ __FUNCTION__
31 #define AI_SEVERITY_INFO 0x00
32 #define AI_SEVERITY_WARNING 0x01
33 #define AI_SEVERITY_ERROR 0x02
34 #define AI_SEVERITY_FATAL 0x03
41 #define AI_LOG_NONE 0x0000
42 #define AI_LOG_INFO 0x0001
43 #define AI_LOG_WARNINGS 0x0002
44 #define AI_LOG_ERRORS 0x0004
45 #define AI_LOG_DEBUG 0x0008
46 #define AI_LOG_STATS 0x0010
47 #define AI_LOG_ASS_PARSE 0x0020
48 #define AI_LOG_PLUGINS 0x0040
49 #define AI_LOG_PROGRESS 0x0080
50 #define AI_LOG_NAN 0x0100
51 #define AI_LOG_TIMESTAMP 0x0200
52 #define AI_LOG_BACKTRACE 0x0400
53 #define AI_LOG_MEMORY 0x0800
54 #define AI_LOG_COLOR 0x1000
55 #define AI_LOG_SSS 0x2000
58 ( AI_LOG_INFO | AI_LOG_WARNINGS | AI_LOG_ERRORS | \
59 AI_LOG_DEBUG | AI_LOG_STATS | AI_LOG_PLUGINS | \
60 AI_LOG_PROGRESS | AI_LOG_NAN | AI_LOG_ASS_PARSE | \
61 AI_LOG_TIMESTAMP | AI_LOG_BACKTRACE | AI_LOG_MEMORY | \
62 AI_LOG_COLOR | AI_LOG_SSS)
65 #ifndef AI_PRINTF_ARGS
74 # define AI_PRINTF_ARGS(fmtarg_pos, vararg_pos) __attribute__ ((format (printf, fmtarg_pos, vararg_pos) ))
76 # define AI_PRINTF_ARGS(fmtarg_pos, vararg_pos)
81 typedef void (*
AtMsgCallBack)(
int logmask,
int severity,
const char* msg_string,
int tabs);
90 AI_API
void AiMsgInfo(
const char* format, ...) AI_PRINTF_ARGS(1,2);
91 AI_API
void AiMsgDebug(const
char* format, ...) AI_PRINTF_ARGS(1,2);
92 AI_API
void AiMsgWarning(const
char* format, ...) AI_PRINTF_ARGS(1,2);
93 AI_API
void AiMsgError(const
char* format, ...) AI_PRINTF_ARGS(1,2);
94 AI_API
void AiMsgFatal(const
char* format, ...) AI_PRINTF_ARGS(1,2);