Package org.lwjgl.vulkan
Class VkBufferImageCopy
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkBufferImageCopy
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class VkBufferImageCopy extends Struct
Khronos Reference Page
Vulkan SpecificationSpecifies a region to copy.
Valid Usage
imageSubresourcemust be a validVkImageSubresourceLayersstructurebufferOffsetmust be a multiple of the calling command'sVkImageparameter's texel sizebufferOffsetmust be a multiple of 4bufferRowLengthmust be 0, or greater than or equal to thewidthmember ofimageExtentbufferImageHeightmust be 0, or greater than or equal to theheightmember ofimageExtentimageOffset.xand (imageExtent.width+imageOffset.x) must both be greater than or equal to 0 and less than or equal to the image subresource widthimageOffset.yand (imageExtent.height +imageOffset.y) must both be greater than or equal to 0 and less than or equal to the image subresource heightimageOffset.zand (imageExtent.depth +imageOffset.z) must both be greater than or equal to 0 and less than or equal to the image subresource depth- If the calling command's
VkImageparameter is a compressed format image: bufferOffset,bufferRowLength,bufferImageHeightand all members ofimageOffsetandimageExtentmust respect the image transfer granularity requirements of the queue family that it will be submitted against, as described in Physical Device Enumeration- The
aspectMaskmember ofimageSubresourcemust specify aspects present in the calling command'sVkImageparameter - The
aspectMaskmember ofimageSubresourcemust only have a single bit set - If the calling command's
VkImageparameter is ofVkImageTypeIMAGE_TYPE_3D, thebaseArrayLayerandlayerCountmembers ofimageSubresourcemust be 0 and 1, respectively
Member documentation
bufferOffset– the offset in bytes from the start of the buffer object where the image data is copied from or tobufferRowLength– the buffer row lengthbufferImageHeight– the buffer image heightimageSubresource– aVkImageSubresourceLayersused to specify the specific image subresources of the image used for the source or destination image dataimageOffset– selects the initial x, y, z offsets in texels of the sub-region of the source or destination image dataimageExtent– the size in texels of the image to copy in width, height and depth
Layout
struct VkBufferImageCopy { VkDeviceSize bufferOffset; uint32_t bufferRowLength; uint32_t bufferImageHeight;VkImageSubresourceLayersimageSubresource;VkOffset3DimageOffset;VkExtent3DimageExtent; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classVkBufferImageCopy.BufferAn array ofVkBufferImageCopystructs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static intSIZEOFThe struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor and Description VkBufferImageCopy(java.nio.ByteBuffer container)Creates aVkBufferImageCopyinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description intbufferImageHeight()Returns the value of thebufferImageHeightfield.VkBufferImageCopybufferImageHeight(int value)Sets the specified value to thebufferImageHeightfield.longbufferOffset()Returns the value of thebufferOffsetfield.VkBufferImageCopybufferOffset(long value)Sets the specified value to thebufferOffsetfield.intbufferRowLength()Returns the value of thebufferRowLengthfield.VkBufferImageCopybufferRowLength(int value)Sets the specified value to thebufferRowLengthfield.static VkBufferImageCopycalloc()Returns a newVkBufferImageCopyinstance allocated withmemCalloc.static VkBufferImageCopy.Buffercalloc(int capacity)Returns a newVkBufferImageCopy.Bufferinstance allocated withmemCalloc.static VkBufferImageCopycallocStack()Returns a newVkBufferImageCopyinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkBufferImageCopy.BuffercallocStack(int capacity)Returns a newVkBufferImageCopy.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static VkBufferImageCopy.BuffercallocStack(int capacity, MemoryStack stack)Returns a newVkBufferImageCopy.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkBufferImageCopycallocStack(MemoryStack stack)Returns a newVkBufferImageCopyinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static VkBufferImageCopycreate()Returns a newVkBufferImageCopyinstance allocated withBufferUtils.static VkBufferImageCopy.Buffercreate(int capacity)Returns a newVkBufferImageCopy.Bufferinstance allocated withBufferUtils.static VkBufferImageCopycreate(long address)Returns a newVkBufferImageCopyinstance for the specified memory address ornullif the address isNULL.static VkBufferImageCopy.Buffercreate(long address, int capacity)Create aVkBufferImageCopy.Bufferinstance at the specified memory.VkExtent3DimageExtent()Returns aVkExtent3Dview of theimageExtentfield.VkBufferImageCopyimageExtent(VkExtent3D value)Copies the specifiedVkExtent3Dto theimageExtentfield.VkOffset3DimageOffset()Returns aVkOffset3Dview of theimageOffsetfield.VkBufferImageCopyimageOffset(VkOffset3D value)Copies the specifiedVkOffset3Dto theimageOffsetfield.VkImageSubresourceLayersimageSubresource()Returns aVkImageSubresourceLayersview of theimageSubresourcefield.VkBufferImageCopyimageSubresource(VkImageSubresourceLayers value)Copies the specifiedVkImageSubresourceLayersto theimageSubresourcefield.static VkBufferImageCopymalloc()Returns a newVkBufferImageCopyinstance allocated withmemAlloc.static VkBufferImageCopy.Buffermalloc(int capacity)Returns a newVkBufferImageCopy.Bufferinstance allocated withmemAlloc.static VkBufferImageCopymallocStack()Returns a newVkBufferImageCopyinstance allocated on the thread-localMemoryStack.static VkBufferImageCopy.BuffermallocStack(int capacity)Returns a newVkBufferImageCopy.Bufferinstance allocated on the thread-localMemoryStack.static VkBufferImageCopy.BuffermallocStack(int capacity, MemoryStack stack)Returns a newVkBufferImageCopy.Bufferinstance allocated on the specifiedMemoryStack.static VkBufferImageCopymallocStack(MemoryStack stack)Returns a newVkBufferImageCopyinstance allocated on the specifiedMemoryStack.VkBufferImageCopynset(long struct)Unsafe version ofset.VkBufferImageCopyset(long bufferOffset, int bufferRowLength, int bufferImageHeight, VkImageSubresourceLayers imageSubresource, VkOffset3D imageOffset, VkExtent3D imageExtent)Initializes this struct with the specified values.VkBufferImageCopyset(VkBufferImageCopy src)Copies the specified struct data to this struct.intsizeof()Returns thesizeof(struct).-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
VkBufferImageCopy
public VkBufferImageCopy(java.nio.ByteBuffer container)
Creates aVkBufferImageCopyinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Detail
-
sizeof
public int sizeof()
Description copied from class:StructReturns thesizeof(struct).
-
bufferOffset
public long bufferOffset()
Returns the value of thebufferOffsetfield.
-
bufferRowLength
public int bufferRowLength()
Returns the value of thebufferRowLengthfield.
-
bufferImageHeight
public int bufferImageHeight()
Returns the value of thebufferImageHeightfield.
-
imageSubresource
public VkImageSubresourceLayers imageSubresource()
Returns aVkImageSubresourceLayersview of theimageSubresourcefield.
-
imageOffset
public VkOffset3D imageOffset()
Returns aVkOffset3Dview of theimageOffsetfield.
-
imageExtent
public VkExtent3D imageExtent()
Returns aVkExtent3Dview of theimageExtentfield.
-
bufferOffset
public VkBufferImageCopy bufferOffset(long value)
Sets the specified value to thebufferOffsetfield.
-
bufferRowLength
public VkBufferImageCopy bufferRowLength(int value)
Sets the specified value to thebufferRowLengthfield.
-
bufferImageHeight
public VkBufferImageCopy bufferImageHeight(int value)
Sets the specified value to thebufferImageHeightfield.
-
imageSubresource
public VkBufferImageCopy imageSubresource(VkImageSubresourceLayers value)
Copies the specifiedVkImageSubresourceLayersto theimageSubresourcefield.
-
imageOffset
public VkBufferImageCopy imageOffset(VkOffset3D value)
Copies the specifiedVkOffset3Dto theimageOffsetfield.
-
imageExtent
public VkBufferImageCopy imageExtent(VkExtent3D value)
Copies the specifiedVkExtent3Dto theimageExtentfield.
-
set
public VkBufferImageCopy set(long bufferOffset, int bufferRowLength, int bufferImageHeight, VkImageSubresourceLayers imageSubresource, VkOffset3D imageOffset, VkExtent3D imageExtent)
Initializes this struct with the specified values.
-
nset
public VkBufferImageCopy nset(long struct)
Unsafe version ofset.
-
set
public VkBufferImageCopy set(VkBufferImageCopy src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static VkBufferImageCopy malloc()
Returns a newVkBufferImageCopyinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static VkBufferImageCopy calloc()
Returns a newVkBufferImageCopyinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static VkBufferImageCopy create()
Returns a newVkBufferImageCopyinstance allocated withBufferUtils.
-
create
public static VkBufferImageCopy create(long address)
Returns a newVkBufferImageCopyinstance for the specified memory address ornullif the address isNULL.
-
malloc
public static VkBufferImageCopy.Buffer malloc(int capacity)
Returns a newVkBufferImageCopy.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static VkBufferImageCopy.Buffer calloc(int capacity)
Returns a newVkBufferImageCopy.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static VkBufferImageCopy.Buffer create(int capacity)
Returns a newVkBufferImageCopy.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static VkBufferImageCopy.Buffer create(long address, int capacity)
Create aVkBufferImageCopy.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
mallocStack
public static VkBufferImageCopy mallocStack()
Returns a newVkBufferImageCopyinstance allocated on the thread-localMemoryStack.
-
callocStack
public static VkBufferImageCopy callocStack()
Returns a newVkBufferImageCopyinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static VkBufferImageCopy mallocStack(MemoryStack stack)
Returns a newVkBufferImageCopyinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static VkBufferImageCopy callocStack(MemoryStack stack)
Returns a newVkBufferImageCopyinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static VkBufferImageCopy.Buffer mallocStack(int capacity)
Returns a newVkBufferImageCopy.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static VkBufferImageCopy.Buffer callocStack(int capacity)
Returns a newVkBufferImageCopy.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static VkBufferImageCopy.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newVkBufferImageCopy.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static VkBufferImageCopy.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newVkBufferImageCopy.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
-