Class XrActionSetCreateInfo

java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<XrActionSetCreateInfo>
org.lwjgl.openxr.XrActionSetCreateInfo
All Implemented Interfaces:
AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

public class XrActionSetCreateInfo extends org.lwjgl.system.Struct<XrActionSetCreateInfo> implements org.lwjgl.system.NativeResource
XrActionSet creation info.
Description

When multiple actions are bound to the same input source, the priority of each action set determines which bindings are suppressed. Runtimes must ignore input sources from action sets with a lower priority number if those specific input sources are also present in active actions within a higher priority action set. If multiple action sets with the same priority are bound to the same input source and that is the highest priority number, runtimes must process all those bindings at the same time.

Two actions are considered to be bound to the same input source if they use the same identifier and optional location path segments, even if they have different component segments.

When runtimes are ignoring bindings because of priority, they must treat the binding to that input source as though they do not exist. That means the isActive field must be FALSE when retrieving action data, and that the runtime must not provide any visual, haptic, or other feedback related to the binding of that action to that input source. Other actions in the same action set which are bound to input sources that do not collide are not affected and are processed as normal.

If actionSetName or localizedActionSetName are empty strings, the runtime must return ERROR_NAME_INVALID or ERROR_LOCALIZED_NAME_INVALID respectively. If actionSetName or localizedActionSetName are duplicates of the corresponding field for any existing action set in the specified instance, the runtime must return ERROR_NAME_DUPLICATED or ERROR_LOCALIZED_NAME_DUPLICATED respectively. If the conflicting action set is destroyed, the conflicting field is no longer considered duplicated. If actionSetName contains characters which are not allowed in a single level of a well-formed path string, the runtime must return ERROR_PATH_FORMAT_INVALID.

Valid Usage (Implicit)
See Also

CreateActionSet

Layout


 struct XrActionSetCreateInfo {
     XrStructureType type();
     void const * next();
     char actionSetName()[XR_MAX_ACTION_SET_NAME_SIZE];
     char localizedActionSetName()[XR_MAX_LOCALIZED_ACTION_SET_NAME_SIZE];
     uint32_t priority();
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • TYPE

      public static final int TYPE
      The struct member offsets.
    • NEXT

      public static final int NEXT
      The struct member offsets.
    • ACTIONSETNAME

      public static final int ACTIONSETNAME
      The struct member offsets.
    • LOCALIZEDACTIONSETNAME

      public static final int LOCALIZEDACTIONSETNAME
      The struct member offsets.
    • PRIORITY

      public static final int PRIORITY
      The struct member offsets.
  • Constructor Details

    • XrActionSetCreateInfo

      public XrActionSetCreateInfo(ByteBuffer container)
      Creates a XrActionSetCreateInfo 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 Details

    • sizeof

      public int sizeof()
      Specified by:
      sizeof in class org.lwjgl.system.Struct<XrActionSetCreateInfo>
    • type

      public int type()
      the XrStructureType of this structure.
    • next

      public long next()
      NULL or a pointer to the next structure in a structure chain. No such structures are defined in core OpenXR.
    • actionSetName

      public ByteBuffer actionSetName()
      an array containing a NULL terminated non-empty string with the name of this action set.
    • actionSetNameString

      public String actionSetNameString()
      an array containing a NULL terminated non-empty string with the name of this action set.
    • localizedActionSetName

      public ByteBuffer localizedActionSetName()
      an array containing a NULL terminated UTF-8 string that can be presented to the user as a description of the action set. This string should be presented in the system’s current active locale.
    • localizedActionSetNameString

      public String localizedActionSetNameString()
      an array containing a NULL terminated UTF-8 string that can be presented to the user as a description of the action set. This string should be presented in the system’s current active locale.
    • priority

      public int priority()
      defines which action sets' actions are active on a given input source when actions on multiple active action sets are bound to the same input source. Larger priority numbers take precedence over smaller priority numbers.
    • type

      public XrActionSetCreateInfo type(int value)
      Sets the specified value to the type() field.
    • type$Default

      public XrActionSetCreateInfo type$Default()
      Sets the TYPE_ACTION_SET_CREATE_INFO value to the type() field.
    • next

      public XrActionSetCreateInfo next(long value)
      Sets the specified value to the next() field.
    • actionSetName

      public XrActionSetCreateInfo actionSetName(ByteBuffer value)
      Copies the specified encoded string to the actionSetName() field.
    • localizedActionSetName

      public XrActionSetCreateInfo localizedActionSetName(ByteBuffer value)
      Copies the specified encoded string to the localizedActionSetName() field.
    • priority

      public XrActionSetCreateInfo priority(int value)
      Sets the specified value to the priority() field.
    • set

      public XrActionSetCreateInfo set(int type, long next, ByteBuffer actionSetName, ByteBuffer localizedActionSetName, int priority)
      Initializes this struct with the specified values.
    • set

      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static XrActionSetCreateInfo malloc()
      Returns a new XrActionSetCreateInfo instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static XrActionSetCreateInfo calloc()
      Returns a new XrActionSetCreateInfo instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static XrActionSetCreateInfo create()
      Returns a new XrActionSetCreateInfo instance allocated with BufferUtils.
    • create

      public static XrActionSetCreateInfo create(long address)
      Returns a new XrActionSetCreateInfo instance for the specified memory address.
    • createSafe

      public static @Nullable XrActionSetCreateInfo createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static XrActionSetCreateInfo.Buffer malloc(int capacity)
      Returns a new XrActionSetCreateInfo.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static XrActionSetCreateInfo.Buffer calloc(int capacity)
      Returns a new XrActionSetCreateInfo.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static XrActionSetCreateInfo.Buffer create(int capacity)
      Returns a new XrActionSetCreateInfo.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static XrActionSetCreateInfo.Buffer create(long address, int capacity)
      Create a XrActionSetCreateInfo.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable XrActionSetCreateInfo.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • malloc

      public static XrActionSetCreateInfo malloc(org.lwjgl.system.MemoryStack stack)
      Returns a new XrActionSetCreateInfo instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static XrActionSetCreateInfo calloc(org.lwjgl.system.MemoryStack stack)
      Returns a new XrActionSetCreateInfo instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static XrActionSetCreateInfo.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new XrActionSetCreateInfo.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static XrActionSetCreateInfo.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new XrActionSetCreateInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • ntype

      public static int ntype(long struct)
      Unsafe version of type().
    • nnext

      public static long nnext(long struct)
      Unsafe version of next().
    • nactionSetName

      public static ByteBuffer nactionSetName(long struct)
      Unsafe version of actionSetName().
    • nactionSetNameString

      public static String nactionSetNameString(long struct)
      Unsafe version of actionSetNameString().
    • nlocalizedActionSetName

      public static ByteBuffer nlocalizedActionSetName(long struct)
      Unsafe version of localizedActionSetName().
    • nlocalizedActionSetNameString

      public static String nlocalizedActionSetNameString(long struct)
    • npriority

      public static int npriority(long struct)
      Unsafe version of priority().
    • ntype

      public static void ntype(long struct, int value)
      Unsafe version of type.
    • nnext

      public static void nnext(long struct, long value)
      Unsafe version of next.
    • nactionSetName

      public static void nactionSetName(long struct, ByteBuffer value)
      Unsafe version of actionSetName.
    • nlocalizedActionSetName

      public static void nlocalizedActionSetName(long struct, ByteBuffer value)
      Unsafe version of localizedActionSetName.
    • npriority

      public static void npriority(long struct, int value)
      Unsafe version of priority.