Fork me on GitHub

Is it possible to draw lines using a dotted pattern? I looked at stroke and fill fns, bit they don’t seem to allow that..

Eric Ervin01:08:32

I translated this from an example in java processing.

(defn dotted-line [x1 y1 x2 y2 dots]
  (doseq [i (range dots)]
    (let [x (q/lerp x1 x2 (/ i dots))
          y (q/lerp y1 y2 (/ i dots))]
        (q/point x y))))


@U9U0G3Q8Y Very nice - Thanks!


hey there! i’m working on a immersive LED sculpture project using the amazing and i’m running into an issue. I’ve been able to use quil to run lxstudio successfully, but lxstudio uses a few callbacks that are usually defined in the main processing sketch, namely void initialize(final lx, ui) and void onUIReady( lx, ui). Does anyone know how might be able to extend quil to implement these methods?