Ramesh India
Ramesh India

Reputation: 107

Augmented reality in iphone using wikitude

I am using wikitude API for augmented reality in my iPhone app. But I got stuck in implementing that in my application.

I am having one button in my one View on clicking of which I want to open the Wikitude AR view but I am not able to add it over that view. As in Sample application provided by Wikitude this wikitudeAR view is added over the Main window but in my application I want to add the view([wikitudeAR Start]) over my view like(self.view addSubview:[wikitudeAR Start]) which is not working. Please suggest me.

Thanks in advance

Upvotes: 0

Views: 414

Answers (2)

Claudio Uribe Solar
Claudio Uribe Solar

Reputation: 31

You must add the Wikitude View as a subView of the key Window. Then, you can show or hide it using the "show" and "hide" methods.

The code is:

- (void) verificationDidSucceed {
    [[[UIApplication sharedApplication] keyWindow] addSubview:[wikitudeAR start]];
}

Upvotes: 1

Birdkingz
Birdkingz

Reputation: 119

This might solve your problem

after you have added wikitude to the subview, call the following method

[wikitudeAR show];

Upvotes: 1

Related Questions