Top Description Inners Fields Constructors Methods
org.lwjgl.openxr

public Class XrInteractionProfileDpadBindingEXT

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

Interaction profile dpad binding.
Description

The XrInteractionProfileDpadBindingEXT structure is an input struct that defines how to use any two-axis input to provide dpad-like functionality to the application. The struct must be added for each input that should be treated as a dpad to the bindingModifications array of the XrBindingModificationsKHR structure (See XR_KHR_binding_modification extension).

Runtimes are free to ignore any of the fields when not obeying the bindings, but may use it for automatic rebindings of actions.

The implementation must return ERROR_VALIDATION_FAILURE from SuggestInteractionProfileBindings if any of the following are true:

If more than one XrInteractionProfileDpadBindingEXT is provided for the same input identifier, including top level path (e.g. pathname:/user/hand/left/input/thumbstick), and two or more of them specify the same actionset, the runtime must return ERROR_VALIDATION_FAILURE. If the same input identifier, including top level path, is used for more than one action set, in addition to inputs being suppressed by higher priority action sets, haptic events from dpads are also suppressed.

For example, a Valve Index controller binding with a "Walking" action set can have a dpad on each of:

Another action set can also have a dpad active on each of those inputs, and they can have different settings. If both action sets are active, the higher priority one trumps the lower priority one, and the lower priority one is suppressed.

Valid Usage (Implicit)
See Also

XrBindingModificationBaseHeaderKHR, XrHapticBaseHeader, SuggestInteractionProfileBindings

Layout


