Inheritance Hierarchy
DeltaEngine.Platforms TestWithMocksOrVisually
DeltaEngine.Rendering3D.Tests.Cameras CameraTests
Namespace: DeltaEngine.Rendering3D.Tests.Cameras
Assembly: DeltaEngine.Rendering3D.Tests (in DeltaEngine.Rendering3D.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax
The CameraTests type exposes the following members.
Constructors
Name | Description | |
---|---|---|
CameraTests | Initializes a new instance of the CameraTests class |
Methods
Name | Description | |
---|---|---|
AdvanceTimeAndUpdateEntities | (Inherited from TestWithMocksOrVisually.) | |
AfterSetupACameraTheAmbientContextShouldBeInitialized | ||
CameraShouldBeAbleToHandleViewportChanges | ||
CreateCamera | ||
InitializeResolver | (Inherited from TestWithMocksOrVisually.) | |
RegisterMock T | (Inherited from TestWithMocksOrVisually.) | |
Resolve T | (Inherited from TestWithMocksOrVisually.) | |
RunAfterFirstFrame | (Inherited from TestWithMocksOrVisually.) | |
RunTestAndDisposeResolverWhenDone | (Inherited from TestWithMocksOrVisually.) |
Properties
Name | Description | |
---|---|---|
IsMockResolver | (Inherited from TestWithMocksOrVisually.) |
Examples
[Test, CloseAfterFirstFrame] public void AfterSetupACameraTheAmbientContextShouldBeInitialized() { Assert.IsTrue(Camera.IsInitialized); }
[Test, ApproveFirstFrameScreenshot] public void CameraShouldBeAbleToHandleViewportChanges() { new Grid3D(new Size(5)); usedDevice = Resolve<Device>(); usedWindow = Resolve<Window>(); Matrix originalProjectionMatrix = usedDevice.CameraProjectionMatrix; usedWindow.ViewportPixelSize = new Size(400, 300); usedDevice.Set3DMode(); Assert.AreNotEqual(originalProjectionMatrix, usedDevice.CameraProjectionMatrix); }
See Also