expose pybullet.URDF_USE_SELF_COLLISION flag, experimental (likely doesn't work well for many URDF files)

This commit is contained in:
Erwin Coumans
2017-04-04 12:47:34 -07:00
parent 239ef81364
commit b095e1d917
4 changed files with 8 additions and 0 deletions

View File

@@ -1810,6 +1810,10 @@ bool PhysicsServerCommandProcessor::loadUrdf(const char* fileName, const btVecto
mb->setUserIndex2(bodyUniqueId);
bodyHandle->m_multiBody = mb;
if (flags & URDF_USE_SELF_COLLISION)
{
mb->setHasSelfCollision(true);
}
createJointMotors(mb);

View File

@@ -451,6 +451,7 @@ enum eCONNECT_METHOD {
enum eURDF_Flags
{
URDF_USE_INERTIA_FROM_FILE=2,//sync with URDF2Bullet.h 'ConvertURDFFlags'
URDF_USE_SELF_COLLISION=8,//see CUF_USE_SELF_COLLISION
};
#endif//SHARED_MEMORY_PUBLIC_H