Well I Read Ksiva's post....
It stated how to change texture on tapping the screen...
Wel i hav in ImageTarget.cpp file----multiple targets loaded....
i.e I hav loaded mytaget1 with targetIndex= 0 as well as targetIndex=1
second mytarget2 with targetIndex=2...
I hav added in Imagetarget.java the following code
public boolean onTouchEvent(MotionEvent event)
if (event.getAction() == MotionEvent.ACTION_UP )
Texture temp = mTextures.elementAt(0);
// Run initRendering on the GL Thread
public void run()
Well what happens is the target is displayed wel for both mytarget1 and mytarget2....It even swaps well and changes the texture for mytarget1 on tapping the screen...
However when the mytarget2 is tracked the texture is displayed well but on tapping multiple times in short duration on mytarget2 the application closes!!!
(IT WORKS WELL IF I TAP MYTARGET2 AFTER SOME SECONDS...)
I taught it would work well as even if i tap on other target it would just swap the position of mTexture 0 and mtexture 1...
The logcat also shows the log for swapping texture ...init deinitapplication native... AND NO ERROR IS DISPLAYED!!!