     (do
       (aset glc "viewportWidth" (aget canvas "width"))
       (aset glc "viewportHeight" (aget canvas "height"))
-      (.enable glc (aget glc "DEPTH_TEST"))
+      (.enable glc (.-DEPTH_TEST glc))
       (.clearColor glc 0.0 0.0 0.0 1.0)
-      (.enable glc (aget glc "DEPTH_TEST"))
-      (.depthFunc glc (aget glc "LEQUAL"))
+      (.enable glc (.-DEPTH_TEST glc))
+      (.depthFunc glc (.-LEQUAL glc))
       glc)
     (do
       (util/log "Unable to load webgl context. Your browser may not support it.")

(defn mat-identity
  "Creates an identity matrix."
  [size]
  ((aget goog.math.Matrix "createIdentityMatrix") size))

(defn mat-translation
  "Returns a 4x4 matrix representing a translation."

    (.attachShader gl prgrm vert)
    (.attachShader gl prgrm frag)
    (.linkProgram gl prgrm)
    (if (not (.getProgramParameter gl prgrm (.-LINK_STATUS gl)))
      (do
        (util/log "An error occured while linking the shader.")
        nil)
