EffectEditor.Controls.GraphicsDeviceService.GraphicsDeviceService C# (CSharp) Метод

GraphicsDeviceService() статический приватный Метод

Constructor is private, because this is a singleton class: client controls should use the public AddRef method instead.
static private GraphicsDeviceService ( IntPtr windowHandle, int width, int height ) : System
windowHandle System.IntPtr
width int
height int
Результат System
        GraphicsDeviceService(IntPtr windowHandle, int width, int height)
        {
            parameters = new PresentationParameters();

            parameters.BackBufferWidth = Math.Max(width, 1);
            parameters.BackBufferHeight = Math.Max(height, 1);
            parameters.BackBufferFormat = SurfaceFormat.Color;

            parameters.EnableAutoDepthStencil = true;
            parameters.AutoDepthStencilFormat = DepthFormat.Depth24;

            graphicsDevice = new GraphicsDevice(GraphicsAdapter.DefaultAdapter,
                                                DeviceType.Hardware,
                                                windowHandle,
                                                parameters);
        }