index.html 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta content="text/html; charset=windows-1252" http-equiv="content-type"/>
  5. <title>ObJS</title>
  6. <!--Script files -->
  7. <script type="text/javascript" src="script/ObJS.js"></script>
  8. <!-- CSS files -->
  9. </head>
  10. <body onload="loadModel(document.getElementById('objSelector'));">
  11. <table>
  12. <tr>
  13. <td>
  14. <canvas id="ObJSCanvas" width="600" height="600">
  15. Your browser does not support the HTML5 canvas tag.
  16. </canvas>
  17. </td>
  18. <td>
  19. Choose a model:
  20. <select id="objSelector" name="objSelector" onChange="loadModel(this)">
  21. <option value="cube" selected="selected">Cube</option>
  22. <option value="sphere">Sphere</option>
  23. <option value="monkey">Monkey</option>
  24. <option value="bolt">Bolt</option>
  25. <option value="multiple">Multiple Objects</option>
  26. </select>
  27. <br/><br/><br/>
  28. <pre><input type="checkbox" name="drawElement" value="backg" checked onChange="drawElement('backg', this.checked);"/>Background <input type="color" id="colorBackg" value="#C8C8C8" onChange="colorElement('backg', this.value);"/></pre>
  29. <br/>
  30. <pre><input type="checkbox" name="drawElement" value="verts" checked onChange="drawElement('verts', this.checked);"/>Vertices <input type="color" id="colorVerts" value="#0A0A0A" onChange="colorElement('verts', this.value);"/></pre>
  31. <br/>
  32. <pre><input type="checkbox" name="drawElement" value="edges" checked onChange="drawElement('edges', this.checked);"/>Edges <input type="color" id="colorEdges" value="#644646" onChange="colorElement('edges', this.value);"/></pre>
  33. <br/>
  34. <pre><input type="checkbox" name="drawElement" value="faces" checked onSlide="drawElement('faces', this.checked);"/>Faces <input type="color" id="colorFaces" value="#B4B4FF" onChange="colorElement('faces', this.value);"/></pre>
  35. <pre> Alpha:<br/> 0% <input id="slide" type="range" min="0" max="100" step="1" value="60" onInput="setAlpha(this.value);" onChange="setAlpha(this.value);"/>100%</pre>
  36. </td>
  37. </tr>
  38. </table>
  39. </body>
  40. </html>