
org.lwjgl.openxr.FBPassthroughKeyboardHands Maven / Gradle / Ivy
/*
* Copyright LWJGL. All rights reserved.
* License terms: https://www.lwjgl.org/license
* MACHINE GENERATED FILE, DO NOT EDIT
*/
package org.lwjgl.openxr;
import org.lwjgl.system.*;
import static org.lwjgl.system.Checks.*;
import static org.lwjgl.system.JNI.*;
/**
* The XR_FB_passthrough_keyboard_hands extension.
*
* This extension enables applications to show passthrough hands when hands are placed over the tracked keyboard. It enables users to see their hands over the keyboard in a mixed reality application. This extension is dependent on {@link FBPassthrough XR_FB_passthrough} extension which can be used to create a passthrough layer for hand presence use-case.
*
* The extension supports a single pair of hands (one left and one right hand), multiple pair of hands are not supported.
*
* This extension allows:
*
*
* - Creation of keyboard hands passthrough layer using {@link FBPassthrough#xrCreatePassthroughLayerFB CreatePassthroughLayerFB}
* - Setting the level of intensity for the hand mask in a passthrough layer with purpose {@code XrPassthroughLayerPurposeFB} as {@link #XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_HANDS_FB PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_HANDS_FB} or {@link #XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_MASKED_HANDS_FB PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_MASKED_HANDS_FB}
*
*/
public class FBPassthroughKeyboardHands {
/** The extension specification version. */
public static final int XR_FB_passthrough_keyboard_hands_SPEC_VERSION = 2;
/** The extension name. */
public static final String XR_FB_PASSTHROUGH_KEYBOARD_HANDS_EXTENSION_NAME = "XR_FB_passthrough_keyboard_hands";
/**
* Extends {@code XrPassthroughLayerPurposeFB}.
*
* Enum values:
*
*
* - {@link #XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_HANDS_FB PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_HANDS_FB}
* - {@link #XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_MASKED_HANDS_FB PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_MASKED_HANDS_FB}
*
*/
public static final int
XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_HANDS_FB = 1000203001,
XR_PASSTHROUGH_LAYER_PURPOSE_TRACKED_KEYBOARD_MASKED_HANDS_FB = 1000203002;
/** Extends {@code XrStructureType}. */
public static final int XR_TYPE_PASSTHROUGH_KEYBOARD_HANDS_INTENSITY_FB = 1000203002;
protected FBPassthroughKeyboardHands() {
throw new UnsupportedOperationException();
}
// --- [ xrPassthroughLayerSetKeyboardHandsIntensityFB ] ---
/** Unsafe version of: {@link #xrPassthroughLayerSetKeyboardHandsIntensityFB PassthroughLayerSetKeyboardHandsIntensityFB} */
public static int nxrPassthroughLayerSetKeyboardHandsIntensityFB(XrPassthroughLayerFB layer, long intensity) {
long __functionAddress = layer.getCapabilities().xrPassthroughLayerSetKeyboardHandsIntensityFB;
if (CHECKS) {
check(__functionAddress);
}
return callPPI(layer.address(), intensity, __functionAddress);
}
/**
* Renders hands over the keyboard (keyboard hands) with a specific intensity of hands passthrough layer.
*
* C Specification
*
* The {@link #xrPassthroughLayerSetKeyboardHandsIntensityFB PassthroughLayerSetKeyboardHandsIntensityFB} function is defined as:
*
*
* XrResult xrPassthroughLayerSetKeyboardHandsIntensityFB(
* XrPassthroughLayerFB layer,
* const XrPassthroughKeyboardHandsIntensityFB* intensity);
*
* Description
*
* Sets an {@link XrPassthroughKeyboardHandsIntensityFB} intensity on an {@code XrPassthroughLayerFB} layer.
*
* Valid Usage (Implicit)
*
*
* - The {@link FBPassthroughKeyboardHands XR_FB_passthrough_keyboard_hands} extension must be enabled prior to calling {@link #xrPassthroughLayerSetKeyboardHandsIntensityFB PassthroughLayerSetKeyboardHandsIntensityFB}
* - {@code layer} must be a valid {@code XrPassthroughLayerFB} handle
* - {@code intensity} must be a pointer to a valid {@link XrPassthroughKeyboardHandsIntensityFB} structure
*
*
* Return Codes
*
*
* - On success, this command returns
*
* - {@link XR10#XR_SUCCESS SUCCESS}
* - {@link XR10#XR_SESSION_LOSS_PENDING SESSION_LOSS_PENDING}
*
* - On failure, this command returns
*
* - {@link XR10#XR_ERROR_FUNCTION_UNSUPPORTED ERROR_FUNCTION_UNSUPPORTED}
* - {@link XR10#XR_ERROR_VALIDATION_FAILURE ERROR_VALIDATION_FAILURE}
* - {@link XR10#XR_ERROR_RUNTIME_FAILURE ERROR_RUNTIME_FAILURE}
* - {@link XR10#XR_ERROR_HANDLE_INVALID ERROR_HANDLE_INVALID}
* - {@link XR10#XR_ERROR_INSTANCE_LOST ERROR_INSTANCE_LOST}
* - {@link XR10#XR_ERROR_SESSION_LOST ERROR_SESSION_LOST}
* - {@link XR10#XR_ERROR_FEATURE_UNSUPPORTED ERROR_FEATURE_UNSUPPORTED}
*
*
*
* See Also
*
* {@link XrPassthroughKeyboardHandsIntensityFB}
*
* @param layer the {@code XrPassthroughLayerFB} to apply the intensity.
* @param intensity the {@link XrPassthroughKeyboardHandsIntensityFB} to be set.
*/
@NativeType("XrResult")
public static int xrPassthroughLayerSetKeyboardHandsIntensityFB(XrPassthroughLayerFB layer, @NativeType("XrPassthroughKeyboardHandsIntensityFB const *") XrPassthroughKeyboardHandsIntensityFB intensity) {
return nxrPassthroughLayerSetKeyboardHandsIntensityFB(layer, intensity.address());
}
}