Axiom.RenderSystems.DirectX9.D3DRenderWindow.SwapBuffers C# (CSharp) Method

SwapBuffers() public method

public SwapBuffers ( bool waitForVSync ) : void
waitForVSync bool
return void
		public override void SwapBuffers( bool waitForVSync )
		{
			DX.Result result;
			var device = D3DDevice;

			// Skip if the device is already lost
			if ( isDeviceLost || testLostDevice() )
			{
				return;
			}

			if ( device != null )
			{
				result = this._isSwapChain ? this._swapChain.Present( D3D.Present.None ) : device.Present();
				/*
                if ( result.Code == D3D.ResultCode.DeviceLost.Code )
				{
					_renderSurface.ReleaseDC( _renderSurface.GetDC() );
					isDeviceLost = true;
					( (D3DRenderSystem)( Root.Instance.RenderSystem ) ).IsDeviceLost = true;
				}
				else if ( result.IsFailure )
				{
					throw new AxiomException( "[D3D] : Error presenting surfaces." );
				}*/
			}
		}