HoloLens 2 Gait Training
The purpose of this project is to create gait training application.
|
A singleton Instance to track Camera Movements This will also calculate distance, rotation and speed (Km/h). More...
Properties | |
static CamMovementTracker | m_CamTrackerInstance [get, private set] |
Singleton Instance We have 1 Camera instance and 1 User at all time. Therefore, I believe Singleton is useful in this case. More... | |
float | Speed [get, private set] |
Property to get and set Speed. More... | |
float | RotationDelta [get, private set] |
Property to get and set RotationDelta. More... | |
float | Distance [get, private set] |
Property to get and set Distance. More... | |
bool | IsMoving [get, private set] |
Property to get and set IsMoving flag. More... | |
Private Member Functions | |
void | Awake () |
If there is an instance, and it is not me, delete myself. More... | |
void | Start () |
Start is called before the first frame update. More... | |
void | Update () |
Update is called once per frame. More... | |
float | CalculateDistanceCovered () |
Calculate Distance More... | |
float | CalculateSpeed () |
Calculate Speed in killo meters per hour. More... | |
float | CalculateRotation () |
Calculate the rotations. More... | |
bool | IsCameraMoving (float speed) |
Calculate whether the player is moving or not. More... | |
Private Attributes | |
readonly float | m_SampleTime = 1.0f |
Just a default value to compare against. More... | |
Vector3 | m_LastSampleLocation |
Holds last location value More... | |
Quaternion | m_LastSampleRotation |
Holds last rotation value. More... | |
float | m_LastSampleTime |
Holds last timestamp value. More... | |
A singleton Instance to track Camera Movements This will also calculate distance, rotation and speed (Km/h).
Definition at line 10 of file CamMovementTracker.cs.
|
inlineprivate |
If there is an instance, and it is not me, delete myself.
Definition at line 47 of file CamMovementTracker.cs.
|
inlineprivate |
Calculate Distance
Definition at line 86 of file CamMovementTracker.cs.
|
inlineprivate |
Calculate the rotations.
Definition at line 102 of file CamMovementTracker.cs.
|
inlineprivate |
Calculate Speed in killo meters per hour.
Definition at line 94 of file CamMovementTracker.cs.
|
inlineprivate |
Calculate whether the player is moving or not.
Definition at line 110 of file CamMovementTracker.cs.
|
inlineprivate |
Start is called before the first frame update.
Definition at line 60 of file CamMovementTracker.cs.
|
inlineprivate |
Update is called once per frame.
Definition at line 68 of file CamMovementTracker.cs.
|
private |
Holds last location value
Definition at line 24 of file CamMovementTracker.cs.
|
private |
Holds last rotation value.
Definition at line 27 of file CamMovementTracker.cs.
|
private |
Holds last timestamp value.
Definition at line 30 of file CamMovementTracker.cs.
|
private |
Just a default value to compare against.
Definition at line 21 of file CamMovementTracker.cs.
|
getprivate set |
Property to get and set Distance.
Definition at line 39 of file CamMovementTracker.cs.
|
getprivate set |
Property to get and set IsMoving flag.
Definition at line 42 of file CamMovementTracker.cs.
|
staticgetprivate set |
Singleton Instance We have 1 Camera instance and 1 User at all time. Therefore, I believe Singleton is useful in this case.
Definition at line 17 of file CamMovementTracker.cs.
|
getprivate set |
Property to get and set RotationDelta.
Definition at line 36 of file CamMovementTracker.cs.
|
getprivate set |
Property to get and set Speed.
Definition at line 33 of file CamMovementTracker.cs.