From a3633876d7f2a153dce359d915fea08d0228a977 Mon Sep 17 00:00:00 2001 From: Mario Date: Fri, 14 Oct 2016 17:01:38 +1000 Subject: [PATCH] Disable some debug code that slows down the editor to a crawl (compile fails without the debug flags, so this is a temporary workaround) --- plugins/md3model/model.h | 2 +- plugins/model/model.cpp | 2 +- radiant/patch.h | 2 +- radiant/selection.cpp | 4 ++-- radiant/view.h | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/plugins/md3model/model.h b/plugins/md3model/model.h index ee760064..2ed094e1 100644 --- a/plugins/md3model/model.h +++ b/plugins/md3model/model.h @@ -180,7 +180,7 @@ void render( RenderStateFlags state ) const { glEnd(); #endif -#if defined( _DEBUG ) +#if 0 glBegin( GL_LINES ); for ( VertexBuffer::const_iterator i = m_vertices.begin(); i != m_vertices.end(); ++i ) diff --git a/plugins/model/model.cpp b/plugins/model/model.cpp index defa472a..b8df1740 100644 --- a/plugins/model/model.cpp +++ b/plugins/model/model.cpp @@ -113,7 +113,7 @@ void render( RenderStateFlags state ) const { glVertexPointer( 3, GL_FLOAT, sizeof( ArbitraryMeshVertex ), &m_vertices.data()->vertex ); glDrawElements( GL_TRIANGLES, GLsizei( m_indices.size() ), RenderIndexTypeID, m_indices.data() ); -#if defined( _DEBUG ) +#if 0 GLfloat modelview[16]; glGetFloatv( GL_MODELVIEW_MATRIX, modelview ); // I know this is slow as hell, but hey - we're in _DEBUG Matrix4 modelview_inv( diff --git a/radiant/patch.h b/radiant/patch.h index a1f1d272..d122451f 100644 --- a/radiant/patch.h +++ b/radiant/patch.h @@ -317,7 +317,7 @@ void render( RenderStateFlags state ) const { } } -#if defined( _DEBUG ) +#if 0 RenderNormals(); #endif } diff --git a/radiant/selection.cpp b/radiant/selection.cpp index 5013af7b..50da1310 100644 --- a/radiant/selection.cpp +++ b/radiant/selection.cpp @@ -156,7 +156,7 @@ inline float angle_between( const Vector3& a, const Vector3& b ){ } -#if defined( _DEBUG ) +#if 0 class test_quat { public: @@ -463,7 +463,7 @@ void add_one(){ } }; -#if defined( _DEBUG ) +#if 0 #define DEBUG_SELECTION #endif diff --git a/radiant/view.h b/radiant/view.h index 7e8cdf95..5fd1a6e9 100644 --- a/radiant/view.h +++ b/radiant/view.h @@ -26,7 +26,7 @@ #include "math/frustum.h" -#if defined( _DEBUG ) +#if 0 #define DEBUG_CULLING #endif -- 2.39.2