2

I am trying to change the marker of the Image Targets Sample app. I have created the trackable from qualcomm website, i used 2 images and got 2 files in total :-

  1. image.xml
  2. image.dat

i placed both the images in media folder next to stones , chips.jpg and replaced the files in the assets folder of config.xml and qcar-android.dat with the above 2 files But still i am unable to get the application working

Is there anything missing?

4 Answers 4

1

You should change ImageTargets.cpp - define, create and load your own DataSet in loadTrackerData() method.

1
  • there is no loadTrackerData method in ImageTargets.cpp
    – abhishek
    Mar 3, 2012 at 15:59
1

I used this sample app for Image target sample app on iPhone IOS ,

Their exist delegate object top root object that iniates every thing else it add targets to Qcar

enter code here

 [qUtils addTargetName:@"Stones & Chips" atPath:@"StonesAndChips.xml"];
[qUtils addTargetName:@"Tarmac" atPath:@"Tarmac.xml"];

change target name and path according to data set files you created and have in your IDE just map this to android i think

1

In ImageTargets.cpp there's the method

NIEXPORT int JNICALL
Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_loadTrackerData

Here you can see it loads the trackable dataset, and you can make your own changes.

0

In ImageTarget.cpp:

JNIEXPORT int JNICALL
Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_loadTrackerData(JNIEnv *, jobject)
{

...

// Load the data sets:
if (!dataSetStonesAndChips->load("StonesAndChips.xml",QCAR::DataSet::STORAGE_APPRESOURCE))
{
    LOG("Failed to load data set.");
    return 0;
}

...

Just change the "StonesAndChips.xml" to your own file (Image.xml).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.