Device.EndScene() Method (Microsoft.DirectX.Direct3D)
Ends a scene that was started by calling the Device.BeginScene method.
When EndScene succeeds, the scene is queued up for rendering by the driver. The method is not synchronous, so the scene is not guaranteed to have completed rendering when the method returns.
When scene rendering begins successfully, this method must be called before calling the Device.BeginScene method to start rendering another scene. If a prior call to Device.BeginScene fails, the scene did not begin and this method should not be called.
InvalidCallException The method failed because EndScene was called before BeginScene.