Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question Confirmation of marker image recognition and release status for AR image tracking work?

Discussion in 'AR' started by zooltagi, Mar 8, 2023.

  1. zooltagi


    Feb 16, 2017
    Help me
    I am making an AR game using image tracking technique in unity3d.
    After loading the desired 3D modeling object into the marker image, I plan to shoot and kill this object.
    I want to give a signal to find the marker image again and recognize it when the distance from the marker image is away or the marker image is out of the camera.
    When the image tracking is released away from the marker image, the object floats alone. At this time, I want to turn the object off the screen.
    In image tracking, can I receive the signal of the situation where the marker image is recognized and the situation where it is not recognized?
  2. andyb-unity


    Unity Technologies

    Feb 10, 2022
    You have a couple options.

    MonoBehaviour.OnBecameInvisible will trigger once the GameObject is no longer in the camera frustum, which can be useful for detecting the moment that the camera is no longer pointed at the image:

    Image trackingState may go to Limited if the platform loses its ability to track the image: However, the platform will continue to try to track the image even when it is offscreen, so this state change may not fire the moment the image goes offscreen.