import { Matrix4Tuple } from 'three'; import { ServerEvent, VuerProps } from '../../../vuer/interfaces'; export declare const CONTROLLER_KEYS: string[]; export type HapticActuatorPulseEvent = ServerEvent & { data: { left?: { strength: number; duration: number; }; right?: { strength: number; duration: number; }; }; }; export type ControllerStateType = { trigger: boolean; squeeze: boolean; touchpad: 'pressed' | 'touched' | false; thumbstick: boolean; aButton: boolean; bButton: boolean; triggerValue: number; squeezeValue: number; touchpadValue: [number, number]; thumbstickValue: [number, number]; }; export type ControllerState = { left?: ControllerStateType; leftPose?: Matrix4Tuple; right?: ControllerStateType; rightPose?: Matrix4Tuple; }; export declare const controllerState: ControllerState; export type ControllerData = { left?: Matrix4Tuple; right?: Matrix4Tuple; leftState?: ControllerStateType; rightState?: ControllerStateType; }; export declare function getState(xrFrame: XRFrame, inputSource: XRInputSource | undefined, refSpace: XRReferenceSpace): ({ transform: Matrix4Tuple; } & ControllerStateType) | void; /** * Motion controllers component props for VR/XR controller tracking * * @dial xr */ export type ControllersProps = VuerProps<{ /** * Frames per second for controller updates * @dial performance * @dial-dtype int * @dial-default 30 * @dial-min 1 * @dial-max 120 * @dial-step 1 */ fps?: number; /** * Enable left controller tracking * @dial controls * @dial-dtype boolean * @dial-default true */ left?: boolean; /** * Enable right controller tracking * @dial controls * @dial-dtype boolean * @dial-default true */ right?: boolean; /** * Stream controller data continuously * @dial performance * @dial-dtype boolean * @dial-default false */ stream?: boolean; /** * Haptic feedback strength for left controller (0-1) * @dial haptics * @dial-dtype number * @dial-default 0.5 * @dial-min 0 * @dial-max 1 * @dial-step 0.01 */ pulseLeftStrength?: number; /** * Haptic feedback duration for left controller (milliseconds) * @dial haptics * @dial-dtype int * @dial-default 100 * @dial-min 0 * @dial-max 5000 * @dial-step 10 */ pulseLeftDuration?: number; /** * Trigger hash for left controller haptic pulse * @dial haptics * @dial-dtype string */ pulseLeftHash?: string; /** * Haptic feedback strength for right controller (0-1) * @dial haptics * @dial-dtype number * @dial-default 0.5 * @dial-min 0 * @dial-max 1 * @dial-step 0.01 */ pulseRightStrength?: number; /** * Haptic feedback duration for right controller (milliseconds) * @dial haptics * @dial-dtype int * @dial-default 100 * @dial-min 0 * @dial-max 5000 * @dial-step 10 */ pulseRightDuration?: number; /** * Trigger hash for right controller haptic pulse * @dial haptics * @dial-dtype string */ pulseRightHash?: string; }>; export declare function MotionControllers({ _key, children, fps, left: useLeft, right: useRight, pulseLeftStrength, pulseLeftDuration, pulseLeftHash, pulseRightStrength, pulseRightDuration, pulseRightHash, stream, ..._ }: ControllersProps): any;