Define btAssert as empty in non-debug builds.
GL_DEPTH_BUFFER_BIT -> GL_DEPTH_TEST, thanks to Mihail Isakov, http://code.google.com/p/bullet/issues/detail?id=86
This commit is contained in:
@@ -725,7 +725,7 @@ convexMesh->getMeshInterface()->InternalProcessAllTriangles(&drawCallback,aabbMi
|
||||
|
||||
|
||||
|
||||
glDisable(GL_DEPTH_BUFFER_BIT);
|
||||
glDisable(GL_DEPTH_TEST);
|
||||
glRasterPos3f(0,0,0);//mvtx.x(), vtx.y(), vtx.z());
|
||||
if (debugMode&btIDebugDraw::DBG_DrawText)
|
||||
{
|
||||
@@ -736,7 +736,7 @@ if (debugMode& btIDebugDraw::DBG_DrawFeaturesText)
|
||||
{
|
||||
//BMF_DrawString(BMF_GetFont(BMF_kHelvetica10),shape->getExtraDebugInfo());
|
||||
}
|
||||
glEnable(GL_DEPTH_BUFFER_BIT);
|
||||
glEnable(GL_DEPTH_TEST);
|
||||
|
||||
// glPopMatrix();
|
||||
if(m_textureenabled) glDisable(GL_TEXTURE_2D);
|
||||
|
||||
@@ -226,7 +226,7 @@ void cullPoints2 (int n, btScalar p[], int m, int i0, int iret[])
|
||||
a = btScalar(j)*(2*M__PI/m) + A[i0];
|
||||
if (a > M__PI) a -= 2*M__PI;
|
||||
btScalar maxdiff=1e9,diff;
|
||||
#ifndef dNODEBUG
|
||||
#if defined(DEBUG) || defined (_DEBUG)
|
||||
*iret = i0; // iret is not allowed to keep this value
|
||||
#endif
|
||||
for (i=0; i<n; i++) {
|
||||
@@ -239,7 +239,7 @@ void cullPoints2 (int n, btScalar p[], int m, int i0, int iret[])
|
||||
}
|
||||
}
|
||||
}
|
||||
#ifndef dNODEBUG
|
||||
#if defined(DEBUG) || defined (_DEBUG)
|
||||
btAssert (*iret != i0); // ensure iret got set
|
||||
#endif
|
||||
avail[*iret] = 0;
|
||||
|
||||
@@ -65,7 +65,11 @@ inline int btGetVersion()
|
||||
#endif //__MINGW32__
|
||||
|
||||
#include <assert.h>
|
||||
#if defined(DEBUG) || defined (_DEBUG)
|
||||
#define btAssert assert
|
||||
#else
|
||||
#define btAssert(x)
|
||||
#endif
|
||||
//btFullAssert is optional, slows down a lot
|
||||
#define btFullAssert(x)
|
||||
|
||||
@@ -116,7 +120,13 @@ inline int btGetVersion()
|
||||
#ifndef assert
|
||||
#include <assert.h>
|
||||
#endif
|
||||
|
||||
#if defined(DEBUG) || defined (_DEBUG)
|
||||
#define btAssert assert
|
||||
#else
|
||||
#define btAssert(x)
|
||||
#endif
|
||||
|
||||
//btFullAssert is optional, slows down a lot
|
||||
#define btFullAssert(x)
|
||||
#define btLikely(_c) _c
|
||||
|
||||
Reference in New Issue
Block a user