-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathARjsTest.html
19 lines (18 loc) · 892 Bytes
/
ARjsTest.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<html>
<head>
<!--Importing aframe, three.js, and ar.js -->
<script src="https://aframe.io/releases/0.5.0/aframe.min.js"></script>
<script src="https://rawgit.com/jeromeetienne/ar.js/master/aframe/build/aframe-ar.js"></script>
<script>THREEx.ArToolkitContext.baseURL = 'https://rawgit.com/jeromeetienne/ar.js/master/three.js'</script>
</head>
<body style='margin: 0px; overflow: hidden;'>
<!--Declares a-frame scene-->
<!--Using ARToolKit to access phone camera-->
<a-scene embedded artoolkit='sourceType: webcam;'>
<!--This is where we add elements for our scene-->
<a-box position='0 0.5 0' material='opacity: 0.5;'></a-box>
<!--Camera looks for default marker and moves with phone-->
<a-marker-camera preset='hiro'></a-marker-camera>
</a-scene>
</body>
</html>