Thu, 06 Apr 2017 15:03:40 +0200
added dependencies to local repo
8 | 1 | <!DOCTYPE html> |
2 | <html lang="en"><head> | |
3 | <meta http-equiv="content-type" content="text/html; charset=UTF-8"> | |
4 | <title>ScubaTools Object Viewer</title> | |
5 | <meta charset="utf-8"> | |
6 | <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"> | |
7 | ||
16 | 8 | <link rel="stylesheet" href="js/jquery-ui.css" /> |
11 | 9 | <link rel="stylesheet" href="stlviewer.css" /> |
16 | 10 | <script src="js/jquery-1.12.4.min.js"></script> |
11 | <script src="js/jquery-ui.min.js"></script> | |
8 | 12 | |
16 | 13 | <script src="js/three.min.js"></script> |
14 | <script src="js/Detector.js"></script> | |
15 | <script src="js/STLLoader.js"></script> | |
16 | <script src="js/OrbitControls.js"></script> | |
8 | 17 | |
18 | </head> | |
19 | <body> | |
20 | <div id="info"> | |
11 | 21 | <div class="listcontainer"> |
22 | <h2>Available:</h2> | |
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
23 | move to selected |
11 | 24 | <ul id="sortable1"> |
25 | <!-- PLACEHOLDER CYLINDERS --> | |
26 | </ul> | |
27 | </div> | |
28 | <div class="listcontainer"> | |
29 | <h2>Selected:</h2> | |
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
30 | <a href="#" id="clearselected">clear list</a> |
11 | 31 | <ul id="sortable2"> |
32 | ||
33 | </ul> | |
34 | </div> | |
35 | ||
8 | 36 | <a href="https://neo-soft.org" target="_blank">NeoSoft</a> ScubaTools - |
37 | <a href="https://threejs.org/" target="_blank">three.js</a> - | |
38 | STL loader by <a href="https://github.com/aleeper" target="_blank">aleeper</a>. | |
39 | <br/> | |
40 | Left mouse: rotate camera, right mouse: move camera, middle mouse or wheel: zoom | |
11 | 41 | |
42 | ||
8 | 43 | </div> |
44 | ||
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
45 | <div id="rendercontainer"></div> |
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
46 | |
11 | 47 | <script src="stlviewer.js"></script> |
48 | ||
8 | 49 | <script> |
12 | 50 | if ( ! Detector.webgl ) Detector.addGetWebGLMessage(); |
8 | 51 | var container; |
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
52 | var controls; |
8 | 53 | var camera, cameraTarget, scene, renderer; |
12 | 54 | var m_spacer = new THREE.MeshPhongMaterial( { |
55 | color: 0x736f6e, specular: 0x111111, shininess: 100 } ); | |
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
56 | |
12 | 57 | var m_cylinder = new THREE.MeshPhongMaterial( { |
58 | color: 0x4682b4, specular: 0x111111, shininess: 200 } ); | |
13
39fb313ba27c
finished viewer again, giving up with texturing mesh without uv mapping
mdd
parents:
12
diff
changeset
|
59 | |
12 | 60 | init(); |
8 | 61 | animate(); |
62 | ||
14 | 63 | </script> |
8 | 64 | |
65 | ||
66 | </body></html> |