Engine
Frameworkcreatedbymeusableforthecreationofsimplegames.CurrentlysupportsOpenGL(Verysimple)andVulkan.
Logging.hpp
Go to the documentation of this file.
1 #pragma once
2 #include "Engine/api.hpp"
3 #include <ThirdParty/EASTL-master/include/EASTL/string.h>
4 
5 #ifdef _DEBUG
6 #define COUT_LOGGING
7 #endif
8 
9 // comment to disable info, warning or debug.
10 #define DEBUG_INFO_ENABLED
11 #define DEBUG_WARNING_ENABLED
12 #define DEBUG_ERROR_ENABLED
13 
14 #define log_path "engine.log"
15 
16 void ENGINE_API doDebug(eastl::string Type, eastl::string debugClass, eastl::string function, eastl::string value);
17 
18 /* example: debug_warning("ResourceManager","GetFile()","File not found"); */
19 
29 #if defined(DEBUG_ERROR_ENABLED)
30 #define debug_error(debug_class, function, value) doDebug("[ERROR]", debug_class, function, value);
31 #else
32 #define debug_error(debug_class, function, value) {}
33 #endif
34 
35 
44 #if defined(DEBUG_WARNING_ENABLED)
45 #define debug_warning(debug_class, function, value) doDebug("[WARNING]", debug_class, function, value);
46 #else
47 #define debug_warning(debug_class, function, value) {}
48 #endif
49 
59 #if defined(DEBUG_INFO_ENABLED)
60 #define debug_info(debug_class, function, value) doDebug("[INFO]", debug_class, function, value);
61 #else
62 #define debug_info(debug_class, function, value) {}
63 #endif
#define ENGINE_API
Definition: api.hpp:25
void ENGINE_API doDebug(eastl::string Type, eastl::string debugClass, eastl::string function, eastl::string value)
Definition: Logging.cpp:12