Class XRTrackableItems
Stores the current trackable items.
Implements
Inherited Members
Namespace: Evergine.Framework.XR.TrackableItems
Assembly: Evergine.Framework.dll
Syntax
public abstract class XRTrackableItems : DisposableObject, IDisposable
Constructors
XRTrackableItems()
Initializes a new instance of the XRTrackableItems class.
Declaration
public XRTrackableItems()
Fields
TrackablesById
Backing field for XRTrackableItem property.
Declaration
public ConcurrentDictionary<Guid, XRTrackableItem> TrackablesById
Field Value
Type | Description |
---|---|
ConcurrentDictionary<Guid, XRTrackableItem> |
Methods
AddTrackables(IEnumerable<XRTrackableItem>)
Executed when new trackables are detected.
Declaration
public void AddTrackables(IEnumerable<XRTrackableItem> addedTrackables)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<XRTrackableItem> | addedTrackables | Collection of detected trackables. |
ClearAllTrackables()
Clears cached trackables.
Declaration
public void ClearAllTrackables()
Destroy()
Destroy all resources of this instance.
Declaration
protected override void Destroy()
Overrides
FindTrackable(Guid)
Looks for an XRTrackableItem detected in the current frame.
Declaration
public XRTrackableItem FindTrackable(Guid trackableId)
Parameters
Type | Name | Description |
---|---|---|
Guid | trackableId | The ID of the trackable. |
Returns
Type | Description |
---|---|
XRTrackableItem | The XRTrackableItem or null if no XRTrackableItem with the specified id was found. |
RemoveTrackables(IEnumerable<Guid>)
Executed when trackables stop to be detected.
Declaration
public void RemoveTrackables(IEnumerable<Guid> removedTrackables)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<Guid> | removedTrackables | Collection of updated trackables. |
UpdateTrackables(IEnumerable<XRTrackableItem>)
Executed when already detected trackables are updated.
Declaration
public void UpdateTrackables(IEnumerable<XRTrackableItem> updatedTrackables)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<XRTrackableItem> | updatedTrackables | Collection of updated trackables. |
Events
AddedTrackables
Event launched when one or more trackables have been added
Declaration
public event EventHandler<IEnumerable<XRTrackableItem>> AddedTrackables
Event Type
Type | Description |
---|---|
EventHandler<IEnumerable<XRTrackableItem>> |
RemovedTrackables
Event launched when one or more trackables have been removed
Declaration
public event EventHandler<IEnumerable<XRTrackableItem>> RemovedTrackables
Event Type
Type | Description |
---|---|
EventHandler<IEnumerable<XRTrackableItem>> |
UpdatedTrackables
Event launched when one or more trackables have been updated
Declaration
public event EventHandler<IEnumerable<XRTrackableItem>> UpdatedTrackables
Event Type
Type | Description |
---|---|
EventHandler<IEnumerable<XRTrackableItem>> |