Skip to content

Commit

Permalink
Fix compilation problem.
Browse files Browse the repository at this point in the history
Can't create step parameter without default show or explicit metronome.
  • Loading branch information
brunchboy committed Nov 25, 2015
1 parent 8b6b134 commit d17f43f
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/afterglow/examples.clj
Original file line number Diff line number Diff line change
Expand Up @@ -345,10 +345,10 @@
(cues/function-cue :snowball-sound :sound-active (show/fixtures-named "snowball")
:color :cyan)))

(def step-param
"A step parameter for controlling example chase cuse. Redefine it to
experiment with other kinds of timing and fades."
(params/build-step-param :fade-fraction 0.3 :fade-curve :sine))
(defonce ^{:doc "A step parameter for controlling example chase cues.
Change it to experiment with other kinds of timing and fades."}
step-param
(atom nil))

(defn make-cues
"Create a bunch of example cues for experimentation."
Expand Down Expand Up @@ -825,6 +825,9 @@
:variables [{:key "position" :min -0.5 :max 10.5 :start 0.0 :name "Position"}]
:color :purple))

;; Set up an initial value for our step parameter
(reset! step-param (params/build-step-param :fade-fraction 0.3 :fade-curve :sine))

(ct/set-cue!
(:cue-grid *show*) 1 13
(cues/cue :chase (fn [var-map]
Expand All @@ -833,7 +836,7 @@
(global-color-effect :green :lights (show/fixtures-named "blade"))
(global-color-effect :blue :lights (show/fixtures-named "hex"))
(global-color-effect :white :lights (show/all-fixtures))]
step-param :beyond :loop))
@step-param :beyond :loop))
:color :magenta))

;; Some compound cues
Expand Down

0 comments on commit d17f43f

Please sign in to comment.