-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathar.html
53 lines (44 loc) · 2.37 KB
/
ar.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<!-- AR.js by @jerome_etienne - github: https://github.com/jeromeetienne/ar.js - info: https://medium.com/arjs/augmented-reality-in-10-lines-of-html-4e193ea9fdbf -->
<script src="https://cdn.rawgit.com/jeromeetienne/AR.js/1.5.0/aframe/examples/vendor/aframe/build/aframe.min.js"></script>
<script src="https://cdn.rawgit.com/jeromeetienne/AR.js/1.5.0/aframe/build/aframe-ar.js"></script>
<script src="https://unpkg.com/aframe-text-geometry-component@^0.5.0/dist/aframe-text-geometry-component.min.js"></script>
<body style='margin : 0px; overflow: hidden;'>
<!--a-scene-- embedded arjs='trackingMethod: best;'>
<a-assets>
<a-asset-item id="optimerBoldFont" src="https://rawgit.com/mrdoob/three.js/dev/examples/fonts/optimer_bold.typeface.json"></a-asset-item>
</a-assets>
<a-anchor hit-testing-enabled='true'>
<a-entity rotation="-90 0 0" text-geometry="value: SAMO; font: #optimerBoldFont; color: white; anchor: center; align: center;">
<a-animation attribute="rotation" to="-90 0 360" dur="3000" easing='linear' repeat="indefinite"></a-animation>
</a-entity>
</a-anchor>
<a-camera-static/>
</a-scene-->
<!-- enable artoolkit on this scene -->
<a-scene embedded arjs='sourceType: webcam; detectionMode: mono_and_matrix; matrixCodeType: 3x3;'>
<!-- handle unknown marker -->
<!-- <a-marker type='unknown'>
<a-box depth="1" height="1" width="1" position='0 0.5 0' material='opacity: 0.5; side:double; color:blue;'></a-box>
</a-marker> -->
<!-- handle hiro marker -->
<a-marker preset='hiro'>
<a-box src="https://abesk.github.io/lids.png">
<a-animation attribute="rotation" to="-90 0 360" dur="3000" easing='linear' repeat="indefinite"></a-animation>
</a-box>
</a-marker>
<!-- handle hiro marker -->
<a-marker type='barcode' barcodeValue='5'>
<a-box src="https://abesk.github.io/lids.png">
<a-animation attribute="rotation" to="-90 0 360" dur="3000" easing='linear' repeat="indefinite"></a-animation>
</a-box>
</a-marker>
<!-- handle kanji marker -->
<a-marker preset='kanji'>
<a-box src="https://abesk.github.io/lids.png">
<a-animation attribute="rotation" to="-90 0 360" dur="3000" easing='linear' repeat="indefinite"></a-animation>
</a-box>
</a-marker>
<!-- add a simple camera -->
<a-entity camera></a-entity>
</a-scene>
</body>