forked from toddtreece/union-bridge-drums
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
418 lines (348 loc) · 14.9 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Union Bridge Drum Co</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Union Bridge Drum Co. Custom Drums">
<meta name="keywords" content="stave, drum, snare, union, bridge, custom, calculator, todd, treece">
<meta name="author" content="Todd Treece">
<link rel="Shortcut Icon" href="/favicon.ico" type="image/x-icon" >
<!-- HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<link href="css/spacelab.min.css" rel="stylesheet">
<link href="css/bootstrap-responsive.css" rel="stylesheet">
<link href="css/stave.css" rel="stylesheet">
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container-fluid">
<a class="brand" href="http://unionbridgedrums.com">Union Bridge Drum Co</a>
</div>
</div>
</div>
<div class="container-fluid" style="margin-top:50px;">
<div class="row-fluid">
<div class="span4">
<form class="form well" id="staveform">
<fieldset>
<legend>Stave Calculator</legend>
<div class="row-fluid">
<div class="span6">
<div class="control-group">
<label class="control-label" for="stave_count">Unit</label>
<div class="controls">
<select class="input-small" name="unit">
<option data-display=""" value="in">in</option>
<option data-display="cm" value="cm">cm</option>
</select>
</div>
</div>
<div class="control-group">
<label class="control-label" for="stave_count">Number of Segments</label>
<div class="controls">
<input type="number"
class="input-small"
min="6"
max="40"
name="stave_count"
placeholder="20"
value="20"
data-precision="0"
required>
</div>
</div>
<div class="control-group">
<label class="control-label" for="shell_diameter">Shell Diameter</label>
<div class="controls">
<div class="input-append">
<input type="text"
pattern="\d+(\.\d{0,2})?"
class="input-small info"
name="shell_diameter"
placeholder="14"
value="14"
data-unit="in"
data-precision="2"
data-toggle="popover"
data-placement="top"
data-content="Enter the common drum shell diameter.<br><br><em>i.e. 14"</em>"
data-original-title="Shell Diameter"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="extra">Extra Diameter</label>
<div class="controls">
<div class="input-prepend">
<input type="text"
pattern="\d+(\.\d{0,4})?"
class="unit input-small info"
name="extra"
placeholder="0.125"
value="0.125"
data-unit="in"
data-precision="4"
data-toggle="popover"
data-placement="top"
data-content="Adds to the rough diameter to allow for shells that don't start perfectly round."
data-original-title="Extra Diameter"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="shell_depth">Shell Depth</label>
<div class="controls">
<div class="input-append">
<input type="text"
pattern="\d+(\.\d{0,2})?"
class="unit input-small"
name="shell_depth"
placeholder="5.5"
value="5.5"
data-unit="in"
data-precision="2"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
</div>
<div class="span6">
<div class="control-group">
<label class="control-label" for="board_thickness">Measured Thickness</label>
<div class="controls">
<div class="input-append">
<input type="text"
pattern="\d+(\.\d{0,4})?"
class="unit input-small"
name="board_thickness"
placeholder="0.750"
value="0.750"
data-unit="in"
data-precision="4"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="board_width">Board Width</label>
<div class="controls">
<div class="input-append">
<input type="text"
pattern="\d+(\.\d{0,3})?"
class="unit input-small"
name="board_width"
placeholder="5.00"
value="5.00"
data-unit="in"
data-precision="3"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="board_cost">Cost per Board Foot</label>
<div class="controls">
<div class="input-prepend">
<span class="add-on">$</span><input
type="text"
pattern="\d+(\.\d{0,2})?"
class="input-small"
name="board_cost"
placeholder="11.00"
value="11.00"
data-precision="2"
required>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="crosscut_kerf">Crosscut Kerf</label>
<div class="controls">
<div class="input-prepend">
<input type="text"
pattern="\d+(\.\d{0,5})?"
class="unit input-small"
name="crosscut_kerf"
placeholder="0.09375"
value="0.09375"
data-unit="in"
data-precision="5"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="rip_kerf">Rip Kerf</label>
<div class="controls">
<div class="input-append">
<input type="text"
pattern="\d+(\.\d{0,5})?"
class="unit input-small"
name="rip_kerf"
placeholder="0.09375"
value="0.09375"
data-unit="in"
data-precision="5"
required><span class="unit add-on">in</span>
</div>
</div>
</div>
<div class="control-group">
<label class="control-label" for="waste_factor">Waste Factor</label>
<div class="controls">
<div class="input-append">
<input type="number"
class="input-small"
name="waste_factor"
id="waste_factor"
min="0"
max="100"
placeholder="15"
value="15"
required><span class="add-on">%</span>
</div>
</div>
</div>
</div>
</div>
</fieldset>
<button style="margin-top: 10px;" type="submit" class="btn btn-primary">Calculate</button>
</form>
</div>
<div class="span8">
<div class="hero-unit">
<div id="logo">
<img src="img/ubdc_300.png">
<h2>Stave Calculator</h2>
<p>
The Union Bridge Drum Co. Stave Calculator is a free and open source utility for
calculating the dimensions, angles, and costs associated with the production
of stave drums. If you would like to improve or make modifications to this utility, you
can fork the project on <a href="http://github.com/toddtreece/union-bridge-drums" target="_blank">GitHub</a>.
</p>
<p>
This tool functions best using the latest version of
<a href="https://www.google.com/chrome" target="_blank">Google Chrome</a> or
<a href="http://www.mozilla.org/firefox" target="_blank">Mozilla Firefox</a>.
</p>
</div>
<div>
<div id="illustration"></div>
</div>
</div>
<div id="results"></div>
</div>
</div>
</div>
<div id="result_template" class="hide">
<table class="table table-condensed table-bordered table-striped">
<tr>
<th></th>
<th>Decimal Inches</th>
<th>Fraction Inches</th>
<th>Centimeters</th>
</tr>
<tr>
<th>Rough Diameter</th>
<td>{{decimal.rough_diameter}}"</td>
<td>{{fraction.rough_diameter}}"</td>
<td>{{cm.rough_diameter}}cm</td>
</tr>
<tr>
<th>Finished Diameter</th>
<td>{{decimal.finished_diameter}}"</td>
<td>{{fraction.finished_diameter}}"</td>
<td>{{cm.finished_diameter}}cm</td>
</tr>
<tr>
<th>Shell Depth</th>
<td>{{decimal.shell_depth}}"</td>
<td>{{fraction.shell_depth}}"</td>
<td>{{cm.shell_depth}}cm</td>
</tr>
<tr>
<th>Number of Staves</th>
<td colspan="3">{{stave_count}}</td>
</tr>
<tr>
<th>Joint Angle</th>
<td colspan="3">{{joint_angle}}°</td>
</tr>
<tr>
<th>Bevel Angle</th>
<td colspan="3">{{bevel_angle}}°</td>
</tr>
<tr>
<th>Stave Outer Width</th>
<td>{{decimal.outer_dimension}}"</td>
<td>{{fraction.outer_dimension}}"</td>
<td>{{cm.outer_dimension}}cm</td>
</tr>
<tr>
<th>Stave Inner Width</th>
<td>{{decimal.inner_dimension}}"</td>
<td>{{fraction.inner_dimension}}"</td>
<td>{{cm.inner_dimension}}cm</td>
</tr>
<tr>
<th>Stave Thickness</th>
<td>{{decimal.board_thickness}}"</td>
<td>{{fraction.board_thickness}}"</td>
<td>{{cm.board_thickness}}cm</td>
</tr>
<tr>
<th>Rounded Thickness</th>
<td>{{decimal.rounded_thickness}}"</td>
<td>{{fraction.rounded_thickness}}"</td>
<td>{{cm.rounded_thickness}}cm</td>
</tr>
<tr>
<th>Board Length Required</th>
<td>{{decimal.board_length}}"</td>
<td>{{fraction.board_length}}"</td>
<td>{{cm.board_length}}cm</td>
</tr>
<tr>
<th>Staves per Width</th>
<td colspan="3">{{staves_per_width}}</td>
</tr>
<tr>
<th>Staves per Length</th>
<td colspan="3">{{staves_per_length}}</td>
</tr>
<tr>
<th>Board Feet Required</th>
<td colspan="3">{{board_feet}}'</td>
</tr>
<tr>
<th>Cost Per Shell</th>
<td colspan="3">${{cost}}</td>
</tr>
</table>
</div>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/raphael.min.js"></script>
<script src="js/jquery.mustache.js"></script>
<script src="js/stave.js"></script>
<script src="js/ruler.js"></script>
<script src="js/form.js"></script>
<script src="js/illustration.js"></script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-34255402-1']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'stats.g.doubleclick.net/dc.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
</body>
</html>