favreau / bullet

Automatically exported from code.google.com/p/bullet
0 stars 0 forks source link

some issues with the btInternalEdgeUtility #500

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

See discussion here 

http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=4603&p=22317#p22317

and attached repro case

Original issue reported on code.google.com by erwin.coumans on 4 Apr 2011 at 3:45

Attachments:

GoogleCodeExporter commented 9 years ago
I've added code that handles btScaledBvhTriangleMeshShape and a fix that seems 
to work on flat-ish terrains, If finds the closest edge and use it no matter 
how far it really is. I still use m_maxEdgeAngleThreshold, set at about 30 
degrees.

Text formating could be bullet unfriendly.
Regards,
Ales

Original comment by jazz...@gmail.com on 5 Apr 2011 at 9:24

Attachments:

GoogleCodeExporter commented 9 years ago
Hi Ales, patch has been applied in trunk:
http://code.google.com/p/bullet/source/detail?r=2375

Thanks!
Erwin

Original comment by erwin.coumans on 7 Apr 2011 at 6:30

GoogleCodeExporter commented 9 years ago
Hmm, I've done a rewritte of the code and found out that just getting the 
closest edge in the threshold and use that normal with only the 
newNormal.dot(localContactNormalOnB) < 0 test works best.

So the question is what was the reason for all that original code? I must be 
missing something here.

Because now is the first time that I can push a 1m box like a car around a big 
tesselated mesh without any problems at 30hz.

Original comment by jazz...@gmail.com on 7 Apr 2011 at 7:08

GoogleCodeExporter commented 9 years ago
If your modified version works for you that's great. Can you share your final 
version?

The various cases are to handle convex and concave triangle edges, both single 
and double sided. It will be best to add all the various test cases in the 
InternalEdgeDemo.

Did you test above repro case with your code?

Thanks,
Erwin

By the way, I noticed that the latest trunk version of Bullet behaves a bit 
different in the InternalEdgeDemo: it doesn't bounce off the edge even with the 
internal edge utility disabled. This is possibly due to some recent work on 
collision detection.

Original comment by erwin.coumans on 7 Apr 2011 at 4:16

GoogleCodeExporter commented 9 years ago
I re-enabled the m_edgeDistanceThreshold and m_edgeDistanceThreshold in the 
code (I hadn't properly reviewed/tested it). You can set them at a large value 
to disable it, or just use your simplified code path.

Original comment by erwin.coumans on 7 Apr 2011 at 4:47

GoogleCodeExporter commented 9 years ago
The code I've done is basically just the "closest distance to an edge up to an 
distance threshold and within angle threshold" thing with all the 
convex/concave code removed.

I've attached the code, though I'm certain this is incorrect it works.

Also I've noticed that when moving over a mesh from triangle to triangle 
there's lots of contact points that are pretty far away from the body. Not even 
in the shapeA+shapeB margin, why is that?

Original comment by jazz...@gmail.com on 8 Apr 2011 at 1:03

Attachments:

GoogleCodeExporter commented 9 years ago
see https://github.com/bulletphysics/bullet3/issues/144

Original comment by erwin.coumans on 30 Mar 2014 at 7:45