Start a new topic

Wikitude-Phonegap and google maps

Wikitude-Phonegap and google maps

1 person has this problem
1 Comment


Greetings,

What might cause this error?

Test case (index.html):

Rest of the codes are exactly same as in hello world example.


<!DOCTYPE HTML>

<html>

<head>

<style>

      html, body {

        margin: 0;

        padding: 0;

        height: 100%;

overflow:hidden;

      }

       #mapcanvas{

 left:0px;

 top:0px;

 margin: 0;

        padding: 0;

        height: 100%;

width:100%;

float:left;

overflow:hidden;

 }

 #ARbutton{

 position:fixed;right:30px;bottom:30px;

 

 }

</style>

<script src="cordova.js"></script>

<script src="scripts/WikitudePlugin.js"></script>

<script src="scripts/indexAr.js"></script>

<script src="https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false"></script>

<script src="http://code.jquery.com/jquery-1.10.1.min.js"></script>

</head>

<body>

<div id="mapcanvas"></div>

<button id="ARbutton" onclick="loadAR()">ar</button>

 

<script>

//AR scripts

app.initialize();

 

                function loadAR(){

                document.removeEventListener("backbutton", WikitudePlugin.onBackButton, false);

                document.addEventListener("backbutton", WikitudePlugin.onBackButton, false);

WikitudePlugin.loadARchitectWorld("assets/world/4_ObtainPoiData_1_FromWebservice/index.html");

                }

//AR scripts-

var map;

function initialize() {

  var mapOptions = {

    zoom: 8,

    center: new google.maps.LatLng(-34.397, 150.644),

    mapTypeId: google.maps.MapTypeId.ROADMAP

  };

  map = new google.maps.Map(document.getElementById('mapcanvas'),

      mapOptions);

}

google.maps.event.addDomListener(window, 'load', initialize);

</script>

</body>

</html>

 

Errors I am getting after pressing to AR button:


07-31 16:58:50.166: E/SensorManager(28640): thread start

07-31 16:58:50.336: E/libEGL(28640): called unimplemented OpenGL ES API

07-31 16:58:50.336: E/libEGL(28640): called unimplemented OpenGL ES API

07-31 16:58:51.641: E/Web Console(28640): Uncaught ReferenceError: AR is not defined:1

 

Errors I am getting after pressing back button:


07-31 17:01:08.926: E/libEGL(28640): call to OpenGL ES API with no current context (logged once per thread)

 

and something breaks Google Maps javascript api v3.1. 

 

Mobile machine: Samsung galaxy S4 GT-I9500 Android 4.2.2




Project attached as file
Login or Signup to post a comment