<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0"> <title>Three.js Test</title> <!-- css --> <style> body { margin:0px; padding:0px; } .canvas_box { margin:0px; padding:0px; width:100%; height:100%; overflow:hidden; background-color:#ccc; position:relative; } #canvas_main { margin:0px; padding:0px; width:100%; height:100%; } .form_ctrl { margin:0px; padding:10px; position:absolute; top:10; left:10; background-color: rgba(0,0,0,0.3); } .btn_pm { margin-left:5px; } </style> <!-- js --> <script src="js/jquery-1.11.2.min.js"></script> <script src="js/three/three.min.js"></script> <script src="js/three/Detector.js"></script> <script src="js/angleTest.js"></script> <script> jQuery(function(){ $(window).on("load",function(){ $("#canvas_main").angleTest({ camera : { fov : 60, } }); }); }); </script> </head> <body> <div class="canvas_box"> <canvas id="canvas_main"></canvas> <div class="form_ctrl"> <table cellspacing="0" cellpadding="0" border="0"> <tr> <td><span style="color:#666;">X:</span></td> <td><input type="text" class="angle" id="ax" size="4" value="0" /></td> <td><button class="btn_pm" data-type="add" data-target="ax">+</button><button class="btn_pm" data-type="sub" data-target="ax">-</button></td> <tr> <tr> <td><span style="color:#666;">Y:</span></td> <td><input type="text" class="angle" id="ay" size="4" value="0" /></td> <td><button class="btn_pm" data-type="add" data-target="ay">+</button><button class="btn_pm" data-type="sub" data-target="ay">-</button></td> <tr> <tr> <td><span style="color:#666;">Z:</span></td> <td><input type="text" class="angle" id="az" size="4" value="0" /></td> <td><button class="btn_pm" data-type="add" data-target="az">+</button><button class="btn_pm" data-type="sub" data-target="az">-</button></td> <tr> </table> <hr /> <div style="text-align:right;"> <button id="btn_reset">reset</button> </div> </div> </div> </body> </html>