Log in or register to post comments

Error integrating CloudReco and Image Target

October 18, 2013 - 9:00am #1

Hello..

I am trying to integrate Image Target and Cloud Reco by following steps on:

https://developer.vuforia.com/forum/faq/android-how-integrate-cloudreco-imagetargets-sample

Unfortunately my cygwin show some errors:

jni/ImageTargets.cpp: In member function 'virtual void ImageTargets_UpdateCallback::QCAR_onUpdate(QCAR::State&)':
jni/ImageTargets.cpp:162:22: error: 'state' was not declared in this scope
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargetsRenderer_renderFrame(JNIEnv*, jobject)':
jni/ImageTargets.cpp:456:25: error: 'env' was not declared in this scope
jni/ImageTargets.cpp:456:45: error: 'obj' was not declared in this scope
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_startCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:810:58: error: 'class QCAR::Tracker' has no member named 'getTargetFinder'
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_stopCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:830:54: error: 'class QCAR::Tracker' has no member named 'getTargetFinder'
/cygdrive/c/Users/Sherly/Desktop/Android/android-ndk-r8e/build/core/build-binary.mk:272: recipe for target `obj/local/armeabi/objs-debug/ImageTargets/ImageTargets.o' failed
make: *** [obj/local/armeabi/objs-debug/ImageTargets/ImageTargets.o] Error 1
 
Can anybody please help me and tell me what did I do wrong?
Thank you so much ...

Error integrating CloudReco and Image Target

July 15, 2014 - 5:10am #10

The error error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker' is saying that the compiler cannot find the IMAGE_TRACKER enum / constant (which belongs to Vuforia 2.0 API).

So, it looks like you are trying to port some existing code from one version of Vuforia to another; you will need to make sure that you are using the correct API for your Vuforia SDK version (current 3.0).

See the migration guide:

https://developer.vuforia.com/resources/dev-guide/transitionmigration-guide

Also, if you are coding in C++, one thing that could help is to have a look at the ImageTargetsNative-3-0-5 sample, so that you can easily compare your code syntax with the sample one and spot possible differences.

 

Error integrating CloudReco and Image Target

July 15, 2014 - 1:39am #9

Hello AlessandroB,

I don't know what is the problem but my all .cpp files showing error . when i am running this app is shows the earlier error. 

i am assuming that this error is due to the vuforia path ( windows).

Error integrating CloudReco and Image Target

July 15, 2014 - 1:16am #8

Are you using the latest Vuforia ? If so, (since this thread is really old), you might need to adjust the API you are using;

in particular, your error messages indicate that you are using the enum IMAGE_TRACKER, which is no longer supported in the 2.8 and 3.0 API;

so, to get the ImageTracker, use this code:

QCAR::ImageTracker *tracker = static_cast<QCAR::ImageTracker*>(

       QCAR::TrackerManager::getInstance().getTracker(QCAR::ImageTracker::getClassType()) );

 

Error integrating CloudReco and Image Target

July 15, 2014 - 1:05am #7

I am developing an android ndk application using vuforia .

whenever i run this app CDT console shows following error.

[armeabi] Compile++ arm  : ImageTargets <= ImageTargets.cpp
jni/ImageTargets.cpp: In member function 'virtual void ImageTargets_UpdateCallback::QCAR_onUpdate(QCAR::State&)':
jni/ImageTargets.cpp:109:8: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'int Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_initTracker(JNIEnv*, jobject)':
jni/ImageTargets.cpp:166:4: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_deinitTracker(JNIEnv*, jobject)':
jni/ImageTargets.cpp:184:31: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'int Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_loadTrackerData(JNIEnv*, jobject)':
jni/ImageTargets.cpp:197:6: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'int Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_destroyTrackerData(JNIEnv*, jobject)':
jni/ImageTargets.cpp:269:6: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_startCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:796:4: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_stopCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:809:4: error: 'IMAGE_TRACKER' is not a member of 'QCAR::Tracker'
make.exe: *** [obj/local/armeabi/objs/ImageTargets/ImageTargets.o] Error 1
 
please suggest how to solve this .

Error integrating CloudReco and Image Target

February 8, 2014 - 7:20am #6

Glad to be helpful :-)

Error integrating CloudReco and Image Target

February 7, 2014 - 4:24pm #5

AlessandroB I had the same problem and you have just saved me.It really works.Now when an image is recognised a toast message is displayed with the name of every single image I have saved in my phone.Thank you so much...!!

Error integrating CloudReco and Image Target

October 18, 2013 - 12:22pm #4

You need to replace

Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargetsRenderer_renderFrame(JNIEnv*, jobject)':
 
with
Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargetsRenderer_renderFrame(JNIEnv* env, jobject obj)':
 

Also, you need to replace:

QCAR::TrackerManager& trackerManager = QCAR::TrackerManager::getInstance();
QCAR::Tracker* tracker = trackerManager.getTracker(QCAR::Tracker::IMAGE_TRACKER);
    

with:

QCAR::TrackerManager& trackerManager = QCAR::TrackerManager::getInstance();
QCAR::ImageTracker* imageTracker = static_cast<QCAR::ImageTracker*>(
        trackerManager.getTracker(QCAR::Tracker::IMAGE_TRACKER));
    
and add the include statement:
 
#include <QCAR\ImageTracker.h>
 
 

 

Error integrating CloudReco and Image Target

October 18, 2013 - 9:21am #3

Thank you for the quick answer.. 

But i'm still dealing with this one.. 

Confused about what to add or change.. could you help me please?

jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargetsRenderer_renderFrame(JNIEnv*, jobject)':
jni/ImageTargets.cpp:455:25: error: 'env' was not declared in this scope
jni/ImageTargets.cpp:455:45: error: 'obj' was not declared in this scope
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_startCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:809:58: error: 'class QCAR::Tracker' has no member named 'getTargetFinder'
jni/ImageTargets.cpp: In function 'void Java_com_qualcomm_QCARSamples_ImageTargets_ImageTargets_stopCamera(JNIEnv*, jobject)':
jni/ImageTargets.cpp:829:54: error: 'class QCAR::Tracker' has no member named 'getTargetFinder'
 

Error integrating CloudReco and Image Target

October 18, 2013 - 9:09am #2

You need to explicitly add the function arguments, for example in:

QCAR_onUpdate(QCAR::State&)

you need to add 'state' so that it becomes:

QCAR_onUpdate(QCAR::State& state)

and so on. These are just small C++ details that you can fix easily.

 

Log in or register to post comments