Class VuforiaService
Vuforia service implementation.
Inheritance
Implements
Inherited Members
Namespace: Evergine.Vuforia
Assembly: Evergine.Vuforia.dll
Syntax
public class VuforiaService : UpdatableService, IDependencyObject
  Properties
DataSets
Gets the dataset collection.
Declaration
public IEnumerable<VuforiaDataSet> DataSets { get; }
  Property Value
| Type | Description | 
|---|---|
| IEnumerable<VuforiaDataSet> | 
DeviceIsOpticalSeeThrough
Gets or sets a value indicating whether the device is an optical see-through device, such as the HoloLens is attached.
Declaration
public bool DeviceIsOpticalSeeThrough { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
EnableVideoBackground
Gets or sets a value indicating whether is video background enabled.
Declaration
public bool EnableVideoBackground { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
IsSupported
Gets a value indicating whether Vuforia is Supported.
Declaration
public bool IsSupported { get; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
LicenseKey
Gets or sets the Vuforia license key that is used for this app.
Declaration
[RenderProperty(CustomPropertyName = "License Key", Tooltip = "The Vuforia license key that is used for this app")]
public string LicenseKey { get; set; }
  Property Value
| Type | Description | 
|---|---|
| string | 
Exceptions
| Type | Condition | 
|---|---|
| InvalidOperationException | License key cannot be changed while Vuforia tracking is active.  | 
      
MaxSimultaneousTrackedImages
Gets or sets how many image targets to detect and track at the same time.
Declaration
public int MaxSimultaneousTrackedImages { get; set; }
  Property Value
| Type | Description | 
|---|---|
| int | 
Remarks
Tells the tracker how many image shall be processed at most at the same time.E.g. if an app will never require tracking more than two targets, this value should be set to 2. Default is: 1.
MaxSimultaneousTrackedObjects
Gets or sets how many object targets to detect and track at the same time.
Declaration
public int MaxSimultaneousTrackedObjects { get; set; }
  Property Value
| Type | Description | 
|---|---|
| int | 
Remarks
Tells the tracker how many 3D objects shall be processed at most at the same time.E.g. if an app will never require tracking more than 1 target, this value should be set to 1. Default is: 1.
StartTrackingAutomatically
Gets or sets a value indicating whether the target tracking will be started automatically when the service is attached.
Declaration
public bool StartTrackingAutomatically { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
TrackDevicePose
Gets or sets a value indicating whether exists a track device pose.
Declaration
public bool TrackDevicePose { get; set; }
  Property Value
| Type | Description | 
|---|---|
| bool | 
TrackableResults
Gets the Trackable objects currently being tracked.
Declaration
public IEnumerable<TrackableResult> TrackableResults { get; }
  Property Value
| Type | Description | 
|---|---|
| IEnumerable<TrackableResult> | 
TrackingState
Gets the Vuforia service tracking state.
Declaration
public VuforiaState TrackingState { get; }
  Property Value
| Type | Description | 
|---|---|
| VuforiaState | 
VideoBackgroundMesh
Gets the video background mesh.
Declaration
public Mesh VideoBackgroundMesh { get; }
  Property Value
| Type | Description | 
|---|---|
| Mesh | 
VideoBackgroundTexture
Gets the video background texture.
Declaration
public Texture VideoBackgroundTexture { get; }
  Property Value
| Type | Description | 
|---|---|
| Texture | 
VuforiaDeviceType
Gets the current Vuforia device type.
Declaration
public VuforiaDeviceType VuforiaDeviceType { get; }
  Property Value
| Type | Description | 
|---|---|
| VuforiaDeviceType | 
WorldCenterMode
Gets the Vuforia world center mode.
Declaration
public WorldCenterMode WorldCenterMode { get; }
  Property Value
| Type | Description | 
|---|---|
| WorldCenterMode | 
Methods
AddDataSet(VuforiaDataSet)
Adds a dataset to collection.
Declaration
public void AddDataSet(VuforiaDataSet dataSet)
  Parameters
| Type | Name | Description | 
|---|---|---|
| VuforiaDataSet | dataSet | The new dataset.  | 
      
OnActivated()
Invoked when the object is activated once is attached.
Declaration
protected override void OnActivated()
  Overrides
OnDeactivated()
Invoked when the object is deactivated.
Declaration
protected override void OnDeactivated()
  Overrides
StartTrackingAsync()
Starts the Vuforia target tracking.
Declaration
public Task<bool> StartTrackingAsync()
  Returns
| Type | Description | 
|---|---|
| Task<bool> | 
  | 
      
StopTrackingAsync()
Stops the Vuforia target tracking.
Declaration
public Task<bool> StopTrackingAsync()
  Returns
| Type | Description | 
|---|---|
| Task<bool> | 
  | 
      
Update(TimeSpan)
Updates this instance.
Declaration
public override void Update(TimeSpan gameTime)
  Parameters
| Type | Name | Description | 
|---|---|---|
| TimeSpan | gameTime | The elapsed game time since the last update.  | 
      
Overrides
Events
OnTrackingStateChanged
Event raised on tracking state changed.
Declaration
public event EventHandler<VuforiaState> OnTrackingStateChanged
  Event Type
| Type | Description | 
|---|---|
| EventHandler<VuforiaState> |