clock_scheduler   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm

Implementation

(bind-func clock_scheduler
  (lambda (hz:double)
    (let ((evtlist:SchedEvt{double}* null)
          (ft:[void,double]* null)
          (scheduler:[i64,double]* null)
          (running:i64 1)
          (time 0.0)
          (err 0)
          (i (/ 1.0 hz))
          (f (lambda ()
              (spawn (lambda ()
                        (set! scheduler (scheduler_init evtlist ft))
                        (set! time (clock_clock))
                        (while (> running 0)
                          (scheduler time)
                          (while (< (clock_clock) time) (thread_sleep 0 100000))
                          (set! time (+ time i))
                          void)
                        (println "exiting scheduler")))
              void)))
      (f)
      f)))


Back to Index

Similar Entries

  • -clock:metro-from-host-    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • -clock:metro-from-host-    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • arrows_clockspin_heads    xtlang    /digego/extempore/tree/v0.8.9/examples/external/shader-tutorials/arrows.xtm
  • beat_scheduler    xtlang    /digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm
  • clock->samples    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • clock-client-receive    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • clock-runsync    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • clock-server-receive    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • clock-set-bpm    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • clock-set-cycle    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • clock:offset-from-server    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • clock:sync-adjust    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • clock:update-metro    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • clock:update-metro    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • clock_scheduler_main_callback    xtlang    /digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm
  • clock_test_a    xtlang    /digego/extempore/tree/v0.8.9/examples/core/scheduler.xtm
  • clock_test_b    xtlang    /digego/extempore/tree/v0.8.9/examples/core/scheduler.xtm
  • get_midi_evt_clocktime    xtlang    /digego/extempore/tree/v0.8.9/libs/external/midi.xtm
  • join-clock-time    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • samples->clock    scheme    /digego/extempore/tree/v0.8.9/runtime/scheme.xtm
  • scheduler_at    xtlang    /digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm
  • scheduler_evt    xtlang    /digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm
  • scheduler_init    xtlang    /digego/extempore/tree/v0.8.9/libs/core/scheduler.xtm
  • split-clock-time    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • start_midi_scheduler    xtlang    /digego/extempore/tree/v0.8.9/libs/external/midi.xtm
  • topclock-bpm    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • topclock-election    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • topclock-receive    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • topclock-streamer    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • topclock-sync    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • topclock-variable    scheme    /digego/extempore/tree/v0.8.9/libs/core/topclock.xtm
  • toplap-clock-election    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm
  • toplap-clock-sync    scheme    /digego/extempore/tree/v0.8.9/libs/core/toplap_clock.xtm