documentation

VLModelTrackableBehaviour Class Reference

Behaviour, which enables the user to use the GameObjects mesh for tracking. NOTE: This behaviour is considered as BETA. Please do not alter this file unless you know what you are doing - it is considered to be changed and optimized in future versions. More...

Inherits VLClientData.

Public Member Functions

void SetUseAsOccluder (bool enable)
 Defines, if this mesh should be used as an occlusion geometry in the tracking system. It is only active, if useForTracking is true. More...
 
void SetUseModelForTracking (bool enable)
 Enables the model in the tracking system. If occluder is true, it will be used as an occlusion geometry. More...
 
void UpdateModel (bool success=true)
 Add all (sub)meshes to the tracking system. If a sub mesh has its own VLModelTrackableBehaviour, it will not be added, but this behaviour should manage the relevant submeshes. More...
 
void UpdateTransformation (bool useAllChildNodes)
 Updates the transformation of all (sub)meshes in the tracking system. It has to be called after each update in a transform which is relevant for the location of a related mesh. More...
 

Data Fields

List< VLModelDeserializationResultmodelDescriptions
 List of model descriptions, which are currently used for tracking. More...
 
bool occluder = false
 Enable/Disable this property in order to use/not use all models in this object for occlusion tracking. More...
 
bool useForTracking = true
 Enable/Disable this property in order to use/not use all models in this object for tracking. More...
 

Protected Attributes

VLHoloLensTrackerBehaviour holoLensTrackerBehaviour
 HoloLens Tracker Behaviour used in this tracking scenario. This behaviour tries to find the corresponding VLHoloLensTrackerBehaviour automatically if not defined. More...
 
VLModelTrackerBehaviour_v1 modelTrackerBehaviour
 ModelTracker Behaviour used in this tracking scenario. This behaviour tries to find the corresponding VLModelTrackerBehaviour automatically if not defined. More...
 
- Protected Attributes inherited from VLWorkerReferenceBehaviour
VLWorker worker
 
VLWorkerBehaviour workerBehaviour
 Reference to used VLWorkerBehaviour. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from VLClientData
static VLClientData ToVLClientData (IntPtr ptr)
 
- Protected Member Functions inherited from VLClientData
IntPtr ToIntPtr ()
 
- Protected Member Functions inherited from VLWorkerReferenceBehaviour
virtual bool InitWorkerReference ()
 Initializes the workerBehaviour and Worker member variables. More...
 

Detailed Description

Behaviour, which enables the user to use the GameObjects mesh for tracking. NOTE: This behaviour is considered as BETA. Please do not alter this file unless you know what you are doing - it is considered to be changed and optimized in future versions.

USAGE: You can add this behaviour to an UnityObject which might contain a mesh. You can allow the transmission of the model inside your definition using the useForTracking flag. If you enable the occluder property, it will be rendered for occlusion of objects while tracking. If you want to disable the visibility of the object in Unity, disable the mesh.

Member Function Documentation

◆ SetUseAsOccluder()

void VLModelTrackableBehaviour.SetUseAsOccluder ( bool  enable)
inline

Defines, if this mesh should be used as an occlusion geometry in the tracking system. It is only active, if useForTracking is true.

◆ SetUseModelForTracking()

void VLModelTrackableBehaviour.SetUseModelForTracking ( bool  enable)
inline

Enables the model in the tracking system. If occluder is true, it will be used as an occlusion geometry.

◆ UpdateModel()

void VLModelTrackableBehaviour.UpdateModel ( bool  success = true)
inline

Add all (sub)meshes to the tracking system. If a sub mesh has its own VLModelTrackableBehaviour, it will not be added, but this behaviour should manage the relevant submeshes.

◆ UpdateTransformation()

void VLModelTrackableBehaviour.UpdateTransformation ( bool  useAllChildNodes)
inline

Updates the transformation of all (sub)meshes in the tracking system. It has to be called after each update in a transform which is relevant for the location of a related mesh.

Parameters
useAllChildNodesIf useAllChildNodes is true, this will update all locations of submeshes, even if they have their own VLModelTrackableBehaviour. It does not update the modelDescriptions of this behaviour.

Field Documentation

◆ holoLensTrackerBehaviour

VLHoloLensTrackerBehaviour VLModelTrackableBehaviour.holoLensTrackerBehaviour
protected

HoloLens Tracker Behaviour used in this tracking scenario. This behaviour tries to find the corresponding VLHoloLensTrackerBehaviour automatically if not defined.

◆ modelDescriptions

List<VLModelDeserializationResult> VLModelTrackableBehaviour.modelDescriptions

List of model descriptions, which are currently used for tracking.

◆ modelTrackerBehaviour

VLModelTrackerBehaviour_v1 VLModelTrackableBehaviour.modelTrackerBehaviour
protected

ModelTracker Behaviour used in this tracking scenario. This behaviour tries to find the corresponding VLModelTrackerBehaviour automatically if not defined.

◆ occluder

bool VLModelTrackableBehaviour.occluder = false

Enable/Disable this property in order to use/not use all models in this object for occlusion tracking.

◆ useForTracking

bool VLModelTrackableBehaviour.useForTracking = true

Enable/Disable this property in order to use/not use all models in this object for tracking.