public void PointsToPoints_Many() { for (var i = 0; i < 1000; i++) { var rotatedUnitZ = NextVector3(); var rotatedUnitY = NextOrthogonalVector3(rotatedUnitZ); var m = NRotationHelper.ToEulerAngles(rotatedUnitZ, rotatedUnitY).ToMatrix4x4(); AssertVector3(rotatedUnitZ, Vector3.Transform(Vector3.UnitZ, m)); AssertVector3(rotatedUnitY, Vector3.Transform(Vector3.UnitY, m)); } }
static void ToEulerAngles_One(NEulerAngles expected, Vector3 rotatedUnitZ, Vector3 rotatedUnitY) { var actual = NRotationHelper.ToEulerAngles(rotatedUnitZ, rotatedUnitY); AssertNEulerAngles(expected, actual); }