Top Description Inners Fields Constructors Methods
org.lwjgl.vulkan

public Class VkDrmFormatModifierPropertiesEXT

extends Struct<VkDrmFormatModifierPropertiesEXT>
Class Inheritance
Imports
javax.annotation.*, java.nio.*, org.lwjgl.system.*

Structure specifying properties of a format when combined with a DRM format modifier.
Description

The returned drmFormatModifierTilingFeatures must contain at least one bit.

The implementation must not return DRM_FORMAT_MOD_INVALID in drmFormatModifier.

An image’s memory planecount (as returned by drmFormatModifierPlaneCount) is distinct from its format planecount (in the sense of multi-planar Y′CBCR formats). In VkImageAspectFlags, each VK_IMAGE_ASPECT_MEMORY_PLANE_i_BIT_EXT represents a memory plane and each VK_IMAGE_ASPECT_PLANE_i_BIT a format plane.

An image’s set of format planes is an ordered partition of the image’s content into separable groups of format components. The ordered partition is encoded in the name of each VkFormat. For example, FORMAT_G8_B8R8_2PLANE_420_UNORM contains two format planes; the first plane contains the green component and the second plane contains the blue component and red component. If the format name does not contain PLANE, then the format contains a single plane; for example, FORMAT_R8G8B8A8_UNORM. Some commands, such as CmdCopyBufferToImage, do not operate on all format components in the image, but instead operate only on the format planes explicitly chosen by the application and operate on each format plane independently.

An image’s set of memory planes is an ordered partition of the image’s memory rather than the image’s content. Each memory plane is a contiguous range of memory. The union of an image’s memory planes is not necessarily contiguous.

If an image is linear, then the partition is the same for memory planes and for format planes. Therefore, if the returned drmFormatModifier is DRM_FORMAT_MOD_LINEAR, then drmFormatModifierPlaneCount must equal the format planecount, and drmFormatModifierTilingFeatures must be identical to the VkFormatProperties2::linearTilingFeatures returned in the same pNext chain.

If an image is non-linear, then the partition of the image’s memory into memory planes is implementation-specific and may be unrelated to the partition of the image’s content into format planes. For example, consider an image whose format is FORMAT_G8_B8_R8_3PLANE_420_UNORM, tiling is IMAGE_TILING_DRM_FORMAT_MODIFIER_EXT, whose drmFormatModifier is not DRM_FORMAT_MOD_LINEAR, and flags lacks IMAGE_CREATE_DISJOINT_BIT. The image has 3 format planes, and commands such CmdCopyBufferToImage act on each format plane independently as if the data of each format plane were separable from the data of the other planes. In a straightforward implementation, the implementation may store the image’s content in 3 adjacent memory planes where each memory plane corresponds exactly to a format plane. However, the implementation may also store the image’s content in a single memory plane where all format components are combined using an implementation-private block-compressed format; or the implementation may store the image’s content in a collection of 7 adjacent memory planes using an implementation-private sharding technique. Because the image is non-linear and non-disjoint, the implementation has much freedom when choosing the image’s placement in memory.

The memory planecount applies to function parameters and structures only when the API specifies an explicit requirement on drmFormatModifierPlaneCount. In all other cases, the memory planecount is ignored.

See Also

VkDrmFormatModifierPropertiesListEXT

Layout


struct VkDrmFormatModifierPropertiesEXT {
    uint64_t drmFormatModifier;
    uint32_t drmFormatModifierPlaneCount;
    VkFormatFeatureFlags drmFormatModifierTilingFeatures;
}

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
DRMFORMATMODIFIER

The struct member offsets.

public static final int
DRMFORMATMODIFIERPLANECOUNT

The struct member offsets.

public static final int
DRMFORMATMODIFIERTILINGFEATURES

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
public
VkDrmFormatModifierPropertiesEXT(ByteBuffer container)

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

Method Summary

Modifier and TypeMethod and Description
protected VkDrmFormatModifierPropertiesEXT
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 VkDrmFormatModifierPropertiesEXT
create(long address)

Returns a new VkDrmFormatModifierPropertiesEXT instance for the specified memory address.

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

Create a VkDrmFormatModifierPropertiesEXT.Buffer instance at the specified memory.

public static VkDrmFormatModifierPropertiesEXT
createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

public long
drmFormatModifier()

a Linux DRM format modifier.

public int
drmFormatModifierPlaneCount()

the number of memory planes in any image created with format and drmFormatModifier.

public int
drmFormatModifierTilingFeatures()

a bitmask of VkFormatFeatureFlagBits that are supported by any image created with format and drmFormatModifier.

public static long
ndrmFormatModifier(long struct)

Unsafe version of drmFormatModifier.

public static int
public static int
public int
sizeof()

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

Returns sizeof(struct).
Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate

Field Detail

ALIGNOFback to summary
public static final int ALIGNOF

The struct alignment in bytes.

DRMFORMATMODIFIERback to summary
public static final int DRMFORMATMODIFIER

The struct member offsets.

DRMFORMATMODIFIERPLANECOUNTback to summary
public static final int DRMFORMATMODIFIERPLANECOUNT

The struct member offsets.

DRMFORMATMODIFIERTILINGFEATURESback to summary
public static final int DRMFORMATMODIFIERTILINGFEATURES

The struct member offsets.

SIZEOFback to summary
public static final int SIZEOF

The struct size in bytes.

Constructor Detail

