0 votes
by (8.2k points)

I want to make all this information displayed on the screen only after scanning the image and it should not go from that until I want to hide that from the screen.

1 Answer

0 votes
by (8.2k points)

Ok so once you scan it, it will appear and then you want it to disappear on a defined function?

From the image target, remove the Default trackable event handler script and attach this script.
Default trackable event handler script

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Tracker : DefaultTrackableEventHandler
{
    override protected void Start()
    {
        base.Start();
    }
    override protected void OnTrackingFound()
    {
//Turn on the mesh renderer
 
    }
    protected override void OnTrackingLost()
    {
//turn off the mesh renderer
    }
 
}

TechXR runs courses in AR / VR / Metaverse / Game Development. Some of the popular Q&A in our courses are available here for easy discovery.

113 questions

117 answers

77 comments

107k users

...