Mana
Loading...
Searching...
No Matches
Macros | Functions
log.cpp File Reference
#include "log.h"
#include <SDL.h>
#include <cstdarg>
#include <fstream>
#include <iostream>
#include <sstream>
#include <sys/time.h>

Go to the source code of this file.

Macros

#define DEFINE_LOG_FUNCTION(name, priority)
 

Functions

 DEFINE_LOG_FUNCTION (verbose, SDL_LOG_PRIORITY_VERBOSE) DEFINE_LOG_FUNCTION(debug
 
SDL_LOG_PRIORITY_DEBUG DEFINE_LOG_FUNCTION (info, SDL_LOG_PRIORITY_INFO) DEFINE_LOG_FUNCTION(warn
 
SDL_LOG_PRIORITY_DEBUG SDL_LOG_PRIORITY_WARN DEFINE_LOG_FUNCTION (error, SDL_LOG_PRIORITY_ERROR) void Log
 

Macro Definition Documentation

◆ DEFINE_LOG_FUNCTION

#define DEFINE_LOG_FUNCTION (   name,
  priority 
)
Value:
void Log::name(const char *fmt, ...) \
{ \
va_list ap; \
va_start(ap, fmt); \
SDL_LogMessageV(SDL_LOG_CATEGORY_APPLICATION, priority, fmt, ap); \
va_end(ap); \
}

Definition at line 105 of file log.cpp.

Function Documentation

◆ DEFINE_LOG_FUNCTION() [1/3]

SDL_LOG_PRIORITY_DEBUG SDL_LOG_PRIORITY_WARN DEFINE_LOG_FUNCTION ( error  ,
SDL_LOG_PRIORITY_ERROR   
)

Definition at line 118 of file log.cpp.

◆ DEFINE_LOG_FUNCTION() [2/3]

SDL_LOG_PRIORITY_DEBUG DEFINE_LOG_FUNCTION ( info  ,
SDL_LOG_PRIORITY_INFO   
)

◆ DEFINE_LOG_FUNCTION() [3/3]

DEFINE_LOG_FUNCTION ( verbose  ,
SDL_LOG_PRIORITY_VERBOSE   
)