Log in or register to post comments

A little question about config.xml

March 30, 2011 - 6:44am #1

Hi,

I want to build an application in which I will be able to launch either the frame tracker or the Image tracker algorithm. Do I have to make two config.xml files? Is it possible by the way? Or do I have to change the config.xml file like that?

<?xml version="1.0"?>
<QCARConfig xsi:noNamespaceSchemaLocation="qcar_config.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <Tracking>
        <ImageTarget name="Star_Wars" size="320 256"/>
        <ImageTarget name="Lord_Of_The_Ring" size="320 240"/>
        <Marker type="id-frame" id="0" size="300 300" name="mymarker1" /> 
        <Marker type="id-frame" id="1" size="300 300" name="mymarker2" />
        <Marker type="id-frame" id="2" size="300 300" name="mymarker3" />
    </Tracking>
</QCARConfig>

Have a nice day

Allan

Re: A little question about config.xml

March 30, 2011 - 2:20pm #2

You can't have multiple config.xml files. Instead, include all the image targets and markers your application needs in the single config.xml file (as you showed). All targets and markers will be trackable at runtime.

If you want to disable/enable tracking for a particular trackable type at runtime, you can use the Tracker deactivate and activate methods.

QCAR::Tracker::getInstance().deactivate(QCAR::Tracker::IMAGE_TARGET);
QCAR::Tracker::getInstance().deactivate(QCAR::Tracker::MARKER);

- Kim

Log in or register to post comments