-
Notifications
You must be signed in to change notification settings - Fork 13
/
va3c-viewer-html5-r2.html
83 lines (71 loc) · 2.49 KB
/
va3c-viewer-html5-r2.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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<!doctype html>
<html lang=en >
<head>
<title>vA3C Viewer R2 HTML5</title>
<meta charset=utf-8 />
<meta name=viewport content=width=device-width,user-scalable=no,minimum-scale=1.0,maximum-scale=1.0 />
<link rel=stylesheet href=http://netdna.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.css />
</head>
<body>
<script src=assets/three.min.js ></script>
<script src=assets/OrbitControls.js ></script>
<script src=assets/stats.min.js ></script>
<script src=assets/ColladaLoader.js ></script>
<script src=assets/va3c-viewer-v3aa.js ></script>
<script src=assets/va3c-viewer-v3at.js ></script>
<script src=assets/va3c-viewer-v3cc.js ></script>
<script src=assets/va3c-viewer-v3pl.js ></script>
<script src=assets/va3c-viewer-v3fo.js ></script>
<script src=assets/va3c-viewer-v3bu.js ></script>
<script src=assets/va3c-viewer-v3su.js ></script>
<script src=assets/first-person-controls-theo.js ></script>
<script src=assets/sun-position.js ></script>
<script>
// Theo Armour ~ 2014-05-27 ~ MIT License
// every name space used below relates to a JavaScript file with the same name suffix
var fname = '../../../json/Hex_01.js';
var targetList;
var clock = new THREE.Clock();
init();
animate();
function init() {
container = document.body.appendChild( document.createElement( 'div' ) );
V3AA.addCSS();
V3AA.addHeader();
V3AA.addMenu();
V3PL.parsePermalink();
V3FO.addFileOpen();
V3AA.addThreeJS();
V3PL.addPermalinks();
V3BU.addBundleOpen();
V3CC.addCameraControls();
V3AT.addAttributes();
V3SU.addSunlight();
V3AA.addAbout();
V3AA.addFooter();
// if a permalink is found use it, otherwise load the default
if ( V3PL.url ) {
V3FO.loadURL( V3PL.url );
} else {
V3FO.loadFile( fname );
}
document.addEventListener( 'mousemove', onDocumentMouseMove, false );
document.addEventListener( 'click', onDocumentMouseClick, false );
window.addEventListener('mouseup', mouseUp, false);
}
function animate() {
requestAnimationFrame( animate );
renderer.render( scene, camera );
controls.update( clock.getDelta() );
stats.update();
if ( !controls.heightSpeed ) return;
msg.innerHTML = 'Debug:<br>' +
'Freeze: ' + controls.freeze + '<br>' +
'lookSpeed: ' + controls.lookSpeed.toFixed(3) + ' movementSpeed: ' + controls.movementSpeed + '<br>' +
'lon ' + controls.lon.toFixed(3) + ' lat ' + controls.lat.toFixed(3) + '<br>' +0
'movementSpeed ' + controls.movementSpeed + ' actualMoveSpeed ' + actualMoveSpeed.toFixed(2) + '<br>' +
'';
}
</script>
</body>
</html>