Skip to content

Instantly share code, notes, and snippets.

@nicolocarpignoli
Created September 13, 2019 12:42
Show Gist options
  • Select an option

  • Save nicolocarpignoli/009dfa6b590bed761344d30dfeeabb05 to your computer and use it in GitHub Desktop.

Select an option

Save nicolocarpignoli/009dfa6b590bed761344d30dfeeabb05 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<meta http-equiv='X-UA-Compatible' content='IE=edge'>
<title>GeoAR.js demo</title>
<!-- import aframe and AR.js -->
<script src='https://aframe.io/releases/0.9.2/aframe.min.js'></script>
<script src='https://raw.githack.com/jeromeetienne/AR.js/master/aframe/build/aframe-ar.min.js'></script>
<script>
THREEx.ArToolkitContext.baseURL = 'https://raw.githack.com/jeromeetienne/ar.js/master/three.js/'
</script>
</head>
<!-- include GeoAR.js -->
<script src="../../src/gps-entity-place.js"></script>
<script src="../../src/gps-camera-debug.js"></script>
<script src="../../src/gps-camera.js"></script>
<link rel="stylesheet" href="../../src/stylesheets/index.css">
<!-- Dynamically add places from Javascript -->
<script src="./places.js"></script>
<body style='margin: 0; overflow: hidden;'>
<a-scene
cursor='rayOrigin: mouse; fuse: true; fuseTimeout: 0;'
raycaster="objects: [gps-entity-place];"
vr-mode-ui="enabled: false"
embedded
arjs='sourceType: webcam; sourceWidth:1280; sourceHeight:960; displayWidth: 1280; displayHeight: 960; debugUIEnabled: false;'>
<a-camera gps-camera="minDistance: 20;" rotation-reader>
</a-camera>
</a-scene>
</body>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment