1

So I have an app that uses Wikitude to recognize images. When an image is recognized I show a popup that gives the name of the image back. When the user clicks on done in the popup the image should be trackable again. But now everything works except for the image to be trackable again (unless i go off the image and go back on the image)

from the js file:

imageRcognized: function(name) {
        AR.platform.sendJSONObject(name);
    },

from C# delegate

public class PopUpdel : WTArchitectViewDelegate
{
    VC _presentingVC;

    public PopUpdel(VC presentingVC)
    {
        _presentingVC = presentingVC;
    }

    public override void ReceivedJSONObject(WTArchitectView architectView, NSDictionary jsonObject)
    {
        WikitudeScanResult result = new WikitudeScanResult()
        {
            name = jsonObject.ValueForKey(new NSString("name")).ToString()
        };
        _presentingVC.Tracked(result);
    }

    public void Tracked(WikitudeScanResult result)
    {
        //show popup 
    }

Now only thing that rest is reset the image so it can be scanned again

test
  • 33
  • 8
  • please post the relevant code – Jason Jul 11 '18 at 12:05
  • @Jason Added some code – test Jul 11 '18 at 12:22
  • You could set ImageTracker.enabled to false when it is recognized and to true once you want to recognize it again. – Someone Jul 12 '18 at 05:51
  • @Alex put it as a normal comment then I can accept it, it fixed my problem (on android i fixed it with destroy and recreate but iOS did not allow this) so with your advice I changed it and your solution worked for both ty – test Jul 19 '18 at 10:25

1 Answers1

0

You could set ImageTracker.enabled to false when it is recognized and to true once you want to recognize it again.

Someone
  • 560
  • 9
  • 21