mirror of
https://github.com/bulletphysics/bullet3.git
synced 2026-09-18 08:14:27 +00:00
clean up reduced body creation
This commit is contained in:
@@ -119,12 +119,7 @@ void ModeVisualizer::initPhysics()
|
||||
|
||||
// create volumetric soft body
|
||||
{
|
||||
std::string filepath("../../../examples/SoftDemo/beam/");
|
||||
std::string filename = filepath + "mesh.vtk";
|
||||
btReducedSoftBody* rsb = btReducedSoftBodyHelpers::createFromVtkFile(getDeformableDynamicsWorld()->getWorldInfo(), filename.c_str());
|
||||
|
||||
rsb->setReducedModes(start_mode, num_modes, rsb->m_nodes.size());
|
||||
btReducedSoftBodyHelpers::readReducedDeformableInfoFromFiles(rsb, filepath.c_str());
|
||||
btReducedSoftBody* rsb = btReducedSoftBodyHelpers::createReducedBeam(getDeformableDynamicsWorld()->getWorldInfo(), start_mode, num_modes);
|
||||
|
||||
getDeformableDynamicsWorld()->addSoftBody(rsb);
|
||||
rsb->getCollisionShape()->setMargin(0.1);
|
||||
|
||||
Reference in New Issue
Block a user