Monado OpenXR Runtime
Loading...
Searching...
No Matches
oxr_set_haptic.c File Reference

Holds action state get related functions. More...

#include "oxr_set_haptic.h"
#include "oxr_subaction.h"
#include "oxr_input.h"
#include "../oxr_objects.h"
#include "../oxr_logger.h"
Include dependency graph for oxr_set_haptic.c:

Macros

#define SET_OUT_VIBRATION(X)
 
#define STOP_VIBRATION(X)
 

Functions

static void set_action_output_vibration (struct oxr_logger *log, struct oxr_session *sess, struct oxr_action_cache *cache, int64_t stop, const XrHapticVibration *data)
 
static XRT_MAYBE_UNUSED void set_action_output_vibration_pcm (struct oxr_logger *log, struct oxr_session *sess, struct oxr_action_cache *cache, const XrHapticPcmVibrationFB *data)
 
XrResult oxr_action_apply_haptic_feedback (struct oxr_logger *log, struct oxr_session *sess, uint32_t act_key, struct oxr_subaction_paths subaction_paths, const XrHapticBaseHeader *hapticEvent)
 
XrResult oxr_action_stop_haptic_feedback (struct oxr_logger *log, struct oxr_session *sess, uint32_t act_key, struct oxr_subaction_paths subaction_paths)
 

Detailed Description

Holds action state get related functions.

Macro Definition Documentation

◆ SET_OUT_VIBRATION

#define SET_OUT_VIBRATION (   X)
Value:
if (act_attached->X.current.active && (subaction_paths.X || subaction_paths.any)) { \
set_action_output_vibration(log, sess, &act_attached->X, stop_ns, data); \
}

◆ STOP_VIBRATION

#define STOP_VIBRATION (   X)
Value:
if (is_focused && act_attached->X.current.active && (subaction_paths.X || subaction_paths.any)) { \
oxr_action_cache_stop_output(log, sess, &act_attached->X); \
}