Class VkReallocationFunction
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Callback
-
- org.lwjgl.vulkan.VkReallocationFunction
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, CallbackI, CallbackI.P, NativeResource, Pointer, VkReallocationFunctionI
public abstract class VkReallocationFunction extends Callback implements VkReallocationFunctionI
Instances of this class may be set to thepfnReallocation
member of theVkAllocationCallbacks
struct.The function must alter the size of the allocation
pOriginal
, either by shrinking or growing it, to accommodate the new size.If
pOriginal
isNULL
, thenpfnReallocation
must behave similarly toVkAllocationFunction
. If size is zero, thenpfnReallocation
must behave similarly toVkFreeFunction
. The contents of the original allocation from bytes zero tomin(original size, new size) − 1
must be preserved in the new allocation. If the new allocation is larger than the old allocation, then the contents of the additional space are undefined. IfpOriginal
is non-NULL
, alignment must be equal to the originally requested alignment. If satisfying these requirements involves creating a new allocation, then the old allocation must be freed. If this function fails, it must returnNULL
and not free the old allocation.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.lwjgl.system.CallbackI
CallbackI.B, CallbackI.D, CallbackI.F, CallbackI.I, CallbackI.J, CallbackI.P, CallbackI.S, CallbackI.V, CallbackI.Z
-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static VkReallocationFunction
create(long functionPointer)
Creates aVkReallocationFunction
instance from the specified function pointer.static VkReallocationFunction
create(VkReallocationFunctionI instance)
Creates aVkReallocationFunction
instance that delegates to the specifiedVkReallocationFunctionI
instance.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.vulkan.VkReallocationFunctionI
address, callback, invoke
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Method Detail
-
create
public static VkReallocationFunction create(long functionPointer)
Creates aVkReallocationFunction
instance from the specified function pointer.
-
create
public static VkReallocationFunction create(VkReallocationFunctionI instance)
Creates aVkReallocationFunction
instance that delegates to the specifiedVkReallocationFunctionI
instance.
-
-