I have superview to display the ImageView in EAGLview while target detect. It displays the image, then i have a button to hide the image from superview. After hiding imageView i can't display again, So, it won't displaying second time scan the target.
if(!strcmp(trackable.getName(), "Stones")){
dispatch_async(dispatch_get_main_queue(), ^(void) {
if (!annotation1.superview) {
[self addSubview:annotation1];
imgView_depress = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 600, 500)];
imgView_depress.image = [UIImage imageNamed:@"brain.jpg"];
[annotation1 addSubview: imgView_depress];
}
-(void)closeButtonTapped:(id)sender{
[closeButton setHidden:YES];
[imgView_depress setHidden:YES];
}
After closing the button the imageView goes off (hiding), but again scan the imageTarget the imageView not displaying