changed linear interpolation to nearest and added rube ragdoll with testbed in lab

This commit is contained in:
logsol 2014-02-16 23:00:01 +01:00
parent 47bb5ef147
commit 86063661db
28 changed files with 31671 additions and 2 deletions

71
lab/rube/js/index.html Normal file
View file

@ -0,0 +1,71 @@
<html>
<head>
<title>Box2D javascript (box2dweb) testbed</title>
<script type="text/javascript" src="box2dweb.js"></script>
<script type="text/javascript" src="loadrube.js"></script>
<script type="text/javascript" src="testbed.js"></script>
<script type="text/javascript" src="jack-min.js"></script>
<script type="text/javascript" src="jackinthebox.js"></script>
<script type="text/javascript" src="ragdoll-min.js"></script>
<script type="text/javascript" src="ragdoll.js"></script>
</head>
<body>
<div style="text-align:center">
<br>
Try the latest version of Chrome or Firefox for best performance.<br>
<br>
<div style="margin:auto;width:640px;padding:2px;border:1px solid #888;text-align:left">
<!--
If you change the size of the canvas, you'll also need to change
the value of 'viewCenterPixel' in testbed.js
-->
<canvas id="canvas" width="640" height="480" tabindex='1'></canvas>
<div style="width:636px;padding:2px;background-color:#ddd">
<div style="text-align:center">
Select test: <select id="testSelection" onchange="changeTest();">
<option value="ragdoll">Ragdoll of Chuck</option>
<option value="jackinthebox">Jack-in-the-box</option>
</select><br>
<div style="height:6px"></div>
<div id="sceneinfo" style="width:500px;margin:auto;background-color:#eee;text-align:left">
Loading...
</div>
<div id="testcomments" style="width:500px;margin:auto;background-color:#eee;text-align:left">
</div>
<br>
<button id="reloadButton" onclick="resetScene();">Reset</button>
<button id="pauseButton" onclick="pause();">Pause</button>
<button id="stepButton" onclick="step();">Single step</button>
(Keyboard: R, P, S)<br>
Zoom
<button id="zoomInButton" onclick="zoomIn();">+</button>
<button id="zoomOutButton" onclick="zoomOut();">-</button>
(Keyboard: X, Z)<br>
Hold down Shift while moving the mouse to pan (Keyboard: arrow keys)<br>
You need to click on the canvas before using the keyboard.<br>
</div>
<br>
Debug draw flags:<br>
<input id="drawShapesCheck" type="checkbox" onclick="updateWorldFromDebugDrawCheckboxes();">Shapes<br>
<input id="drawJointsCheck" type="checkbox" onclick="updateWorldFromDebugDrawCheckboxes();">Joints<br>
<input id="drawAABBsCheck" type="checkbox" onclick="updateWorldFromDebugDrawCheckboxes();">AABBs<br>
<input id="drawTransformsCheck" type="checkbox" onclick="updateWorldFromDebugDrawCheckboxes();">Transforms<br>
<br>
<input id="showStatsCheck" type="checkbox" onclick="updateContinuousRefreshStatus();">Show stats<br>
<span id="feedbackSpan"></span>
<br>
</div>
</div>
</div>
</body>
</html>