mirror of
https://github.com/johndoe6345789/SDL3CPlusPlus.git
synced 2026-04-26 22:54:59 +00:00
Refactor logging and tracing in SDL3 application
- Replaced macro-based logging with a dedicated Logger class for improved readability and maintainability. - Introduced TraceGuard class for automatic function entry/exit logging. - Updated all relevant source files to utilize the new logging and tracing mechanisms. - Consolidated SDL_MAIN_HANDLED definition into a separate header file (sdl_macros.hpp) for better organization. - Ensured consistent logging practices across the application, including error handling and debug information.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
#include "script/shader_manager.hpp"
|
||||
#include "logging/logger.hpp"
|
||||
|
||||
#include <lua.hpp>
|
||||
|
||||
@@ -8,7 +9,9 @@
|
||||
|
||||
namespace sdl3cpp::script {
|
||||
|
||||
ShaderManager::ShaderManager(lua_State* L) : L_(L) {}
|
||||
ShaderManager::ShaderManager(lua_State* L) : L_(L) {
|
||||
sdl3cpp::logging::TraceGuard trace(__PRETTY_FUNCTION__);
|
||||
}
|
||||
|
||||
std::unordered_map<std::string, ShaderManager::ShaderPaths> ShaderManager::LoadShaderPathsMap() {
|
||||
lua_getglobal(L_, "get_shader_paths");
|
||||
|
||||
Reference in New Issue
Block a user