Пример #1
0
        /// <summary>
        /// Resizes the current presenter, by resizing the back buffer and the depth stencil buffer.
        /// </summary>
        /// <param name="width"></param>
        /// <param name="height"></param>
        /// <param name="format"></param>
        public void Resize(int width, int height, PixelFormat format)
        {
            GraphicsDevice.Begin();

            Description.BackBufferWidth  = width;
            Description.BackBufferHeight = height;
            Description.BackBufferFormat = format;

            ResizeBackBuffer(width, height, format);
            ResizeDepthStencilBuffer(width, height, format);

            GraphicsDevice.End();
        }