Monado OpenXR Runtime
t_tracker_psmv_fusion.hpp
Go to the documentation of this file.
1// Copyright 2019, Collabora, Ltd.
2// SPDX-License-Identifier: BSL-1.0
3/*!
4 * @file
5 * @brief PS Move tracker code.
6 * @author Pete Black <pblack@collabora.com>
7 * @author Jakob Bornecrantz <jakob@collabora.com>
8 * @author Rylie Pavlik <rylie.pavlik@collabora.com>
9 * @ingroup aux_tracking
10 */
11
12#pragma once
13
14#ifndef __cplusplus
15#error "This header is C++-only."
16#endif
17
18#include "xrt/xrt_defines.h"
19#include "xrt/xrt_tracking.h"
20
21#include "util/u_time.h"
22
23#include <memory>
24
25
26namespace xrt::auxiliary::tracking {
27
29{
30public:
31 static std::unique_ptr<PSMVFusionInterface>
32 create();
33 virtual ~PSMVFusionInterface() = default;
34
35 /*!
36 * @brief If you've lost sight of the position tracking and won't even
37 * enter another function in this class.
38 */
39 virtual void
41
42 virtual void
43 process_imu_data(timepoint_ns timestamp_ns,
44 const struct xrt_tracking_sample *sample,
45 const struct xrt_vec3 *orientation_variance_optional) = 0;
46 virtual void
47 process_3d_vision_data(timepoint_ns timestamp_ns,
48 const struct xrt_vec3 *position,
49 const struct xrt_vec3 *variance_optional,
50 const struct xrt_vec3 *lever_arm_optional,
51 float residual_limit) = 0;
52
53 virtual void
54 get_prediction(timepoint_ns when_ns, struct xrt_space_relation *out_relation) = 0;
55};
56} // namespace xrt::auxiliary::tracking
Definition: t_tracker_psmv_fusion.hpp:29
virtual void clear_position_tracked_flag()=0
If you've lost sight of the position tracking and won't even enter another function in this class.
int64_t timepoint_ns
Integer timestamp type.
Definition: u_time.h:70
static Eigen::Map< const Eigen::Vector3f > position(const struct xrt_pose &pose)
Return a Eigen type wrapping a pose's position (const).
Definition: m_eigen_interop.hpp:217
A relation with two spaces, includes velocity and acceleration.
Definition: xrt_defines.h:657
IMU Sample.
Definition: xrt_tracking.h:117
A 3 element vector with single floats.
Definition: xrt_defines.h:271
Time-keeping: a clock that is steady, convertible to system time, and ideally high-resolution.
Common defines and enums for XRT.
Header defining the tracking system integration in Monado.