19 #ifndef HEADER_IRR_DEBUG_DRAWER_HPP 
   20 #define HEADER_IRR_DEBUG_DRAWER_HPP 
   22 #include "btBulletDynamicsCommon.h" 
   25 #include "utils/vec3.hpp" 
   40                                     DM_KARTS_PHYSICS     = 0x01,
 
   41                                     DM_NO_KARTS_GRAPHICS = 0x02
 
   45     std::map<video::SColor, std::vector<float> > m_lines;
 
   50     virtual void    setDebugMode(
int debug_mode) {}
 
   56                     { 
return m_debug_mode==DM_NONE ? DBG_NoDebug
 
   60     void            render(
float dt);
 
   62     virtual void    drawLine(
const btVector3& from, 
const btVector3& to,
 
   63                              const btVector3& color);
 
   66                                      const btVector3& normal_on_b,
 
   67                                      btScalar distance,
int life_time,
 
   68                                      const btVector3& color)      {}
 
   69     virtual void    reportErrorWarning(
const char* warningString) {}
 
   70     virtual void    draw3dText(
const btVector3& location,
 
   71                                const char* textString)            {}
 
   77     void            beginNextFrame();
 
   78     const std::map<video::SColor, std::vector<float> >& getLines()
 const { 
return m_lines; }
 
Definition: irr_debug_drawer.hpp:33
 
void nextDebugMode()
Activates the next debug mode, or switches the mode off again.
Definition: irr_debug_drawer.cpp:37
 
virtual void drawContactPoint(const btVector3 &Point_on_b, const btVector3 &normal_on_b, btScalar distance, int life_time, const btVector3 &color)
optional debug methods
Definition: irr_debug_drawer.hpp:65
 
bool debugEnabled() const
Returns true if debug mode is enabled.
Definition: irr_debug_drawer.hpp:73
 
virtual int getDebugMode() const
Callback for bullet: if debug drawing should be done or not.
Definition: irr_debug_drawer.hpp:55
 
virtual void drawLine(const btVector3 &from, const btVector3 &to, const btVector3 &color)
Draws a line.
Definition: irr_debug_drawer.cpp:58
 
DebugModeType
The drawing mode to use: If bit 0 is set, draw the bullet collision shape of karts If bit 1 is set,...
Definition: irr_debug_drawer.hpp:39
 
A wrapper around bullets btVector3 to include conventient conversion functions (e....
Definition: vec3.hpp:35