QuadraticScreenSpaceTests ToQuadraticWithUnevenSize Method Delta Engine Documentation

Namespace: DeltaEngine.Tests.ScreenSpaces
Assembly: DeltaEngine.Tests (in DeltaEngine.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public void ToQuadraticWithUnevenSize()
Examples

[Test]
public void ToQuadraticWithUnevenSize()
{
    window.ViewportPixelSize = new Size(99, 199);
    var screen = new QuadraticScreenSpace(window);
    Assert.AreEqual(new Vector2D(0.2512563f, 0), screen.TopLeft);
    Assert.AreEqual(new Vector2D(0.7487437f, 1), screen.BottomRight);
    Assert.AreEqual(screen.BottomRight, screen.FromPixelSpace(new Vector2D(99, 199)));
}
See Also