Interaction

These pages weave interaction into the minimal application framework enabling the viewing of a 3D model. In the interest of producing a rendering worth interacting with, it expands the minimal framework to enable colorful objects.

This framework is given as pseudocode to be translated into JavaScript and, and this case, the OpenGL Shading Language. Many of the elements in this section link back to the application framework.

Viewer.js
  〈Interaction〉
  〈Initialization〉
  〈Rendering〉
Viewer.html
<html>
  <head>
   〈Headers〉
  </head>
  <body onload="init()">
    <script id="vertexShader" type="x-shader/x-vertex">
      〈Vertex Shader〉
    </script>
    <script id="fragmentShader" type="x-shader/x-fragment">
      〈Fragment Shader〉
    </script>
   〈Elements〉
  </body>
</html>