private void PrepareDXDevice() { pParams.BackBufferWidth = Math.Max(_CurrentDXWindowSize.Width, 1); pParams.BackBufferHeight = Math.Max(_CurrentDXWindowSize.Height, 1); pParams.BackBufferFormat = SurfaceFormat.Color; pParams.DepthStencilFormat = DepthFormat.Depth24Stencil8; pParams.DeviceWindowHandle = dxHandle; pParams.IsFullScreen = false; //pParams.PresentationInterval = PresentInterval.Immediate; DxDevice = CreateGraphicsDevice(pParams); fontEngine = new FontEngine(UserSettings.FontName, UserSettings.FontStyle, UserSettings.FontSize, DxDevice); sprite = new SpriteBatch(DxDevice); }