Start a new topic
Solved

AngularJS and wikitude

Hello everyone,


I'm here because i'm blocked and I wanted to know if anyone had a solution for me.

My problem is: 

Is it possible to share an angular context with the AR world ? If so how can I do that ?


Things I already know:

I know the wikitude plugin is opening a new webview which is completely indepedent of the main app. I saw different project like Ionicitude which use some tricks to do that but I'm not really convince of the reliability of this communication solution.


Why I want to do that:


I'm actually working with meanIO and I need to share in realtime informations between the AR World and the main app without loosing my context. I need to be able to navigate through the app without reloading anything (Cf. SPA)


Thanks for your answers !! :) 

1 Comment

Hi there!


As you mentioned the WebView inside Wikitude's WebView runs in an isolated context.

I assume you're using Angular inside a PhoneGap environment and you like to provide "seamless" navigation between application and AR view.


Unfortunately "context-sharing" is not possible. I recommend you to use Angular (and any UI framework around it) also inside your AR experience. That way at least the UI looks similar.
Aside from you should structure the AR code in a way it can run independently, it should load all of it's content without dependencies to the application code.
If that is not possible at all, you may use the urlListener concept to send messages from AR-View to your application or use "callJavaScript" to pass information to your AR webView (compare References)


Note: Ensure to set background of your Angular view transparent.

A CSS like this may help:


*   

{

    -webkit-highlight: none;

    -webkit-touch-callout : none;

    -webkit-user-select: none;

}


::-webkit-scrollbar {

    display: none;

}


html, body {

    background-color: transparent;

    background-image:none;

    background:rgba(0, 0, 0, 0);

}



Best regards,
Andreas

Login or Signup to post a comment