Start a new topic

Multiple Objects Trackers

I'm trying to have multiple object trackers the same way as multiple image trackers example.

I'm switching from one tracker to another when clicking on a button but the tracker does not switch and stay on the same 3D object.


public GameObject figureInstructions;
public GameObject teaInstructions;

public ObjectTracker figureTracker;
public ObjectTracker teaTracker;

private bool _waitingForTrackerToLoad = false;

 public void OnFigureTracker()
        if(!figureTracker.enabled && !_waitingForTrackerToLoad)
            _waitingForTrackerToLoad = true;

            figureTracker.enabled = true;
            teaTracker.enabled = false;

    public void OnTeaTracker()
        if (!teaTracker.enabled && !_waitingForTrackerToLoad)
            _waitingForTrackerToLoad = true;

            teaTracker.enabled = true;
            figureTracker.enabled = false;

    public override void OnTargetsLoaded()
        _waitingForTrackerToLoad = false;
        Debug.Log("OnTargetsLoaded " + _waitingForTrackerToLoad);

 What am I doing wrong ?

Thank you.






1 Comment

Hello Cedric,

It is not possible to track multiple objects at the same time, so you need to implement them like the Different Targets sample. It is possible to have one .wto file with multiple objects, it is just that you cannot recognize them at the same time and this is why you need to implement it with the sample I suggested.



Login or Signup to post a comment