Namespace: DeltaEngine.Tests.Datatypes
Assembly: DeltaEngine.Tests (in DeltaEngine.Tests.dll) Version: 1.1.1.0 (1.1.1)
Assembly: DeltaEngine.Tests (in DeltaEngine.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax
Examples
[Test] public void Rotate() { Assert.IsTrue(Vector2D.UnitX.Rotate(90.0f).IsNearlyEqual(Vector2D.UnitY)); Assert.IsTrue(Vector2D.UnitX.Rotate(-90.0f).IsNearlyEqual(-Vector2D.UnitY)); Assert.IsTrue(Vector2D.UnitY.Rotate(-90.0f).IsNearlyEqual(Vector2D.UnitX)); }
[Test] public void RotateAround() { Assert.IsTrue(Vector2D.UnitX.RotateAround(Vector2D.Zero, 90.0f).IsNearlyEqual(Vector2D.UnitY)); Assert.IsTrue( Vector2D.UnitY.RotateAround(new Vector2D(0.0f, 0.5f), 180.0f).IsNearlyEqual(Vector2D.Zero)); }
See Also