Class SpectatorViewPoseCache
Caches poses with timestamps from a HoloLens and allows computing a synthesized pose from any timestamp.
Inherited Members
Namespace: Microsoft.MixedReality.SpectatorView
Assembly: cs.temp.dll.dll
Syntax
[Serializable]
public class SpectatorViewPoseCache
Fields
poses
Declaration
public List<SpectatorViewPoseCache.PoseData> poses
Field Value
Type | Description |
---|---|
List<Spectator |
Methods
AddPose(Vector3, Quaternion, Single)
Adds a pose to the cache.
Declaration
public bool AddPose(Vector3 position, Quaternion rotation, float timeStamp)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | position | The position for the pose. |
Quaternion | rotation | The rotation for the pose. |
Single | timeStamp | The timestamp in seconds of the pose. |
Returns
Type | Description |
---|---|
Boolean | True if the pose was insert, false if the pose was already in the cache. |
GetLatestPose()
Gets the latest pose added to the cache.
Declaration
public SpectatorViewPoseCache.PoseData GetLatestPose()
Returns
Type | Description |
---|---|
Spectator |
The most-recent pose available. |
GetPose(Single, out Vector3, out Quaternion)
Gets a synthesized pose from a timestamp. Positions are synthensized by interpolating the recorded poses nearest to the pose time.
Declaration
public bool GetPose(float poseTime, out Vector3 position, out Quaternion rotation)
Parameters
Type | Name | Description |
---|---|---|
Single | poseTime | The timestamp to synthesize a pose for. |
Vector3 | position | The position synthesized for the pose. |
Quaternion | rotation | The rotation synthesized for the pose. |
Returns
Type | Description |
---|---|
Boolean |
Reset()
Declaration
public void Reset()