-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
executable file
·68 lines (68 loc) · 5.5 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
62
63
64
65
66
67
68
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<meta name="viewport" id="viewport" content="width=device-width, initial-scale=1">
<meta name="description" id="description" content="" />
<meta name="keywords" id="keywords" content="" />
<meta name="language" id="language" content="en-us" />
<title>Gyroscope working</title>
<link rel="author" href="Joseph Stephen">
<script type="text/javascript" src="jquery.min.js"></script>
<script type="text/javascript" src="three.min.js"></script>
<link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
<style type="text/css">
html, body {margin: 0; padding: 0; background: #111; font-family: 'Open Sans', sans-serif; font-size: 14px; }
#canvas, canvas {display: block; margin: 0 auto; touch-action: none; }
#canvas:focus {outline: none; }
.form {position: fixed; left: 0; top: 0; bottom: 0; max-width: 100%; height: 100%; overflow: visible; }
.form-control {margin-bottom: 0.5em; }
.form .box {background-color: white; padding: 1em 1em 0.5em 1em; overflow: auto; max-width: 100%; max-height: 100%; box-sizing: border-box; }
.form.hidden .box {display: none; }
.form .button {position: absolute; left: 100%; top: 1em; background-color: white; padding: 10px 6px; cursor: pointer; }
.form.hidden .button {position: fixed; left: 0; top: 1em; background-color: white; padding: 10px 6px; }
.form .button .arrow {width: 0; height: 0; border-top: 10px solid transparent; border-bottom: 10px solid transparent; border-left: none; border-right:10px solid black; }
.form.hidden .button .arrow {width: 0; height: 0; border-top: 10px solid transparent; border-bottom: 10px solid transparent; border-left:10px solid black; border-right: none; }
</style>
</head>
<body>
<div id="canvas"></div>
<div id="form" class="form">
<div class="button" id="button"><div class="arrow"></div></div>
<div class="box">
<div class="form-control"><input type="checkbox" name="msingle" id="msingle" /><label for="msingle"> Single</label></div>
<div class="form-control"><input type="checkbox" name="mpause" id="mpause" /><label for="mpause"> Pause simulation</label></div>
<div class="form-control"><input type="checkbox" name="malpha" id="malpha" checked="true" /><label for="malpha"> See through</label></div>
<hr>
<div class="form-control">Linear Acceleration/Force</div>
<div class="form-control"><input type="checkbox" name="fgravity" id="fgravity" /><label for="fgravity"> Gravity</label></div>
<div class="form-control"><input type="checkbox" name="frotational" id="frotational" /><label for="frotational"> Rotational</label></div>
<div class="form-control"><input type="checkbox" name="ftorque" id="ftorque" checked="true" /><label for="ftorque"> Torque due to gravity</label></div>
<div class="form-control"><input type="checkbox" name="ftorquevertical" id="ftorquevertical" /><label for="ftorquevertical"> Torque due to gravity (Vertical)</label></div>
<div class="form-control"><input type="checkbox" name="ftorquehorizontal" id="ftorquehorizontal" /><label for="ftorquehorizontal"> Torque due to gravity (Horizontal)</label></div>
<div class="form-control"><input type="checkbox" name="ftorquereference" id="ftorquereference" /><label for="ftorquereference"> Torque reference helpers</label></div>
<hr>
<div class="form-control">Linear Velocty/Momentum </div>
<div class="form-control"><input type="checkbox" name="mrotational" id="mrotational" /><label for="mrotational"> Rotational</label></div>
<div class="form-control"><input type="checkbox" name="mprecession" id="mprecession" checked="true" /><label for="mprecession"> Precession</label></div>
<hr>
<div class="form-control">Simulation speed </div>
<div class="form-control"><input type="radio" name="sspeed" id="sspeed1" value="1" checked="true" /><label for="sspeed1"> x</label></div>
<div class="form-control"><input type="radio" name="sspeed" id="sspeed2" value="2" /><label for="sspeed2"> x/2</label></div>
<div class="form-control"><input type="radio" name="sspeed" id="sspeed3" value="4" /><label for="sspeed3"> x/4</label></div>
<div class="form-control"><input type="radio" name="sspeed" id="sspeed4" value="8" /><label for="sspeed4"> x/8</label></div>
<hr>
<div class="form-control">Tilt </div>
<div class="form-control"><input type="radio" name="snutation" id="snutation0" value="0" checked="true" /><label for="snutation0"> 0°</label></div>
<div class="form-control"><input type="radio" name="snutation" id="snutation10" value="10" /><label for="snutation10"> 10°</label></div>
<div class="form-control"><input type="radio" name="snutation" id="snutation20" value="20" /><label for="snutation20"> 20°</label></div>
<div class="form-control"><input type="radio" name="snutation" id="snutation30" value="30" /><label for="snutation30"> 30°</label></div>
<div class="form-control"><input type="radio" name="snutation" id="snutation40" value="40" /><label for="snutation40"> 40°</label></div>
<div class="form-control"><input type="radio" name="snutation" id="snutation50" value="50" /><label for="snutation50"> 50°</label></div>
<hr>
<div class="form-control" style="max-width: 200px;">This simulator is my understanding of the gyroscope. Neither the input measurments nor the resultants are valid and can not be used for any applications. <br/><a href="https://github.com/pronuba66/Gyroscope">Source</a>. </div>
</div>
</div>
<script type="text/javascript" src="build/gyro.min.js"></script>
</body>
</html>