Sfoglia il codice sorgente

Asserts and debug stuff exist in development mode too

Daniele Bartolini 12 anni fa
parent
commit
f1d14221ad
2 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 1 1
      engine/core/Assert.h
  2. 1 1
      engine/renderers/gl/GLRenderer.cpp

+ 1 - 1
engine/core/Assert.h

@@ -31,7 +31,7 @@ OTHER DEALINGS IN THE SOFTWARE.
 #include "Config.h"
 #include "Log.h"
 
-#ifdef CROWN_DEBUG
+#if defined(CROWN_DEBUG) || defined(CROWN_DEVELOPMENT)
 	#define CE_ASSERT(condition, ...) do { if (!(condition)) {\
 		crown::Log::e("Assertion failed: %s", #condition);\
 		crown::Log::e("\t" __VA_ARGS__);\

+ 1 - 1
engine/renderers/gl/GLRenderer.cpp

@@ -60,7 +60,7 @@ static const char* gl_error_to_string(GLenum error)
 }
 
 //-----------------------------------------------------------------------------
-#ifdef CROWN_DEBUG
+#if defined(CROWN_DEBUG) || defined(CROWN_DEVELOPMENT)
 	#define GL_CHECK(function)\
 		function;\
 		do { GLenum error; CE_ASSERT((error = glGetError()) == GL_NO_ERROR,\