Function oxygengine_physics_2d::prelude::solver::helper::cancel_relative_rotation
source · pub fn cancel_relative_rotation<N, B, H>(
parameters: &IntegrationParameters<N>,
body1: &B,
part1: &(dyn BodyPart<N> + 'static),
handle1: BodyPartHandle<H>,
body2: &B,
part2: &(dyn BodyPart<N> + 'static),
handle2: BodyPartHandle<H>,
anchor1: &OPoint<N, Const<2>>,
anchor2: &OPoint<N, Const<2>>,
rotation1: &Unit<Complex<N>>,
rotation2: &Unit<Complex<N>>,
jacobians: &mut [N]
) -> Option<GenericNonlinearConstraint<N, H>>where
N: RealField + Copy,
B: Body<N> + ?Sized,
H: BodyHandle,
Expand description
Generate position constraints to cancel the relative rotation of two bodies.
All inputs mut be given in world-space.