Physics Simulation Forum

 

All times are UTC




Post new topic Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Fri Jan 20, 2012 6:56 pm 
Offline

Joined: Fri Oct 14, 2011 11:23 pm
Posts: 5
Hello,

Is there a way to set Bullet's debug drawer to only draw certain meshes? I have a terrain object that uses a height field collision shape, but the mesh is very fine, so the drawer ends up drawing millions of triangles and then lags my entire application. I only want the drawer to draw my small rigid bodies that are moving around a lot. I tried doing a search but I couldn't find anything useful.

Any assistance would be appreciated.

Thanks,
Gavin


Top
 Profile  
 
PostPosted: Sun Jan 22, 2012 8:18 am 
Offline

Joined: Tue Dec 25, 2007 1:06 pm
Posts: 316
GavinL wrote:
I have a terrain object that uses a height field collision shape, but the mesh is very fine, so the drawer ends up drawing millions of triangles and then lags my entire application.
You may try:
Code:
terrainBody->setCollisionFlags(terrainBody->getCollisionFlags()|CF_DISABLE_VISUALIZE_OBJECT);   // Disable debug drawing


Top
 Profile  
 
PostPosted: Sun Jan 22, 2012 8:24 pm 
Offline

Joined: Fri Oct 14, 2011 11:23 pm
Posts: 5
Ah thanks :) works like a charm!


Top
 Profile  
 
PostPosted: Mon Jan 23, 2012 8:46 am 
Offline

Joined: Fri May 13, 2011 1:11 pm
Posts: 62
alternatively, if you are bothered by the normals but want to keep the wireframe try the 1st patch in:

http://code.google.com/p/bullet/issues/ ... 9&sort=-id

/selfpromotion ;P

edit: the 3rd patch also shows bounding boxes for child-shapes in compound shapes, neat for both debugging and debug-drawing :)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC


Who is online

Users browsing this forum: anthrax11 and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group