rsc3/doc/help/ugen/fft/pv-rect-comb.help.scrbl

35 lines
707 B
Text
Raw Normal View History

2022-08-24 13:53:18 +00:00
#lang scribble/manual
@(require (for-label racket))
2022-08-28 10:27:01 +00:00
@title{(pv-rect-comb buffer numTeeth phase width)}
2022-08-24 13:53:18 +00:00
2022-08-28 10:27:01 +00:00
@racketblock[
2022-08-24 13:53:18 +00:00
(with-sc3
(lambda (fd)
(async fd (b-alloc 10 2048 1))))
2022-08-28 10:27:01 +00:00
]
2022-08-24 13:53:18 +00:00
2022-08-28 10:27:01 +00:00
@racketblock[
2022-08-24 13:53:18 +00:00
(let* ((dup (lambda (a) (mce2 a a)))
(x (mouse-x kr 0 0.5 0 0.1))
(y (mouse-y kr 0 0.5 0 0.1))
(n (dup (mul (white-noise ar) 0.3)))
(c (pv-rect-comb (fft* 10 n) 8 x y)))
(audition (out 0 (ifft* c))))
2022-08-28 10:27:01 +00:00
]
2022-08-24 13:53:18 +00:00
2022-08-28 10:27:01 +00:00
@racketblock[
2022-08-24 13:53:18 +00:00
(let* ((dup (lambda (a) (mce2 a a)))
(p (mul-add (lf-tri kr 0.097 0) 0.4 0.5))
(w (mul-add (lf-tri kr 0.24 0) -0.5 0.5))
(n (dup (mul (white-noise ar) 0.3)))
(c (pv-rect-comb (fft* 10 n) 8 p w)))
2022-08-28 10:27:01 +00:00
(audition (out 0 (ifft* c))))
]
2022-08-24 13:53:18 +00:00