I use Irrlicht + Bullet for a project and noticed strange lines being drawn across my screen when using GLSL shaders.
After some time of debugging i found out that
Code: Select all
virtual void drawLine(const btVector3& from, const btVector3& to, const btVector3& color);
The reason i mentioned the shader is that the lines are not visible if no postprocessing is applied to the scene (but drawLine() gets called nevertheless)
Anyway, the drawLine only gets called if i use DBG_DrawWireframe as drawing mode.
Here's the backtrace
Code: Select all
Breakpoint 1, DebugDraw::drawLine (this=0xb0e1c878, from=..., to=...,
color=...) at ../trunk/source/core/physics/DebugDraw.cpp:30
30 const irr::video::SColorf newColor(color[0], color[1], color[2], color[3]);
(gdb) backtrace
#0 DebugDraw::drawLine (this=0xb0e1c878, from=..., to=..., color=...)
at ../trunk/source/core/physics/DebugDraw.cpp:30
#1 0x08434701 in btConvexTriangleCallback::processTriangle(btVector3*, int, int) ()
#2 0x0840f78f in btBvhTriangleMeshShape::processAllTriangles(btTriangleCallback*, btVector3 const&, btVector3 const&) const::MyNodeOverlapCallback::processNode(int, int) ()
#3 0x0842cf89 in btQuantizedBvh::reportAabbOverlappingNodex(btNodeOverlapCallback*, btVector3 const&, btVector3 const&) const ()
#4 0x0840fdfc in btBvhTriangleMeshShape::processAllTriangles(btTriangleCallback*, btVector3 const&, btVector3 const&) const ()
#5 0x084350bb in btConvexConcaveCollisionAlgorithm::processCollision(btCollisionObject*, btCollisionObject*, btDispatcherInfo const&, btManifoldResult*) ()
#6 0x083ffe83 in btCollisionDispatcher::defaultNearCallback(btBroadphasePair&, btCollisionDispatcher&, btDispatcherInfo const&) ()
#7 0x08400333 in btCollisionPairCallback::processOverlap(btBroadphasePair&) ()
#8 0x083fd54d in btHashedOverlappingPairCache::processAllOverlappingPairs(btOverlapCallback*, btDispatcher*) ()
#9 0x083ff902 in btCollisionDispatcher::dispatchAllCollisionPairs(btOverlappingPairCache*, btDispatcherInfo const&, btDispatcher*) ()
#10 0x084014cd in btCollisionWorld::performDiscreteCollisionDetection() ()
#11 0x083de747 in btDiscreteDynamicsWorld::internalSingleStepSimulation(float) ()
#12 0x083dcb9a in btDiscreteDynamicsWorld::stepSimulation(float, int, float) ()
#13 0x080559d9 in RunningState::onUpdate (this=0xbffff228, game=0xb0e1d2c0)
at ../trunk/source/states/RunningState.cpp:226
#14 0x08078464 in StateManager<Game, irr::SEvent>::onUpdate (this=0xb0e1d2c4)
at ../trunk/source/core/statemanager/StateManager.h:91
#15 0x0807726f in Application::run (this=0xbffff3e8)
at ../trunk/source/core/Application.cpp:179
#16 0x0805a2d5 in main (argc=1, argv=0xbffff4b4) at ../trunk/source/main.cpp:8