class WayspotAnchorController (Niantic.ARDK.AR.WayspotAnchors.WayspotAnchorController)
Overview
class WayspotAnchorController { public: // fields ArdkEventHandler<LocalizationStateUpdatedArgs> LocalizationStateUpdated; ArdkEventHandler<WayspotAnchorsCreatedArgs> WayspotAnchorsCreated; ArdkEventHandler<WayspotAnchorStatusUpdatedArgs> WayspotAnchorStatusUpdated; ArdkEventHandler<WayspotAnchorsResolvedArgs> WayspotAnchorsTrackingUpdated; // methods Guid[] CreateWayspotAnchors(params Matrix4x4[] localPoses); void PauseTracking(params IWayspotAnchor[] wayspotAnchors); IWayspotAnchor[] RestoreWayspotAnchors(params WayspotAnchorPayload[] wayspotAnchorPayloads); void ResumeTracking(params IWayspotAnchor[] wayspotAnchors); void StartVps(IWayspotAnchorsConfiguration wayspotAnchorsConfiguration); void StopVps(); WayspotAnchorController(IARSession arSession, ILocationService locationService); };
Detailed Documentation
Fields
ArdkEventHandler<LocalizationStateUpdatedArgs> LocalizationStateUpdated
Called when the localization status has changed.
ArdkEventHandler<WayspotAnchorsCreatedArgs> WayspotAnchorsCreated
Called when new anchors have been created.
ArdkEventHandler<WayspotAnchorStatusUpdatedArgs> WayspotAnchorStatusUpdated
Called when the status of wayspot anchors has changed.
ArdkEventHandler<WayspotAnchorsResolvedArgs> WayspotAnchorsTrackingUpdated
Called when wayspot anchors report a new position/rotation.
Methods
Guid[] CreateWayspotAnchors(params Matrix4x4[] localPoses)
Creates new wayspot anchors based on position and rotations.
Parameters:
localPoses |
The position and rotation used to create new wayspot anchors with |
Returns:
The IDs of the newly created wayspot anchors
void PauseTracking(params IWayspotAnchor[] wayspotAnchors)
Pauses the tracking of wayspot anchors. This can be used to conserve resources for wayspot anchors which you currently do not care about, but may again in the future.
Parameters:
wayspotAnchors |
The wayspot anchors to pause tracking for |
IWayspotAnchor[] RestoreWayspotAnchors(params WayspotAnchorPayload[] wayspotAnchorPayloads)
Restores previously created wayspot anchors via their payloads. Use this to restore wayspot anchors from the payload stored in your database from a another session.
Parameters:
wayspotAnchorPayloads |
The payload (data) used to restore previously created wayspot anchors |
Returns:
The restored wayspot anchors
void ResumeTracking(params IWayspotAnchor[] wayspotAnchors)
Resumes the tracking of previously paused wayspot anchors.
Parameters:
wayspotAnchors |
The wayspot anchors to resume tracking for |
void StartVps(IWayspotAnchorsConfiguration wayspotAnchorsConfiguration)
Starts the virtual position system.
Parameters:
wayspotAnchorsConfiguration |
The configuration to start VPS with |
void StopVps()
Stops the virtual position system.
Note
This will reset the state and stop all pending creations and trackings
WayspotAnchorController(IARSession arSession, ILocationService locationService)
Creates a new wayspot anchor API to consume.
Parameters:
arSession |
The AR session required by the WayspotAnchorController to run VPS. |
locationService |
The location service required by the WayspotAnchorController to run VPS. |