Calculates the 'mass' of an object. :param obj: Compute the mass of this object :param tol: Numerical integration tolerance (optional).
(obj: Shape, tol: float | None = None)
| 814 | |
| 815 | @staticmethod |
| 816 | def computeMass(obj: Shape, tol: float | None = None) -> float: |
| 817 | """ |
| 818 | Calculates the 'mass' of an object. |
| 819 | |
| 820 | :param obj: Compute the mass of this object |
| 821 | :param tol: Numerical integration tolerance (optional). |
| 822 | """ |
| 823 | Properties = GProp_GProps() |
| 824 | calc_function = Shape._mass_calc_function(obj) |
| 825 | |
| 826 | calc_function(obj.wrapped, Properties, *((tol,) if tol else ())) |
| 827 | |
| 828 | return Properties.Mass() |
| 829 | |
| 830 | @staticmethod |
| 831 | def centerOfMass(obj: Shape) -> Vector: |
no test coverage detected