Log in or register to post comments

Rebooting tracker data

March 5, 2013 - 4:10am #1

Hi everybody,

I'm making some changes to the ImageTargets.cpp from the ImageTargets example app to get to know how much time does the app need to track an object.

To have accurate results for this experiment I have thought of this:

The first time that the app tracks the object I force the app to think that it has not been found changing the state to UNKNOWN;

Then I would like to reboot all the data from the tracker, forcing it to track the object from the begining again, this point is where I start the time counter.

When the object is tracked again I should get really accurate data of how much time does the app need to track that texture.

I've tried deinitializing and initializing the tracker, but my idea dont seems to work, cause the time I get is really little, like 0,000008 secs.

Do you have any idea of how could I do it or what function should I use to clear all that data?

Thanks for your time!

David

Rebooting tracker data

March 7, 2013 - 11:08am #6

Glad to help ;-)

Rebooting tracker data

March 7, 2013 - 1:43am #5

Hi Alessandro,

Yeah, that makes sense, and I guess I have no other way to do it that cause I've been trying to find the way for almost 2 months and I'm still here with that problem

So thanks for your idea, I hope it works fine!

Rebooting tracker data

March 6, 2013 - 11:20am #4

Hi, in my idea you don't need to explicitely start/stop the tracker;

you can just start the tracker at application startup like in the Image targets sample, but then you can do this "manual" operation:

  • when the application starts, make sure that you are not pointing your device camera towards the target;
  • then, when you are ready, move the device towards the target so that the target suddenly enters the camera field of view;
  • at that moment (i.e. when you move your device as above) you can press the button so to record the "start time" in the native code;
  • then, when the target becomes "detected" you can just read the current time and compare it with the start time.

Does it make sense ?

Rebooting tracker data

March 6, 2013 - 1:33am #3

Thanks AlenssandroB, you saved a lot of my time with that explanation.

I think the idea of the button is great, but how should I implement that?How could I make the processes that are responsible of the detecting and tracking to stop until I press my button?

I'm really lost with that, so I would appreciate a good explanation

Thanks again!

Rebooting tracker data

March 5, 2013 - 7:46am #2

Hi, I think your idea is interesting but it porbably does not work because of the complexity of the Vuforia internal logic (which relies on background / multi-threaded model); so, even if you "clear" and/or "deinit" the tracker, the target will be re-detected immediately (if it was just detected).

My suggestion would be to start counting the elapsed time from a point in time which you define manually;

for instance you could imagine to have a button on the screen and start counting the time elapsed (until the target is detected) from the moment that you press the button;

so, you could for instance aim your device camera towards the target and press the button at that time; maybe this will be not extremely accurate, but at least it is reliable.

 

Log in or register to post comments