Add API to set bunny properties. Add example to show coupling between softbody and multibody.

This commit is contained in:
yunfeibai
2016-11-01 16:45:10 -07:00
parent 9d54f0cf8d
commit 3c37db0804
10 changed files with 115 additions and 8 deletions

View File

@@ -1000,8 +1000,11 @@ void b3RobotSimAPI::getLinkState(int bodyUniqueId, int linkIndex, double* worldP
}
}
void b3RobotSimAPI::loadBunny()
void b3RobotSimAPI::loadBunny(double scale, double mass, double collisionMargin)
{
b3SharedMemoryCommandHandle command = b3LoadBunnyCommandInit(m_data->m_physicsClient);
b3LoadBunnySetScale(command, scale);
b3LoadBunnySetMass(command, mass);
b3LoadBunnySetCollisionMargin(command, collisionMargin);
b3SubmitClientCommand(m_data->m_physicsClient, command);
}
}