|
Monado OpenXR Runtime
|
Supports input actions and can be attached to the HMD pose. More...
#include <qwerty/qwerty_device.h>


Public Member Functions | |
| struct qwerty_controller * | qwerty_controller_create (bool is_left, struct qwerty_hmd *qhmd) |
| Create qwerty_controller. More... | |
| struct qwerty_controller * | qwerty_controller (struct xrt_device *xd) |
| Cast to qwerty_controller. More... | |
| void | qwerty_press_trigger (struct qwerty_controller *qc) |
| Simulate pressing input/trigger/value to 1.0. More... | |
| void | qwerty_release_trigger (struct qwerty_controller *qc) |
| Simulate releasing input/trigger/value to 0.0. More... | |
| void | qwerty_press_menu (struct qwerty_controller *qc) |
| Simulate pressing input/menu/click. More... | |
| void | qwerty_release_menu (struct qwerty_controller *qc) |
| Simulate releasing input/menu/click. More... | |
| void | qwerty_press_squeeze (struct qwerty_controller *qc) |
| Simulate pressing input/squeeze/click. More... | |
| void | qwerty_release_squeeze (struct qwerty_controller *qc) |
| Simulate releasing input/squeeze/click. More... | |
| void | qwerty_press_system (struct qwerty_controller *qc) |
| Simulate pressing input/system/click. More... | |
| void | qwerty_release_system (struct qwerty_controller *qc) |
| Simulate releasing input/system/click. More... | |
| void | qwerty_press_thumbstick_left (struct qwerty_controller *qc) |
| void | qwerty_release_thumbstick_left (struct qwerty_controller *qc) |
| void | qwerty_press_thumbstick_right (struct qwerty_controller *qc) |
| void | qwerty_release_thumbstick_right (struct qwerty_controller *qc) |
| void | qwerty_press_thumbstick_up (struct qwerty_controller *qc) |
| void | qwerty_release_thumbstick_up (struct qwerty_controller *qc) |
| void | qwerty_press_thumbstick_down (struct qwerty_controller *qc) |
| void | qwerty_release_thumbstick_down (struct qwerty_controller *qc) |
| void | qwerty_press_thumbstick_click (struct qwerty_controller *qc) |
| void | qwerty_release_thumbstick_click (struct qwerty_controller *qc) |
| void | qwerty_press_trackpad_left (struct qwerty_controller *qc) |
| void | qwerty_release_trackpad_left (struct qwerty_controller *qc) |
| void | qwerty_press_trackpad_right (struct qwerty_controller *qc) |
| void | qwerty_release_trackpad_right (struct qwerty_controller *qc) |
| void | qwerty_press_trackpad_up (struct qwerty_controller *qc) |
| void | qwerty_release_trackpad_up (struct qwerty_controller *qc) |
| void | qwerty_press_trackpad_down (struct qwerty_controller *qc) |
| void | qwerty_release_trackpad_down (struct qwerty_controller *qc) |
| void | qwerty_press_trackpad_click (struct qwerty_controller *qc) |
| void | qwerty_release_trackpad_click (struct qwerty_controller *qc) |
| void | qwerty_follow_hmd (struct qwerty_controller *qc, bool follow) |
Attach/detach the pose of qc to its HMD. More... | |
| void | qwerty_reset_controller_pose (struct qwerty_controller *qc) |
| Reset controller to initial pose and makes it follow the HMD. More... | |
Public Member Functions inherited from qwerty_device | |
| struct qwerty_device * | qwerty_device (struct xrt_device *xd) |
| Cast to qwerty_device. More... | |
| void | qwerty_press_left (struct qwerty_device *qd) |
| void | qwerty_release_left (struct qwerty_device *qd) |
| void | qwerty_press_right (struct qwerty_device *qd) |
| void | qwerty_release_right (struct qwerty_device *qd) |
| void | qwerty_press_forward (struct qwerty_device *qd) |
| void | qwerty_release_forward (struct qwerty_device *qd) |
| void | qwerty_press_backward (struct qwerty_device *qd) |
| void | qwerty_release_backward (struct qwerty_device *qd) |
| void | qwerty_press_up (struct qwerty_device *qd) |
| void | qwerty_release_up (struct qwerty_device *qd) |
| void | qwerty_press_down (struct qwerty_device *qd) |
| void | qwerty_release_down (struct qwerty_device *qd) |
| void | qwerty_press_look_left (struct qwerty_device *qd) |
| void | qwerty_release_look_left (struct qwerty_device *qd) |
| void | qwerty_press_look_right (struct qwerty_device *qd) |
| void | qwerty_release_look_right (struct qwerty_device *qd) |
| void | qwerty_press_look_up (struct qwerty_device *qd) |
| void | qwerty_release_look_up (struct qwerty_device *qd) |
| void | qwerty_press_look_down (struct qwerty_device *qd) |
| void | qwerty_release_look_down (struct qwerty_device *qd) |
| void | qwerty_press_sprint (struct qwerty_device *qd) |
Momentarily increase movement_speed until qwerty_release_sprint() More... | |
| void | qwerty_release_sprint (struct qwerty_device *qd) |
| Stop doing what qwerty_press_sprint started. More... | |
| void | qwerty_add_look_delta (struct qwerty_device *qd, float yaw, float pitch) |
| Add yaw and pitch movement for the next frame. More... | |
| void | qwerty_change_movement_speed (struct qwerty_device *qd, float steps) |
| Change movement speed in exponential steps (usually integers, but any float allowed) More... | |
| void | qwerty_release_all (struct qwerty_device *qd) |
| Release all movement input. More... | |
Data Fields | |
| struct qwerty_device | base |
| bool | trigger_clicked |
| int64_t | trigger_timestamp |
| bool | menu_clicked |
| int64_t | menu_timestamp |
| bool | squeeze_clicked |
| int64_t | squeeze_timestamp |
| bool | system_clicked |
| int64_t | system_timestamp |
| bool | thumbstick_left_pressed |
| bool | thumbstick_right_pressed |
| bool | thumbstick_up_pressed |
| bool | thumbstick_down_pressed |
| int64_t | thumbstick_timestamp |
| bool | thumbstick_clicked |
| int64_t | thumbstick_click_timestamp |
| bool | trackpad_left_pressed |
| bool | trackpad_right_pressed |
| bool | trackpad_up_pressed |
| bool | trackpad_down_pressed |
| int64_t | trackpad_timestamp |
| bool | trackpad_clicked |
| int64_t | trackpad_click_timestamp |
| bool | follow_hmd |
| Only used when a qwerty_hmd exists in the system. More... | |
Data Fields inherited from qwerty_device | |
| struct xrt_device | base |
| struct xrt_pose | pose |
| Internal pose state. More... | |
| struct qwerty_system * | sys |
| Reference to the system this device is in. More... | |
| float | movement_speed |
| In meters per frame. More... | |
| bool | left_pressed |
| bool | right_pressed |
| bool | forward_pressed |
| bool | backward_pressed |
| bool | up_pressed |
| bool | down_pressed |
| float | look_speed |
| In radians per frame. More... | |
| bool | look_left_pressed |
| bool | look_right_pressed |
| bool | look_up_pressed |
| bool | look_down_pressed |
| bool | sprint_pressed |
| Movement speed boost. More... | |
| float | yaw_delta |
| How much extra yaw to add for the next pose. More... | |
| float | pitch_delta |
Similar to yaw_delta More... | |
Data Fields inherited from xrt_device | |
| enum xrt_device_name | name |
| Enum identifier of the device. More... | |
| enum xrt_device_type | device_type |
| char | str [256] |
| A string describing the device. More... | |
| char | serial [256] |
| A unique identifier. Persistent across configurations, if possible. More... | |
| struct xrt_hmd_parts * | hmd |
| Null if this device does not interface with the users head. More... | |
| struct xrt_tracking_origin * | tracking_origin |
| Always set, pointing to the tracking system for this device. More... | |
| size_t | binding_profile_count |
| Number of bindings in xrt_device::binding_profiles. More... | |
| struct xrt_binding_profile * | binding_profiles |
| size_t | input_count |
| Number of inputs. More... | |
| struct xrt_input * | inputs |
| Array of input structs. More... | |
| size_t | output_count |
| Number of outputs. More... | |
| struct xrt_output * | outputs |
| Array of output structs. More... | |
| struct xrt_device_supported | supported |
| What features/functions/things does this device supports? More... | |
| xrt_result_t(* | update_inputs )(struct xrt_device *xdev) |
| Update any attached inputs. More... | |
| xrt_result_t(* | get_tracked_pose )(struct xrt_device *xdev, enum xrt_input_name name, int64_t at_timestamp_ns, struct xrt_space_relation *out_relation) |
| Get relationship of a tracked device to the tracking origin space as the base space. More... | |
| xrt_result_t(* | get_hand_tracking )(struct xrt_device *xdev, enum xrt_input_name name, int64_t desired_timestamp_ns, struct xrt_hand_joint_set *out_value, int64_t *out_timestamp_ns) |
| Get relationship of hand joints to the tracking origin space as the base space. More... | |
| xrt_result_t(* | get_face_tracking )(struct xrt_device *xdev, enum xrt_input_name facial_expression_type, int64_t at_timestamp_ns, struct xrt_facial_expression_set *out_value) |
| Get the requested blend shape properties & weights for a face tracker. More... | |
| xrt_result_t(* | get_body_skeleton )(struct xrt_device *xdev, enum xrt_input_name body_tracking_type, struct xrt_body_skeleton *out_value) |
| Get the body skeleton in T-pose, used to query the skeleton hierarchy, scale, proportions etc. More... | |
| xrt_result_t(* | get_body_joints )(struct xrt_device *xdev, enum xrt_input_name body_tracking_type, int64_t desired_timestamp_ns, struct xrt_body_joint_set *out_value) |
| Get the joint locations for a body tracker. More... | |
| xrt_result_t(* | reset_body_tracking_calibration_meta )(struct xrt_device *xdev) |
| XR_META_body_tracking_calibration - body tracking extension to reset the body tracking calibration. More... | |
| xrt_result_t(* | set_body_tracking_calibration_override_meta )(struct xrt_device *xdev, float new_body_height) |
| XR_META_body_tracking_calibration - body tracking extension to suggest a body tracking calibration override. More... | |
| xrt_result_t(* | set_output )(struct xrt_device *xdev, enum xrt_output_name name, const struct xrt_output_value *value) |
| Set a output value. More... | |
| xrt_result_t(* | get_output_limits )(struct xrt_device *xdev, struct xrt_output_limits *limits) |
| Gets limits of this devices outputs. More... | |
| xrt_result_t(* | get_presence )(struct xrt_device *xdev, bool *presence) |
| Get current presence status of the device. More... | |
| xrt_result_t(* | begin_plane_detection_ext )(struct xrt_device *xdev, const struct xrt_plane_detector_begin_info_ext *begin_info, uint64_t plane_detection_id, uint64_t *out_plane_detection_id) |
| Begin a plane detection request. More... | |
| xrt_result_t(* | destroy_plane_detection_ext )(struct xrt_device *xdev, uint64_t plane_detection_id) |
| Destroy internal resources associated with plane_detector_id. More... | |
| xrt_result_t(* | get_plane_detection_state_ext )(struct xrt_device *xdev, uint64_t plane_detection_id, enum xrt_plane_detector_state_ext *out_state) |
| Get the state of a plane detection request. More... | |
| xrt_result_t(* | get_plane_detections_ext )(struct xrt_device *xdev, uint64_t plane_detection_id, struct xrt_plane_detections_ext *out_detections) |
| Get results of a plane detection request. More... | |
| xrt_result_t(* | get_view_poses )(struct xrt_device *xdev, const struct xrt_vec3 *default_eye_relation, int64_t at_timestamp_ns, enum xrt_view_type view_type, uint32_t view_count, struct xrt_space_relation *out_head_relation, struct xrt_fov *out_fovs, struct xrt_pose *out_poses) |
| Get the per-view pose in relation to the view space. More... | |
| xrt_result_t(* | compute_distortion )(struct xrt_device *xdev, uint32_t view, float u, float v, struct xrt_uv_triplet *out_result) |
| Compute the distortion at a single point. More... | |
| xrt_result_t(* | get_visibility_mask )(struct xrt_device *xdev, enum xrt_visibility_mask_type type, uint32_t view_index, struct xrt_visibility_mask **out_mask) |
| Get the visibility mask for this device. More... | |
| xrt_result_t(* | ref_space_usage )(struct xrt_device *xdev, enum xrt_reference_space_type type, enum xrt_input_name name, bool used) |
| Called by the xrt_space_overseer when a reference space that is implemented by this device is first used, or when the last usage of the reference space stops. More... | |
| bool(* | is_form_factor_available )(struct xrt_device *xdev, enum xrt_form_factor form_factor) |
| Check if given form factor is available or not. More... | |
| xrt_result_t(* | get_battery_status )(struct xrt_device *xdev, bool *out_present, bool *out_charging, float *out_charge) |
| Get battery status information. More... | |
| xrt_result_t(* | get_brightness )(struct xrt_device *xdev, float *out_brightness) |
| Get the current display brightness. More... | |
| xrt_result_t(* | set_brightness )(struct xrt_device *xdev, float brightness, bool relative) |
| Set the display brightness. More... | |
| xrt_result_t(* | begin_feature )(struct xrt_device *xdev, enum xrt_device_feature_type type) |
| Enable the feature for this device. More... | |
| xrt_result_t(* | end_feature )(struct xrt_device *xdev, enum xrt_device_feature_type type) |
| Disable the feature for this device. More... | |
| void(* | destroy )(struct xrt_device *xdev) |
| Destroy device. More... | |
Supports input actions and can be attached to the HMD pose.
| bool qwerty_controller::follow_hmd |
Only used when a qwerty_hmd exists in the system.
Do not modify directly; use qwerty_follow_hmd(). If true, pose is relative to the qwerty_hmd.
Referenced by qwerty_follow_hmd().