diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-25 16:57:42 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2022-10-25 16:57:42 +0200 |
commit | 343ce367077777dab463816a0d1c5bb9bee9c837 (patch) | |
tree | cdbe30101390b9989ce456346b013c313cb0b207 /editor/draw.cpp | |
parent | 0d97856bf6974450a8e72816be7bf271af04a458 (diff) |
a
Diffstat (limited to 'editor/draw.cpp')
-rw-r--r-- | editor/draw.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
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 <Magnum/GL/DebugOutput.h> @@ -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 |