Top Description Inners Fields Constructors Methods
org.lwjgl.vulkan

public Class VkAccelerationStructureTrianglesDisplacementMicromapNV

extends Struct<VkAccelerationStructureTrianglesDisplacementMicromapNV>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

Structure specifying a displacement micromap in a bottom-level acceleration structure.
Description

If VkAccelerationStructureTrianglesDisplacementMicromapNV is included in the pNext chain of a VkAccelerationStructureGeometryTrianglesDataKHR structure, that geometry will reference that micromap.

For each triangle in the geometry, the acceleration structure build fetches an index from indexBuffer using indexType and indexStride. That triangle uses the displacement micromap information from micromap at that index plus baseTriangle.

Only one of pUsageCounts or ppUsageCounts can be a valid pointer, the other must be NULL. The elements of the non-NULL array describe the total count used to build this geometry. For a given format and subdivisionLevel the number of triangles in this geometry matching those values after indirection must be equal to the sum of matching count provided.

Valid Usage
Valid Usage (Implicit)
See Also

VkDeviceOrHostAddressConstKHR, VkMicromapUsageEXT

Layout


struct VkAccelerationStructureTrianglesDisplacementMicromapNV {
    VkStructureType sType;
    void * pNext;
    VkFormat displacementBiasAndScaleFormat;
    VkFormat displacementVectorFormat;
    VkDeviceOrHostAddressConstKHR displacementBiasAndScaleBuffer;
    VkDeviceSize displacementBiasAndScaleStride;
    VkDeviceOrHostAddressConstKHR displacementVectorBuffer;
    VkDeviceSize displacementVectorStride;
    VkDeviceOrHostAddressConstKHR displacedMicromapPrimitiveFlags;
    VkDeviceSize displacedMicromapPrimitiveFlagsStride;
    VkIndexType indexType;
    VkDeviceOrHostAddressConstKHR indexBuffer;
    VkDeviceSize indexStride;
    uint32_t baseTriangle;
    uint32_t usageCountsCount;
    VkMicromapUsageEXT const * pUsageCounts;
    VkMicromapUsageEXT const * const * ppUsageCounts;
    VkMicromapEXT micromap;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
BASETRIANGLE

The struct member offsets.

public static final int
DISPLACEDMICROMAPPRIMITIVEFLAGS

The struct member offsets.

public static final int
DISPLACEDMICROMAPPRIMITIVEFLAGSSTRIDE

The struct member offsets.

public static final int
DISPLACEMENTBIASANDSCALEBUFFER

The struct member offsets.

public static final int
DISPLACEMENTBIASANDSCALEFORMAT

The struct member offsets.

public static final int
DISPLACEMENTBIASANDSCALESTRIDE

The struct member offsets.

public static final int
DISPLACEMENTVECTORBUFFER

The struct member offsets.

public static final int
DISPLACEMENTVECTORFORMAT

The struct member offsets.

public static final int
DISPLACEMENTVECTORSTRIDE

The struct member offsets.

public static final int
INDEXBUFFER

The struct member offsets.

public static final int
INDEXSTRIDE

The struct member offsets.

public static final int
INDEXTYPE

The struct member offsets.

public static final int
MICROMAP

The struct member offsets.

public static final int
PNEXT

The struct member offsets.

public static final int
PPUSAGECOUNTS

The struct member offsets.

public static final int
PUSAGECOUNTS

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
STYPE

The struct member offsets.

public static final int
USAGECOUNTSCOUNT

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
public
VkAccelerationStructureTrianglesDisplacementMicromapNV(ByteBuffer container)

Creates a VkAccelerationStructureTrianglesDisplacementMicromapNV instance at the current position of the specified ByteBuffer container.

Method Summary

Modifier and TypeMethod and Description
public int
baseTriangle()

the base value added to the non-negative triangle indices.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
baseTriangle(int value)

Sets the specified value to the baseTriangle field.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
calloc()

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance allocated with memCalloc.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
calloc(int
the buffer capacity
capacity
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance allocated with memCalloc.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
calloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
calloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

protected VkAccelerationStructureTrianglesDisplacementMicromapNV
create(long
the struct memory address
address
,
ByteBuffer
an optional container buffer, to be referenced strongly by the struct instance.
container
)

Implements abstract org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.
public static VkAccelerationStructureTrianglesDisplacementMicromapNV
create()

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance allocated with BufferUtils.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
create(long address)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance for the specified memory address.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
create(int
the buffer capacity
capacity
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance allocated with BufferUtils.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
create(long
the memory address
address
,
int
the buffer capacity
capacity
)

Create a VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance at the specified memory.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
createSafe(long address)

Like create, but returns null if address is NULL.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

public VkDeviceOrHostAddressConstKHR
displacedMicromapPrimitiveFlags()

the address containing the primitive flags.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
public VkAccelerationStructureTrianglesDisplacementMicromapNV
public long
displacedMicromapPrimitiveFlagsStride()

the byte stride between primitive flag values.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
displacedMicromapPrimitiveFlagsStride(long value)

Sets the specified value to the displacedMicromapPrimitiveFlagsStride field.

public VkDeviceOrHostAddressConstKHR
displacementBiasAndScaleBuffer()

the address containing the bias and scale.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
public VkAccelerationStructureTrianglesDisplacementMicromapNV
public int
displacementBiasAndScaleFormat()

the format of displacement bias and scale used in this displacement micromap reference.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
displacementBiasAndScaleFormat(int value)

Sets the specified value to the displacementBiasAndScaleFormat field.

public long
displacementBiasAndScaleStride()

the byte stride between bias and scale values.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
displacementBiasAndScaleStride(long value)

Sets the specified value to the displacementBiasAndScaleStride field.

public VkDeviceOrHostAddressConstKHR
displacementVectorBuffer()

the address containing the displacement vector values.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
public VkAccelerationStructureTrianglesDisplacementMicromapNV
public int
displacementVectorFormat()

the format of displacement vector used in this displacement micromap reference.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
displacementVectorFormat(int value)

Sets the specified value to the displacementVectorFormat field.

public long
displacementVectorStride()

the byte stride between displacement vector values.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
displacementVectorStride(long value)

Sets the specified value to the displacementVectorStride field.

public VkDeviceOrHostAddressConstKHR
indexBuffer()

the address containing the triangle indices.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
public VkAccelerationStructureTrianglesDisplacementMicromapNV
indexBuffer(Consumer<VkDeviceOrHostAddressConstKHR> consumer)

Passes the indexBuffer field to the specified Consumer.

public long
indexStride()

the byte stride between triangle indices.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
indexStride(long value)

Sets the specified value to the indexStride field.

public int
indexType()

the type of triangle indices used when indexing this micromap.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
indexType(int value)

Sets the specified value to the indexType field.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
malloc()

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance allocated with memAlloc.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
malloc(int
the buffer capacity
capacity
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance allocated with memAlloc.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV
malloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV instance allocated on the specified MemoryStack.

public static VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer
malloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new VkAccelerationStructureTrianglesDisplacementMicromapNV.Buffer instance allocated on the specified MemoryStack.

public long
micromap()

the handle to the micromap object to include in this geometry.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
micromap(long value)

Sets the specified value to the micromap field.

public static int
nbaseTriangle(long struct)

Unsafe version of baseTriangle.

public static void
nbaseTriangle(long struct, int value)

Unsafe version of baseTriangle.

public static VkDeviceOrHostAddressConstKHR
public static void
public static long
public static void
public static VkDeviceOrHostAddressConstKHR
public static void
public static int
public static void
ndisplacementBiasAndScaleFormat(long struct, int value)

Unsafe version of displacementBiasAndScaleFormat.

public static long
public static void
ndisplacementBiasAndScaleStride(long struct, long value)

Unsafe version of displacementBiasAndScaleStride.

public static VkDeviceOrHostAddressConstKHR
ndisplacementVectorBuffer(long struct)

Unsafe version of displacementVectorBuffer.

public static void
public static int
ndisplacementVectorFormat(long struct)

Unsafe version of displacementVectorFormat.

public static void
ndisplacementVectorFormat(long struct, int value)

Unsafe version of displacementVectorFormat.

public static long
ndisplacementVectorStride(long struct)

Unsafe version of displacementVectorStride.

public static void
ndisplacementVectorStride(long struct, long value)

Unsafe version of displacementVectorStride.

public static VkDeviceOrHostAddressConstKHR
nindexBuffer(long struct)

Unsafe version of indexBuffer.

public static void
nindexBuffer(long struct, VkDeviceOrHostAddressConstKHR value)

Unsafe version of indexBuffer.

public static long
nindexStride(long struct)

Unsafe version of indexStride.

public static void
nindexStride(long struct, long value)

Unsafe version of indexStride.

public static int
nindexType(long struct)

Unsafe version of indexType.

public static void
nindexType(long struct, int value)

Unsafe version of indexType.

public static long
nmicromap(long struct)

Unsafe version of micromap.

public static void
nmicromap(long struct, long value)

Unsafe version of micromap.

public static long
npNext(long struct)

Unsafe version of pNext.

public static void
npNext(long struct, long value)

Unsafe version of pNext.

public static PointerBuffer
nppUsageCounts(long struct)

Unsafe version of ppUsageCounts.

public static void
nppUsageCounts(long struct, PointerBuffer value)

Unsafe version of ppUsageCounts.

public static VkMicromapUsageEXT.Buffer
npUsageCounts(long struct)

Unsafe version of pUsageCounts.

public static void
npUsageCounts(long struct, VkMicromapUsageEXT.Buffer value)

Unsafe version of pUsageCounts.

public static int
nsType(long struct)

Unsafe version of sType.

public static void
nsType(long struct, int value)

Unsafe version of sType.

public static int
nusageCountsCount(long struct)

Unsafe version of usageCountsCount.

public static void
nusageCountsCount(long struct, int value)

Sets the specified value to the usageCountsCount field of the specified struct.

public long
pNext()

NULL or a pointer to a structure extending this structure.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
pNext(long value)

Sets the specified value to the pNext field.

public PointerBuffer
ppUsageCounts()

a pointer to an array of pointers to VkMicromapUsageEXT structures.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
ppUsageCounts(PointerBuffer value)

Sets the address of the specified PointerBuffer to the ppUsageCounts field.

public VkMicromapUsageEXT.Buffer
pUsageCounts()

a pointer to an array of VkMicromapUsageEXT structures.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
pUsageCounts(VkMicromapUsageEXT.Buffer value)

Sets the address of the specified VkMicromapUsageEXT.Buffer to the pUsageCounts field.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
set(int sType, long pNext, int displacementBiasAndScaleFormat, int displacementVectorFormat, VkDeviceOrHostAddressConstKHR displacementBiasAndScaleBuffer, long displacementBiasAndScaleStride, VkDeviceOrHostAddressConstKHR displacementVectorBuffer, long displacementVectorStride, VkDeviceOrHostAddressConstKHR displacedMicromapPrimitiveFlags, long displacedMicromapPrimitiveFlagsStride, int indexType, VkDeviceOrHostAddressConstKHR indexBuffer, long indexStride, int baseTriangle, int usageCountsCount, VkMicromapUsageEXT.Buffer pUsageCounts, PointerBuffer ppUsageCounts, long micromap)

Initializes this struct with the specified values.

public VkAccelerationStructureTrianglesDisplacementMicromapNV

Returns:

this struct
set
(VkAccelerationStructureTrianglesDisplacementMicromapNV
the source struct
src
)

Copies the specified struct data to this struct.

public int
sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).
public int
sType()

a VkStructureType value identifying this structure.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
sType(int value)

Sets the specified value to the sType field.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
public int
usageCountsCount()

specifies the number of usage counts structures that will be used to determine the size of this micromap.

public VkAccelerationStructureTrianglesDisplacementMicromapNV
usageCountsCount(int value)

Sets the specified value to the usageCountsCount field.

Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate