mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-22 15:20:15 +02:00
Fixed table size for soft clip Limiter
Fixes exceeding max table size at high sample rates.
This commit is contained in:
parent
888b41aafc
commit
c042b0c7c6
@ -86,7 +86,8 @@
|
||||
(defun soft-clip-table ()
|
||||
"Lookup table for soft clipping wave-shaper"
|
||||
(abs-env
|
||||
(Control-srate-abs *sound-srate*
|
||||
(sound-srate-abs 44100
|
||||
(Control-srate-abs 44100
|
||||
(let* ((knee (- 1 (/ 1.0 pi)))
|
||||
(kcurve (mult knee (osc (hz-to-step (/ (* 4 knee))) knee)))
|
||||
(ikcurve (mult knee (osc (hz-to-step (/ (* 4 knee))) knee *sine-table* -90)))
|
||||
@ -99,7 +100,7 @@
|
||||
(sim
|
||||
(at-abs 0 (cue ikcurve))
|
||||
(at-abs 0 (cue lin))
|
||||
(at-abs (+ knee (/ 2.0 pi)) (cue kcurve))))))))
|
||||
(at-abs (+ knee (/ 2.0 pi)) (cue kcurve)))))))))
|
||||
|
||||
(defun soft-clip (sig)
|
||||
(let* ((knee (- 1 (/ 1.0 pi)))
|
||||
|
Loading…
x
Reference in New Issue
Block a user