VKFREEMEMORY(3)

NAME
vkFreeMemory - Free GPU memory

C SPECIFICATION

    void vkFreeMemory(
        VkDevice                                    device,
        VkDeviceMemory                              memory,
        const VkAllocationCallbacks*                pAllocator);

PARAMETERS

device
    The logical device which owns the memory object.

mem
    The memory object to free.

DESCRIPTION

vkFreeMemory frees the memory object whose handle is given in mem. After the memory is freed, mem becomes invalid and should no longer be used. Further, any resource to which the memory is bound become invalid and should not be referenced. Such objects should be destroyed or rebound to a new memory object (if allowed).

VALID USAGE

    • device must be a valid VkDevice handle

    • If memory is not VK_NULL_HANDLE, memory must be a valid VkDeviceMemory handle

    • If pAllocator is not NULL, pAllocator must be a pointer to a valid VkAllocationCallbacks structure

    • If memory is a valid handle, it must have been created, allocated or retrieved from device

    • Each of device and memory that are valid handles must have been created, allocated or retrieved from the same VkPhysicalDevice

    • All submitted commands that refer to memory (via images or buffers) must have completed execution

HOST SYNCHRONIZATION

    • Host access to memory must be externally synchronized

SEE ALSO

vkAllocateMemory

COPYRIGHT

Copyright © 2014-2016 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.

AUTHOR

Khronos Group
    Author.