Log in or register to post comments

Replacing the stones or chips image in Image Target app

August 25, 2011 - 12:20am #8

I need to replace the stones or chips image in config.xml in Image Target App (QCAR sdk) by some other image. Will the server maps the image or simply can we replace some other image by creating our own xml file?

Help!

Re: Replacing the stones or chips image in Image Target app

August 25, 2011 - 12:32am #7

[QUOTE=AugmentedReality" />I need to replace the stones or chips image in config.xml in Image Target App (QCAR sdk) by some other image. Will the server maps the image or simply can we replace some other image by creating our own xml file?[/QUOTE" />

Hi AugmentedReality,

You'll need to use the online service to create a new trackable, that you can download and use to replace or append your existing resources.

See the "MY TRACKABLES" tab on Qualcomm DevNet for Augmented Reality

Re: Replacing the stones or chips image in Image Target app

August 25, 2011 - 3:05am #6

Thank yo so much... It was very helpful....

Re: Replacing the stones or chips image in Image Target app

January 20, 2012 - 4:06am #5

Hello AugmentedReality & MoSR,

Did you succedd replacing those images with new trackable? I created a new one, replaced the project with new target resources, and replaced EAGLView:renderFrameQCAR "stones" string.... but does not work... any other clue?

Would be great a tutorial to create apps from the scratch... it completes examples when you are new in a certain SDK

Thank you!!

Re: Replacing the stones or chips image in Image Target app

January 20, 2012 - 6:40am #4

Hi smayo, assuming you're using SDK 1.0 in a native iOS project then it's as easy as you've suggested:

1) Create a new trackable data set using the web service (make sure you get a good score on your image)

2) Replace the dataset in your Xcode project with the new config.xml and qcar-resource.dat

3) In the loop inside renderFrameQCAR, match the target against the detected target either by name, or by knowing its the only one.

"but does not work" covers a huge spectrum of possibilities. Providing the console log, or seeing if the renderFrameQCAR loop is ever executed and whether state.getNumActiveTrackables is ever non-zero, or printing to the log what the detected target name is - these would be the logical steps to take next.

Re: Replacing the stones or chips image in Image Target app

January 23, 2012 - 2:54am #3

Thank you MoSR, and sorry for my vague post, you're right. I try to explain further my problem here:

I use SDK 1.0 and native iOS project (actually, I am modifying ImageTargets as a first attempt to learn QCAR SDK).

I followed the steps you posted: I created a 5 stars trackable image, replaced config.xml and qcar_resource.dat with new ones, and changed the name of the file in the loop of renderFrameQCAR:

// Choose the texture based on the target name
int textureIndex = (!strcmp(trackable->getName(), "trackable_test1")) ? 0 : 1;

When I exec the app, it enters the loop (renderFrameQCAR) but state.getNumActiveTrackables is always 0... I checked the console but no clue with the messages before showing that state.getNumActiveTrackables is 0:

Mon Jan 23 11:50:58 ITA-iPhone-3GS-1 kernel[0] : punchd[302] Builtin profile: container (sandbox)
Mon Jan 23 11:50:58 ITA-iPhone-3GS-1 kernel[0] : punchd[302] Container: /private/var/mobile/Applications/23D5996F-5EB4-446E-BC34-E72067A2B34E [69] (sandbox)
Mon Jan 23 11:50:58 ITA-iPhone-3GS-1 ImageTargets[302] : QCAR OpenGL flag: 2
Mon Jan 23 11:50:59 ITA-iPhone-3GS-1 ImageTargets[302] : EAGLView onCreate()
Mon Jan 23 11:50:59 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: QCAR SDK version 1.0.0
Mon Jan 23 11:50:59 ITA-iPhone-3GS-1 ImageTargets[302] : EAGLView onResume()
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 securityd[303] : ImageTargets[302] SecItemDelete: missing entitlement
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 securityd[303] : ImageTargets[302] SecItemAdd: missing entitlement
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 ImageTargets[302] : QCAR::init percent: 100
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: Tracker starts loading
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: Found config.xml
Mon Jan 23 11:51:01 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: Found config.xml
Mon Jan 23 11:51:01 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: Tracker finished loading (no errors)
Mon Jan 23 11:51:01 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: UIView has CAEAGLLayer class
Mon Jan 23 11:51:01 ITA-iPhone-3GS-1 ImageTargets[302] : INFO: UIView conforms to UIGLViewProtocol
Mon Jan 23 11:51:02 ITA-iPhone-3GS-1 ImageTargets[302] : CameraImpl: setting torch mode 0 is not supported

Thank you again, and sorry for these newbie's questions

Re: Replacing the stones or chips image in Image Target app

January 23, 2012 - 3:05am #2

Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 securityd[303] : ImageTargets[302] SecItemDelete: missing entitlement
Mon Jan 23 11:51:00 ITA-iPhone-3GS-1 securityd[303] : ImageTargets[302] SecItemAdd: missing entitlement

I've seen these two lines before and I believe it's when the device is jailbroken. Unfortunately we can't offer a solution to this at the time. Please retry with a non-jailbroken device.

If I'm wrong in my diagnosis please let me know.

Re: Replacing the stones or chips image in Image Target app

January 23, 2012 - 3:30am #1

Hello MoSR,

Yes, you're absolutely right, I am testing with a jailbroken iPhone... so I guess this is may be a problem even in this very early testing SDK phase...I mean: I know I must use a non-jailbroken iPhone for dev&test&distribute my apps (I am used, already done it in the past with other iOS developments), but now I am just testing QCAR capabilities and, mainly, SDK ease-of-use to decide to adopt or not in the near future.

Thanks a lot for your quick and proper feedback

Log in or register to post comments