Rework wivrn_session to be a xrt_system_devices
This will allow changing roles dynamically, and fixes some object lifetime issues.
This commit is contained in:
@@ -28,7 +28,6 @@
|
||||
|
||||
#include <array>
|
||||
#include <cmath>
|
||||
#include <memory>
|
||||
#include <openxr/openxr.h>
|
||||
|
||||
namespace wivrn
|
||||
@@ -90,14 +89,10 @@ class wivrn_fb_face2_tracker : public xrt_device
|
||||
fb_face2_list face_list;
|
||||
xrt_input face_input;
|
||||
|
||||
std::shared_ptr<wivrn::wivrn_session> cnx;
|
||||
wivrn::wivrn_session & cnx;
|
||||
|
||||
public:
|
||||
wivrn_fb_face2_tracker(xrt_device * hmd, std::shared_ptr<wivrn::wivrn_session> cnx);
|
||||
void unregister()
|
||||
{
|
||||
cnx = nullptr;
|
||||
}
|
||||
wivrn_fb_face2_tracker(xrt_device * hmd, wivrn::wivrn_session & cnx);
|
||||
|
||||
void update_inputs();
|
||||
void update_tracking(const from_headset::tracking &, const clock_offset &);
|
||||
|
||||
Reference in New Issue
Block a user