C Specification

Alternatively, to unmap a memory object once host access to it is no longer needed by the application, call:

// Provided by VK_KHR_map_memory2
VkResult vkUnmapMemory2KHR(
    VkDevice                                    device,
    const VkMemoryUnmapInfoKHR*                 pMemoryUnmapInfo);

Parameters

  • device is the logical device that owns the memory.

  • pMemoryUnmapInfo is a pointer to a VkMemoryUnmapInfoKHR structure describing parameters of the unmap.

Description

This function behaves identically to vkUnmapMemory except that it gets its parameters via an extensible structure pointer rather than directly as function arguments.

Valid Usage (Implicit)
  • VUID-vkUnmapMemory2KHR-device-parameter
    device must be a valid VkDevice handle

  • VUID-vkUnmapMemory2KHR-pMemoryUnmapInfo-parameter
    pMemoryUnmapInfo must be a valid pointer to a valid VkMemoryUnmapInfoKHR structure

Return Codes
On success, this command returns
  • VK_SUCCESS

On failure, this command returns
  • VK_ERROR_MEMORY_MAP_FAILED

See Also

Document Notes

For more information, see the Vulkan Specification

This page is extracted from the Vulkan Specification. Fixes and changes should be made to the Specification, not directly.

Copyright 2014-2024 The Khronos Group Inc.

SPDX-License-Identifier: CC-BY-4.0