Rotates the unit vector from toward the unit vector to by at most maxAngle radians.
When the two are already within maxAngle this copies to, so the function doubles as a
cone clamp: the result is to, limited to lie within maxAngle of from. That is the form
a rotor joint limit and a per-frame turn rate both want.
Both inputs are assumed to be unit length, and the result is unit length. maxAngle is treated
as 0 if negative. When the inputs are exactly antiparallel the rotation plane is undefined
and an arbitrary perpendicular is used.
Rotates the unit vector
fromtoward the unit vectortoby at mostmaxAngleradians.When the two are already within
maxAnglethis copiesto, so the function doubles as a cone clamp: the result isto, limited to lie withinmaxAngleoffrom. That is the form a rotor joint limit and a per-frame turn rate both want.Both inputs are assumed to be unit length, and the result is unit length.
maxAngleis treated as 0 if negative. When the inputs are exactly antiparallel the rotation plane is undefined and an arbitrary perpendicular is used.