Class LandmarkOutputPolygon
Component that contains polygon data for a landmark. Also a source for calculating other landmarks
from the polygon data.
Inheritance
LandmarkOutputPolygon
Syntax
public class LandmarkOutputPolygon : MonoBehaviour, ICalculateLandmarks, ILandmarkOutput, ISimulatable
Properties
AvailableLandmarkDefinitions
Declaration
public virtual List<LandmarkDefinition> AvailableLandmarkDefinitions { get; }
Property Value
Implements
localVertices
Declaration
public List<Vector3> localVertices { get; }
Property Value
Type |
Description |
List<Vector3> |
|
pose
Declaration
public Pose pose { get; set; }
Property Value
worldVertices
Declaration
public List<Vector3> worldVertices { get; }
Property Value
Type |
Description |
List<Vector3> |
|
Methods
FireDataChangeEvent()
Declaration
protected void FireDataChangeEvent()
GetLandmarkCalculation(LandmarkDefinition)
Get an action that calculates a landmark with the given definition. If the landmark
does not have the proper settings or output set up, it should return null
Declaration
public virtual Action<ILandmarkController> GetLandmarkCalculation(LandmarkDefinition definition)
Parameters
Type |
Name |
Description |
LandmarkDefinition |
definition |
The landmark definition to get the calculation for
|
Returns
Implements
SetPolygonLocalSpace(List<Vector3>, Pose)
Declaration
public void SetPolygonLocalSpace(List<Vector3> newLocalVertices, Pose newPose)
Parameters
Type |
Name |
Description |
List<Vector3> |
newLocalVertices |
|
Pose |
newPose |
|
SetPolygonWorldSpace(List<Vector3>, Pose)
Declaration
public void SetPolygonWorldSpace(List<Vector3> newWorldVertices, Pose newPose)
Parameters
Type |
Name |
Description |
List<Vector3> |
newWorldVertices |
|
Pose |
newPose |
|
SetupLandmark(ILandmarkController)
Called when a landmark is set to reference this source, or when the definition is changed.
The source can use this to set the default starting properties and location for the landmark.
Declaration
public void SetupLandmark(ILandmarkController landmark)
Parameters
Implements
UpdateOutput()
Called to apply the output data to the attached gameobject or scene.
This is called by the landmark controller automatically after calling the source's calculation method.
Declaration
public void UpdateOutput()
Implements
Events
dataChanged
Declaration
public event Action<ICalculateLandmarks> dataChanged
Event Type
Implements
Extension Methods