-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
61 lines (49 loc) · 2.2 KB
/
index.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
54
55
56
57
58
59
60
61
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>AR Tiles Placement</title>
<script src="//cdn.8thwall.com/web/aframe/8frame-1.3.0.min.js"></script>
<script src="//cdn.8thwall.com/web/xrextras/xrextras.js"></script>
<script src="//cdn.8thwall.com/web/landing-page/landing-page.js"></script>
<script src="//apps.8thwall.com/xrweb?appKey=gJa5sHYSlcyhg4hOX5FfmoLPmFETu2xfGT5kBFr59jdBcfV9R1rInxXvJt3NjO9pUgIpYU"
async></script>
</head>
<body>
<a-scene xrextras-gesture-detector landing-page xrextras-loading xrextras-runtime-error
renderer="colorManagement: true" xrweb>
<a-assets>
<img id="texture" src="./a.webp">
<a-asset-item id="tile-transparent" src="./Transparent02.glb"></a-asset-item>
</a-assets>
<!-- The raycaster will emit mouse events on scene objects specified with the cantap class -->
<a-camera id="camera" position="0 8 0" cursor="fuse: false; rayOrigin: mouse;">
</a-camera>
<a-entity id="cursor" tap-place-cursor gltf-model="#tile-transparent" scale="1 1 1" reflections="type: static"
rotation="0 45 0">
</a-entity>
<a-entity light="
type: directional;
intensity: 0.8;
castShadow: true;
shadowMapHeight:2048;
shadowMapWidth:2048;
shadowCameraTop: 20;
shadowCameraBottom: -20;
shadowCameraRight: 20;
shadowCameraLeft: -20;
target: #model" xrextras-attach="target: model; offset: 8 15 4" position="1 4.3 2.5">
</a-entity>
<a-light type="ambient" intensity="0.5"></a-light>
<a-box id="model" scale="10 0.1 10" visible="false" shadow="receive: false" xrextras-hold-drag
xrextras-two-finger-rotate xrextras-pinch-scale reflections="type: realtime" rotation="0 0 0"
position="0 0 0" material="src: #texture">
</a-box>
<a-box id="ground" scale="1000 2 1000" position="0 -1 0"
material="shader: shadow; transparent: true; opacity: 0.4" shadow>
</a-box>
</a-scene>
<script src="./tap-place-cursor.js"></script>
</body>
</html>