Interface ICalculateLandmarks
Components that implement this interface can define landmarks
Namespace: Unity.MARS.Landmarks
Syntax
public interface ICalculateLandmarks
Properties
AvailableLandmarkDefinitions
A list of landmark definitions that this class can support.
Declaration
List<LandmarkDefinition> AvailableLandmarkDefinitions { get; }
Property Value
Type | Description |
---|---|
List<LandmarkDefinition> |
Methods
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
Action<ILandmarkController> GetLandmarkCalculation(LandmarkDefinition definition)
Parameters
Type | Name | Description |
---|---|---|
LandmarkDefinition | definition | The landmark definition to get the calculation for |
Returns
Type | Description |
---|---|
Action<ILandmarkController> |
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
void SetupLandmark(ILandmarkController landmark)
Parameters
Type | Name | Description |
---|---|---|
ILandmarkController | landmark | The landmark to setup. |
Events
dataChanged
This event can be invoked by the landmark source to indicate the source data has changed. By default, landmarks referencing this source will subscribe to this event and update.
Declaration
event Action<ICalculateLandmarks> dataChanged
Event Type
Type | Description |
---|---|
Action<ICalculateLandmarks> |