diff --git a/assets/main.frag b/assets/main.frag index cd9e9fa..ba65807 100644 --- a/assets/main.frag +++ b/assets/main.frag @@ -12,4 +12,5 @@ void main() { if (col.rgb == vec3(1.0, 0.0, 1.0)) discard; color = col * colortint; + //color = colortint; } diff --git a/src/Main.cpp b/src/Main.cpp index 3aab354..4b35e9c 100644 --- a/src/Main.cpp +++ b/src/Main.cpp @@ -24,8 +24,7 @@ int main(int argc, char* argv[]) { Renderer* renderer; Input* input; - setenv("MESA_DEBUG", "", 0); - SDL_LogSetAllPriority(SDL_LOG_PRIORITY_VERBOSE); + //setenv("MESA_DEBUG", "", 0); Config cfg = Config("dungeon.cfg"); cfg.load(); @@ -39,13 +38,14 @@ int main(int argc, char* argv[]) { int err = 0; err = SDL_Init(SDL_INIT_TIMER | SDL_INIT_VIDEO); + SDL_LogSetAllPriority(SDL_LOG_PRIORITY_DEBUG); if (err != 0) { const char* error = SDL_GetError(); SDL_LogCritical(SDL_LOG_CATEGORY_SYSTEM, "%s", error); SDL_Quit(); return 1; } - SDL_Log("SDL initialized.\n"); + SDL_LogVerbose(SDL_LOG_CATEGORY_SYSTEM,"SDL initialized.\n"); renderer = new Renderer(); if (!renderer->Init("Dungeon", windowWidth, windowHeight)) { diff --git a/src/Renderer.cpp b/src/Renderer.cpp index b5d0bf6..53a3bb9 100644 --- a/src/Renderer.cpp +++ b/src/Renderer.cpp @@ -253,7 +253,7 @@ Texture * Renderer::LoadTexture(std::string path) { mode = GL_RGBA; } - glPixelStorei(GL_UNPACK_ALIGNMENT, 1); + glPixelStorei(GL_UNPACK_ALIGNMENT, 4); glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); glPixelStorei(GL_UNPACK_SKIP_ROWS, 0);