Пример #1
0
 public int CreateSwapChainForHwnd(IntPtr pDevice, HWND hWnd, ref DXGI_SWAP_CHAIN_DESC1 pDesc, ref DXGI_SWAP_CHAIN_FULLSCREEN_DESC pFullscreenDesc, IntPtr pRestrictToOutput, ref IntPtr ppSwapChain)
 {
     if (m_CreateSwapChainForHwndFunc == null)
     {
         var fp = GetFunctionPointer(15);
         m_CreateSwapChainForHwndFunc = (CreateSwapChainForHwndFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CreateSwapChainForHwndFunc));
     }
     return(m_CreateSwapChainForHwndFunc(m_ptr, pDevice, hWnd, ref pDesc, ref pFullscreenDesc, pRestrictToOutput, ref ppSwapChain));
 }
Пример #2
0
 public int CreateSwapChainForComposition(IntPtr pDevice, ref DXGI_SWAP_CHAIN_DESC1 pDesc, IntPtr pRestrictToOutput, ref IntPtr ppSwapChain)
 {
     if (m_CreateSwapChainForCompositionFunc == null)
     {
         var fp = GetFunctionPointer(24);
         m_CreateSwapChainForCompositionFunc = (CreateSwapChainForCompositionFunc)Marshal.GetDelegateForFunctionPointer(fp, typeof(CreateSwapChainForCompositionFunc));
     }
     return(m_CreateSwapChainForCompositionFunc(m_ptr, pDevice, ref pDesc, pRestrictToOutput, ref ppSwapChain));
 }