Attacher: fix wrong inertial calculation on solids

was using surface calculation instead of volume...
This commit is contained in:
DeepSOIC 2016-05-08 18:49:07 +03:00
parent 6ffa0c9b37
commit 53bd9b674b

View File

@ -640,7 +640,7 @@ GProp_GProps AttachEngine::getInertialPropsOfShape(const std::vector<const TopoD
throw Base::Exception("AttachEngine::getInertialPropsOfShape: provided shapes are incompatible (not only solids/compsolids)");
if (sh.Infinite())
throw Base::Exception("AttachEngine::getInertialPropsOfShape: infinite shape provided");
BRepGProp::SurfaceProperties(sh,gpr);
BRepGProp::VolumeProperties(sh,gpr);
gpr_acc.Add(gpr);
}
return gpr_acc;