Tech ENABLE_OPENGL_ERROR_LOGGING set as default

This commit is contained in:
enricoturri1966 2021-02-25 13:38:52 +01:00
parent 21b044b556
commit 8f8217723c
3 changed files with 4 additions and 11 deletions

View file

@ -49,9 +49,6 @@
// Enable smoothing of objects normals
#define ENABLE_SMOOTH_NORMALS (0 && ENABLE_2_3_0_ALPHA1)
// Enable error logging for OpenGL calls when SLIC3R_LOGLEVEL >= 5
#define ENABLE_OPENGL_ERROR_LOGGING (1 && ENABLE_2_3_0_ALPHA1)
//====================
// 2.3.0.alpha3 techs

View file

@ -39,12 +39,11 @@
#ifdef HAS_GLSAFE
void glAssertRecentCallImpl(const char* file_name, unsigned int line, const char* function_name)
{
#if defined(NDEBUG) && ENABLE_OPENGL_ERROR_LOGGING
// In release mode, if OpenGL debugging was forced by ENABLE_OPENGL_ERROR_LOGGING, only show
// OpenGL errors if sufficiently high loglevel.
#if defined(NDEBUG)
// In release mode, only show OpenGL errors if sufficiently high loglevel.
if (Slic3r::get_logging_level() < 5)
return;
#endif // ENABLE_OPENGL_ERROR_LOGGING
#endif // NDEBUG
GLenum err = glGetError();
if (err == GL_NO_ERROR)

View file

@ -10,10 +10,7 @@
#include <functional>
#if ENABLE_OPENGL_ERROR_LOGGING || ! defined(NDEBUG)
#define HAS_GLSAFE
#endif
#define HAS_GLSAFE
#ifdef HAS_GLSAFE
extern void glAssertRecentCallImpl(const char *file_name, unsigned int line, const char *function_name);
inline void glAssertRecentCall() { glAssertRecentCallImpl(__FILE__, __LINE__, __FUNCTION__); }