// Copyright (c) 2018-2020 NVIDIA Corporation
//
// SPDX-License-Identifier: CC-BY-4.0

[open,refpage='VkExportMemoryWin32HandleInfoNV',desc='specify security attributes and access rights for Win32 memory handles',type='structs']
--
When slink:VkExportMemoryAllocateInfoNV::pname:handleTypes includes
ename:VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_BIT_NV, add a
sname:VkExportMemoryWin32HandleInfoNV structure to the pname:pNext chain of
the slink:VkExportMemoryAllocateInfoNV structure to specify security
attributes and access rights for the memory object's external handle.

The sname:VkExportMemoryWin32HandleInfoNV structure is defined as:

include::{generated}/api/structs/VkExportMemoryWin32HandleInfoNV.txt[]

  * pname:sType is the type of this structure.
  * pname:pNext is `NULL` or a pointer to a structure extending this
    structure.
  * pname:pAttributes is a pointer to a Windows code:SECURITY_ATTRIBUTES
    structure specifying security attributes of the handle.
  * pname:dwAccess is a code:DWORD specifying access rights of the handle.

If this structure is not present, or if pname:pAttributes is set to `NULL`,
default security descriptor values will be used, and child processes created
by the application will not inherit the handle, as described in the MSDN
documentation for "`Synchronization Object Security and Access Rights`"^1^.
Further, if the structure is not present, the access rights will be

code:DXGI_SHARED_RESOURCE_READ | code:DXGI_SHARED_RESOURCE_WRITE

1::
    https://docs.microsoft.com/en-us/windows/win32/sync/synchronization-object-security-and-access-rights

include::{generated}/validity/structs/VkExportMemoryWin32HandleInfoNV.txt[]
--
