Esempio n. 1
0
        public void RegenerateOrthonormalBasisTest()
        {
            var f = Vector3.UnitZ * 2;
            var u = Vector3.UnitY;

            Vector3 s;

            LocalSpaceBasisHelpers.RegenerateOrthonormalBasis(f, u, out f, out s, out u);

            Assert.AreEqual(Vector3.UnitZ, f);
            Assert.AreEqual(u, Vector3.UnitY);
            Assert.AreEqual(Vector3.Cross(f, u), s);
        }
Esempio n. 2
0
 // for supplying both a new forward and and new up
 public void RegenerateOrthonormalBasis(Vector3 newForward, Vector3 newUp)
 {
     LocalSpaceBasisHelpers.RegenerateOrthonormalBasis(newForward, newUp, out ForwardField, out SideField, out UpField);
 }