Ejemplo n.º 1
0
        public IDXGISwapChain1 CreateSwapChainForHwnd(
            IUnknown device,
            IntPtr hwnd,
            SwapChainDescription1 description,
            SwapChainFullscreenDescription fullscreenDescription,
            IDXGIOutput restrictToOutput)
        {
            Guard.NotNull(device, nameof(device));
            Guard.IsTrue(hwnd != IntPtr.Zero, nameof(hwnd), "Invalid hwnd handle");
            Guard.NotNull(restrictToOutput, nameof(restrictToOutput));

            return(CreateSwapChainForHwnd(device, hwnd, ref description, fullscreenDescription, restrictToOutput));
        }
Ejemplo n.º 2
0
        public IDXGIDecodeSwapChain CreateDecodeSwapChainForCompositionSurfaceHandle(
            IUnknown device,
            IntPtr surface,
            IDXGIResource yuvDecodeBuffers,
            IDXGIOutput restrictToOutput)
        {
            Guard.NotNull(device, nameof(device));
            Guard.IsTrue(surface != IntPtr.Zero, nameof(surface), "Invalid surface handle");
            Guard.NotNull(device, nameof(device));
            Guard.NotNull(yuvDecodeBuffers, nameof(yuvDecodeBuffers));
            Guard.NotNull(restrictToOutput, nameof(restrictToOutput));

            // Reserved for future use (https://docs.microsoft.com/it-it/windows/desktop/api/dxgi1_3/ns-dxgi1_3-dxgi_decode_swap_chain_desc)
            var description = new DecodeSwapChainDescription
            {
                Flags = 0
            };

            return(CreateDecodeSwapChainForCompositionSurfaceHandle(device, surface, description, yuvDecodeBuffers, restrictToOutput));
        }
Ejemplo n.º 3
0
 public Result SetFullscreenState(bool fullscreen, IDXGIOutput target = null)
 {
     return(SetFullscreenState(new RawBool(fullscreen), target));
 }
Ejemplo n.º 4
0
        public IDXGISwapChain1 CreateSwapChainForCoreWindow(IUnknown device, IUnknown window, SwapChainDescription1 description, IDXGIOutput restrictToOutput)
        {
            Guard.NotNull(device, nameof(device));
            Guard.NotNull(window, nameof(window));
            Guard.NotNull(restrictToOutput, nameof(restrictToOutput));

            return(CreateSwapChainForCoreWindow(device, window, ref description, restrictToOutput));
        }
Ejemplo n.º 5
0
 public IDXGISwapChain1 CreateSwapChainForComposition(IUnknown device, SwapChainDescription1 description, IDXGIOutput restrictToOutput)
 {
     Guard.NotNull(device, nameof(device));
     Guard.NotNull(restrictToOutput, nameof(restrictToOutput));
     return(CreateSwapChainForComposition(device, ref description, restrictToOutput));
 }
Ejemplo n.º 6
0
        public IDXGISwapChain1 CreateSwapChainForCompositionSurfaceHandle(IUnknown device, IntPtr surface, SwapChainDescription1 description, IDXGIOutput restrictToOutput)
        {
            Guard.NotNull(device, nameof(device));
            Guard.IsTrue(surface != IntPtr.Zero, nameof(surface), "Invalid surface handle");
            Guard.NotNull(restrictToOutput, nameof(restrictToOutput));

            return(CreateSwapChainForCompositionSurfaceHandle(device, surface, ref description, restrictToOutput));
        }