pipeline_stage   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/contrib/stream.xtm

Implementation

;; input only node
;; filter rate input
(bind-func pipeline_stage:[FilterData*,!a,i64,!b]*
  (lambda (filt rate input)
    (let ((r (/ rate (zero_check (filt.pop))))
    (p:i1 (or (refcheck filt prepush)
        (refcheck filt prepeek)
        (refcheck filt prepop)))
    (work (filt input))
    (makelwork:i1 (refcheck work make_lwork))
    (lwork:[void]*
     (if makelwork
         (let ((maker:[[void]*,i64]* (work.make_lwork)))
     (maker r))
         (lambda () (doloop (ii r) (work)))))
    (prework:[void]* (if p (work.prework) work)))
      (FilterData r input input work lwork prework #t #f))))


Back to Index

Similar Entries