LeiaSR SDK 720218b2 v1.32.7.6322 2025-02-13T14:55:38Z
Stable
predictingweavertracker.h
Go to the documentation of this file.
1
5#pragma once
6
10
11#ifdef WIN32
12# ifdef COMPILING_DLL_SimulatedRealityFaceTrackers
13# define DIMENCOSR_API __declspec(dllexport)
14# else
15# define DIMENCOSR_API __declspec(dllimport)
16# endif
17#else
18# define DIMENCOSR_API
19#endif
20
21namespace SR {
22
29 class Impl;
35#pragma warning(suppress: 4251)
36 std::unique_ptr<Impl> pimpl;
37
38public:
48
53
55
65 void predict(uint64_t latency, SR_weaverPosition& output);
66
75 void predict(uint64_t latency);
76
77 // Inherited via WeaverTracker
78 virtual std::string getName() override;
79 virtual std::string getDescription() override;
80 virtual void start() override;
81 virtual void stop() override;
82 virtual std::shared_ptr<WeaverPositionStream> openWeaverPositionStream(WeaverPositionListener* listener) override;
83 virtual void streamClosed(WeaverPositionStream* stream) override;
84
85 // Inherited via EyePairListener
86
92 virtual void accept(const SR_eyePair& frame) override;
93};
94
95}
96
97#undef DIMENCOSR_API
Interface for listening to SR_eyePair updates.
Definition: eyepairlistener.h:15
Sense class which provides face tracking functionality to the SR system.
Definition: eyetracker.h:35
Sense class which provides predictive weaver position tracking functionality.
Definition: predictingweavertracker.h:28
virtual void streamClosed(WeaverPositionStream *stream) override
Closes a specific WeaverPositionStream.
void predict(uint64_t latency)
Predict for a certain latency and trigger stream output Should not be used directly,...
void predict(uint64_t latency, SR_weaverPosition &output)
Predict for a certain latency and trigger stream output Should not be used directly,...
PredictingWeaverTracker(EyeTracker *rawEyeTracker)
Constructs a PredictingWeaverTracker.
virtual void accept(const SR_eyePair &frame) override
Receives SR_eyePair to filter and use in predictions.
virtual std::shared_ptr< WeaverPositionStream > openWeaverPositionStream(WeaverPositionListener *listener) override
Creates a WeaverPositionStream for listener to be connected to.
virtual std::string getDescription() override
Return a description of the sense.
static PredictingWeaverTracker * create(SRContext &context)
Returns a class of PredictingWeaverTracker.
virtual void start() override
Start continuous updates, default behaviour is defined in the updater() function.
virtual void stop() override
Stop continuous updates.
virtual std::string getName() override
Return the name of the sense.
Maintains WorldObject and Sense objects during the application lifetime.
Definition: srcontext.h:75
Interface for listening to SR_weaverPosition updates.
Definition: weaverpositionlistener.h:15
Stream of SR_weaverPosition objects.
Definition: weaverpositionstream.h:30
Sense class which provides weave tracking functionality to the SR system.
Definition: weavertracker.h:35
Namespace containing all C++ Simulated Reality classes.
Definition: srconfiguration.h:20
#define DIMENCOSR_API
Definition: predictingweavertracker.h:18
C-compatible struct containing the position of two eyes.
Definition: eyepair.h:23
C-compatible struct containing the weaver position.
Definition: weaverposition.h:15