 (ns gampg.learn-gamma.lesson-09
-  (:require [clojure.string :as s]
-            [gamma.api :as g]
+  (:require [gamma.api :as g]
             [gamma.program :as p]
-            [gamma.tools :as gt]
+            [gamma-driver.api :as gd]
             [gamma-driver.drivers.basic :as driver]
-            [gamma-driver.protocols :as dp]
-            [goog.webgl :as ggl]
             [thi.ng.geom.core :as geom]
-            [thi.ng.geom.core.matrix :as mat :refer [M44]]
-            [thi.ng.geom.webgl.arrays :as arrays]))
+            [thi.ng.geom.core.matrix :as mat :refer [M44]]))
 
 (def title
   "9. Lots of moving objects")

                     (geom/rotate-around-axis [0 0 1] (:angle star))
                     (geom/translate [(:distance star) 0 -7])
                     (geom/rotate-around-axis [0 0 -1] (- (:angle star))))]
          (driver/draw-arrays driver program
                               (get-data p mv star-vertices texture star-texture-coords (if twinkle?
                                                                                          (:twinkle star)
                                                                                          (:color star)))
                               {:draw-mode :triangle-strip}))))))  

(defn animate [draw-fn step-fn current-value]
  (js/requestAnimationFrame

  (let [width   (.-clientWidth node)
        height  (.-clientHeight node)
        driver  (driver/basic-driver gl)
        program program-source
        state   (app-state width height)]
    (reset-gl-canvas! node)
    ;; Set the blending function
