From 343ce367077777dab463816a0d1c5bb9bee9c837 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Tue, 25 Oct 2022 16:57:42 +0200 Subject: a --- editor/draw.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'editor') diff --git a/editor/draw.cpp b/editor/draw.cpp index 52b3af2e..f15a93af 100644 --- a/editor/draw.cpp +++ b/editor/draw.cpp @@ -1,5 +1,6 @@ #include "app.hpp" #include "floormat/main.hpp" +#include "floormat/settings.hpp" #include "shaders/tile.hpp" #include @@ -45,7 +46,12 @@ void app::draw_msaa() void app::draw() { + const bool debug = M->settings().gpu_debug >= fm_gpu_debug::on; + if (debug) + GL::DebugOutput::setEnabled(GL::DebugOutput::Source::Api, GL::DebugOutput::Type::Other, {131185}, false); // nvidia krap render_menu(); + if (debug) + GL::DebugOutput::setEnabled(GL::DebugOutput::Source::Api, GL::DebugOutput::Type::Other, {131185}, true); // nvidia krap } } // namespace floormat -- cgit v1.2.3