VkDrmFormatModifierPropertiesEXTback to summary
protected VkDrmFormatModifierPropertiesEXT(long address, ByteBuffer container)
VkDrmFormatModifierPropertiesEXTback to summary
public VkDrmFormatModifierPropertiesEXT(ByteBuffer container)

Creates a VkDrmFormatModifierPropertiesEXT instance at the current position of the specified ByteBuffer container. 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

createback to summary
protected VkDrmFormatModifierPropertiesEXT create(long address, ByteBuffer container)

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

Doc from org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.

Effectively, every Struct instance is a factory for more instances of the same type. This is used by StructBuffer.

Parameters
address:long

the struct memory address

container:ByteBuffer

an optional container buffer, to be referenced strongly by the struct instance.

Annotations
@Override
createback to summary
public static VkDrmFormatModifierPropertiesEXT create(long address)

Returns a new VkDrmFormatModifierPropertiesEXT instance for the specified memory address.

createback to summary
public static VkDrmFormatModifierPropertiesEXT.Buffer create(long address, int capacity)

Create a VkDrmFormatModifierPropertiesEXT.Buffer instance at the specified memory.

Parameters
address:long

the memory address

capacity:int

the buffer capacity

createSafeback to summary
public static VkDrmFormatModifierPropertiesEXT createSafe(long address)

Like create, but returns null if address is NULL.

Annotations
@Nullable
createSafeback to summary
public static VkDrmFormatModifierPropertiesEXT.Buffer createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

Annotations
@Nullable
drmFormatModifierback to summary
public long drmFormatModifier()

a Linux DRM format modifier.

Annotations
@NativeType:uint64_t
drmFormatModifierPlaneCountback to summary
public int drmFormatModifierPlaneCount()

the number of memory planes in any image created with format and drmFormatModifier. An image’s memory planecount is distinct from its format planecount, as explained below.

Annotations
@NativeType:uint32_t
drmFormatModifierTilingFeaturesback to summary
public int drmFormatModifierTilingFeatures()

a bitmask of VkFormatFeatureFlagBits that are supported by any image created with format and drmFormatModifier.

Annotations
@NativeType:VkFormatFeatureFlags
ndrmFormatModifierback to summary
public static long ndrmFormatModifier(long struct)

Unsafe version of drmFormatModifier.

ndrmFormatModifierPlaneCountback to summary
public static int ndrmFormatModifierPlaneCount(long struct)

Unsafe version of drmFormatModifierPlaneCount.

ndrmFormatModifierTilingFeaturesback to summary
public static int ndrmFormatModifierTilingFeatures(long struct)

Unsafe version of drmFormatModifierTilingFeatures.

sizeofback to summary
public int sizeof()

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

Doc from org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).

Annotations
@Override
org.lwjgl.vulkan back to summary

public Class VkDrmFormatModifierPropertiesEXT.Buffer

extends StructBuffer<VkDrmFormatModifierPropertiesEXT, VkDrmFormatModifierPropertiesEXT.Buffer>
Class Inheritance

An array of VkDrmFormatModifierPropertiesEXT structs.

Field Summary

Modifier and TypeField and Description
private static final VkDrmFormatModifierPropertiesEXT

Constructor Summary

AccessConstructor and Description
public
Buffer(ByteBuffer container)

Creates a new VkDrmFormatModifierPropertiesEXT.Buffer instance backed by the specified container.

public
Buffer(long address, int cap)

pack-priv
Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Summary

Modifier and TypeMethod and Description
public long
public int
public int
protected VkDrmFormatModifierPropertiesEXT
protected VkDrmFormatModifierPropertiesEXT.Buffer
Inherited from org.lwjgl.system.StructBuffer:
applyapplyforEachgetgetgetgetiteratorparallelStreamputputsizeofspliteratorstream

Field Detail

ELEMENT_FACTORYback to summary
private static final VkDrmFormatModifierPropertiesEXT ELEMENT_FACTORY

Constructor Detail

Bufferback to summary
public Buffer(ByteBuffer container)

Creates a new VkDrmFormatModifierPropertiesEXT.Buffer instance backed by the specified container.

Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by VkDrmFormatModifierPropertiesEXT#SIZEOF, and its mark will be undefined.

The created buffer instance holds a strong reference to the container object.

Bufferback to summary
public Buffer(long address, int cap)
Bufferback to summary
pack-priv Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Detail

drmFormatModifierback to summary
public long drmFormatModifier()
Returns:long

the value of the VkDrmFormatModifierPropertiesEXT#drmFormatModifier field.

Annotations
@NativeType:uint64_t
drmFormatModifierPlaneCountback to summary
public int drmFormatModifierPlaneCount()
Returns:int

the value of the VkDrmFormatModifierPropertiesEXT#drmFormatModifierPlaneCount field.

Annotations
@NativeType:uint32_t
drmFormatModifierTilingFeaturesback to summary
public int drmFormatModifierTilingFeatures()
Returns:int

the value of the VkDrmFormatModifierPropertiesEXT#drmFormatModifierTilingFeatures field.

Annotations
@NativeType:VkFormatFeatureFlags
getElementFactoryback to summary
protected VkDrmFormatModifierPropertiesEXT getElementFactory()

Implements abstract org.lwjgl.system.StructBuffer.getElementFactory.

Annotations
@Override
selfback to summary
protected VkDrmFormatModifierPropertiesEXT.Buffer self()

Implements abstract org.lwjgl.system.CustomBuffer.self.

Annotations
@Override