Log in or register to post comments

Using two different trackers

September 3, 2011 - 5:27pm #1

Hey,

I'm exploring the ImageTargets app and I want to replace both trackers with different images. I used the target management system and created two different trackers with medium quality. I also have two different pngs to use in each tracker.

I've tested each target individually and they are working fine. But how can I make both trackers work at the same time with different pictures on them?

Thanks

Re: Using two different trackers

September 5, 2011 - 3:06am #4

Hi maveryck21,

Although for your use case you don't need the two targets visible simultaneously, to QCAR the configuration is the same whether the targets are both in view or singly in view - it is set up to detect two different targets and will present the augmentation for all those currently detected within the camera view, gated by the HINT_MAX_SIMULTANEOUS_IMAGE_TARGETS value.

As a test you could try the original code for ImageTargets, and build that to see if it does exactly what you need as I believe it should. If this works, this should help you to debug what is causing the problem in your modified version.

Re: Using two different trackers

September 4, 2011 - 9:11am #3

Yeah it was a mistake.

I've already changed that line (read it on the dev guide) but it still not working.

I don't need the targets to be tracked at the same time. I want to display different images when each target is presented. The problem is that only the first target is working.

int textureIndex = (!strcmp(trackable->getName(), "vivaViagem")) ? 0 : 1;

If I'm not mistaken I needed to change the name of the target to the name of my first target on the config.xml right?

this is my config.xml:







is this correct?

Re: Using two different trackers

September 4, 2011 - 7:37am #2

Confirm that HINT_MAX_SIMULTANEOUS_IMAGE_TARGETS is set to 2, or how ever many trackables you want to track at the same time.

Also the 'tracker' is the SDK component that tracks the targets. What you're referring to is known as the trackable or target.

Log in or register to post comments