struct XrInteractionProfileDpadBindingEXT {
    XrStructureType type;
    void const * next;
    XrPath binding;
    XrActionSet actionSet;
    float forceThreshold;
    float forceThresholdReleased;
    float centerRegion;
    float wedgeAngle;
    XrBool32 isSticky;
    XrHapticBaseHeader const * onHaptic;
    XrHapticBaseHeader const * offHaptic;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final int
ACTIONSET

The struct member offsets.

public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
BINDING

The struct member offsets.

public static final int
CENTERREGION

The struct member offsets.

public static final int
FORCETHRESHOLD

The struct member offsets.

public static final int
FORCETHRESHOLDRELEASED

The struct member offsets.

public static final int
ISSTICKY

The struct member offsets.

public static final int
NEXT

The struct member offsets.

public static final int
OFFHAPTIC

The struct member offsets.

public static final int
ONHAPTIC

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
TYPE

The struct member offsets.

public static final int
WEDGEANGLE

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
public
XrInteractionProfileDpadBindingEXT(ByteBuffer container)

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

Method Summary

Modifier and TypeMethod and Description
public long
actionSet()

the action set for which this dpad will be active.

public XrInteractionProfileDpadBindingEXT
actionSet(XrActionSet value)

Sets the specified value to the actionSet field.

public long
binding()

the input path used for the specified actions in the suggested binding list to be used as a dpad.

public XrInteractionProfileDpadBindingEXT
binding(long value)

Sets the specified value to the binding field.

public static XrInteractionProfileDpadBindingEXT
calloc()

Returns a new XrInteractionProfileDpadBindingEXT instance allocated with memCalloc.

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

Returns a new XrInteractionProfileDpadBindingEXT.Buffer instance allocated with memCalloc.

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

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

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

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

public float
centerRegion()

defines the center region of the thumbstick or trackpad.

public XrInteractionProfileDpadBindingEXT
centerRegion(float value)

Sets the specified value to the centerRegion field.

protected XrInteractionProfileDpadBindingEXT
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 XrInteractionProfileDpadBindingEXT
create()

Returns a new XrInteractionProfileDpadBindingEXT instance allocated with BufferUtils.

public static XrInteractionProfileDpadBindingEXT
create(long address)

Returns a new XrInteractionProfileDpadBindingEXT instance for the specified memory address.

public static XrInteractionProfileDpadBindingEXT
create(XrBindingModificationBaseHeaderKHR value)

Downcasts the specified XrBindingModificationBaseHeaderKHR instance to XrInteractionProfileDpadBindingEXT.

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

Returns a new XrInteractionProfileDpadBindingEXT.Buffer instance allocated with BufferUtils.

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

Create a XrInteractionProfileDpadBindingEXT.Buffer instance at the specified memory.

public static XrInteractionProfileDpadBindingEXT.Buffer
create(XrBindingModificationBaseHeaderKHR.Buffer value)

Downcasts the specified XrBindingModificationBaseHeaderKHR.Buffer instance to XrInteractionProfileDpadBindingEXT.Buffer.

public static XrInteractionProfileDpadBindingEXT
createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

public float
forceThreshold()

a number in the half-open range (0, 1] representing the force value threshold at or above which (≥) a dpad input will transition from inactive to active.

public XrInteractionProfileDpadBindingEXT
forceThreshold(float value)

Sets the specified value to the forceThreshold field.

public float
forceThresholdReleased()

a number in the half-open range (0, 1] representing the force value threshold strictly below which (<) a dpad input will transition from active to inactive.

public XrInteractionProfileDpadBindingEXT
forceThresholdReleased(float value)

Sets the specified value to the forceThresholdReleased field.

public boolean
isSticky()

indicates that the implementation will latch the first region that is activated and continue to indicate that the binding for that region is true until the user releases the input underlying the virtual dpad.

public XrInteractionProfileDpadBindingEXT
isSticky(boolean value)

Sets the specified value to the isSticky field.

public static XrInteractionProfileDpadBindingEXT
malloc()

Returns a new XrInteractionProfileDpadBindingEXT instance allocated with memAlloc.

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

Returns a new XrInteractionProfileDpadBindingEXT.Buffer instance allocated with memAlloc.

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

Returns a new XrInteractionProfileDpadBindingEXT instance allocated on the specified MemoryStack.

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

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

public static long
nactionSet(long struct)

Unsafe version of actionSet.

public static void
nactionSet(long struct, XrActionSet value)

Unsafe version of actionSet.

public static long
nbinding(long struct)

Unsafe version of binding.

public static void
nbinding(long struct, long value)

Unsafe version of binding.

public static float
ncenterRegion(long struct)

Unsafe version of centerRegion.

public static void
ncenterRegion(long struct, float value)

Unsafe version of centerRegion.

public long
next()

NULL or a pointer to the next structure in a structure chain.

public XrInteractionProfileDpadBindingEXT
next(long value)

Sets the specified value to the next field.

public static float
nforceThreshold(long struct)

Unsafe version of forceThreshold.

public static void
nforceThreshold(long struct, float value)

Unsafe version of forceThreshold.

public static float
nforceThresholdReleased(long struct)

Unsafe version of forceThresholdReleased.

public static void
nforceThresholdReleased(long struct, float value)

Unsafe version of forceThresholdReleased.

public static int
nisSticky(long struct)

Unsafe version of isSticky.

public static void
nisSticky(long struct, int value)

Unsafe version of isSticky.

public static long
nnext(long struct)

Unsafe version of next.

public static void
nnext(long struct, long value)

Unsafe version of next.

public static XrHapticBaseHeader
noffHaptic(long struct)

Unsafe version of offHaptic.

public static void
noffHaptic(long struct, XrHapticBaseHeader value)

Unsafe version of offHaptic.

public static XrHapticBaseHeader
nonHaptic(long struct)

Unsafe version of onHaptic.

public static void
nonHaptic(long struct, XrHapticBaseHeader value)

Unsafe version of onHaptic.

public static int
ntype(long struct)

Unsafe version of type.

public static void
ntype(long struct, int value)

Unsafe version of type.

public static float
nwedgeAngle(long struct)

Unsafe version of wedgeAngle.

public static void
nwedgeAngle(long struct, float value)

Unsafe version of wedgeAngle.

public XrHapticBaseHeader
offHaptic()

the haptic output that the runtime must trigger when the binding changes from true to false.

public XrInteractionProfileDpadBindingEXT
offHaptic(XrHapticBaseHeader value)

Sets the address of the specified XrHapticBaseHeader to the offHaptic field.

public XrHapticBaseHeader
onHaptic()

the haptic output that the runtime must trigger when the binding changes from false to true.

public XrInteractionProfileDpadBindingEXT
onHaptic(XrHapticBaseHeader value)

Sets the address of the specified XrHapticBaseHeader to the onHaptic field.

public XrInteractionProfileDpadBindingEXT
set(int type, long next, long binding, XrActionSet actionSet, float forceThreshold, float forceThresholdReleased, float centerRegion, float wedgeAngle, boolean isSticky, XrHapticBaseHeader onHaptic, XrHapticBaseHeader offHaptic)

Initializes this struct with the specified values.

public XrInteractionProfileDpadBindingEXT

Returns:

this struct
set
(XrInteractionProfileDpadBindingEXT
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
type()

the XrStructureType of this structure.

public XrInteractionProfileDpadBindingEXT
type(int value)

Sets the specified value to the type field.

public XrInteractionProfileDpadBindingEXT
public static void
validate(long
the struct to validate
struct
)

Validates pointer members that should not be NULL.

public float
wedgeAngle()

indicates the angle in radians of each direction region and is a value in the half-open range [0, π).

public XrInteractionProfileDpadBindingEXT
wedgeAngle(float value)

Sets the specified value to the wedgeAngle field.

Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate