Work-in-progress repo for ambisonics extensions for OM-SoX
Alexander Nguyen
25.01.25 a590ad25dc2fa20301f47b7b6c84e5f176e36db2
commit | author | age
92c40d 1 ; OM File Header - Saved 2013/11/09 15:40:50
AN 2 ; (6.070005 :patc (om-make-point 33 89) (om-make-point 102 241) (om-make-point 913 406) "" 183 0 nil "2013/11/09 15:40:12")
3 ; End File Header
4 ; External resources 
5 ; (list (list (quote :picture) "#P\"../../../../resources/pict/noise-shape2\"" "#P\"../../../../resources/pict/noise-shape\"" "#P\"../../../../resources/pict/omsox\"") (list (quote :sound) "#P\"../../../../../../../../Research/OM-SoX/OM-SoX 1.0/resources/sounds/seagull.wav\""))
6 (in-package :om)(load-lib-for (quote ("OM-SoX")))(setf *om-current-persistent* (om-load-patch1 "dithering" (quote ((om-load-boxcomment "comment" (om-make-point 359 34) (quote "Apply dithering noise to audio using \"sox-dither\"") "" (om-make-point 129 22) nil (om-make-color 0.0 0.0 0.0) (om-make-font "Verdana" 14.0 :family "Verdana" :style (quote (:plain)) :mode (quote nil))) (om-load-editor-box1 "" (quote sound) (quote ((om-load-inputfun (quote input-funbox) "object" "self" nil) (om-load-inputfun (quote input-funbox) "a track index for multichannel mixing" "tracknum" 0) (om-load-inputfun (quote input-funbox) "a list of markers (s)" "markers" nil))) (om-make-point 161 304) (om-make-point 80 50) (let ((newobj nil)) (load-port-info newobj (quote nil)) (init-mus-color newobj (quote nil)) (set-extra-pairs newobj (quote nil)) (set-patch-pairs newobj (quote nil)) (set-name newobj "") (set-tonalite newobj nil) newobj) nil nil (pairlis (quote (approx fontsize staff cmnpref deltapict outport inport player zoom notechancolor? grillestep mode winsize winpos score-mode obj-mode show-stems scale palette-mode)) (list 2 24 (quote g) (let ((newobj (make-instance (quote edition-values)))) (setf (paper-size newobj) (om-make-point 600 800)) (setf (top-margin newobj) 2) (setf (left-margin newobj) 1) (setf (right-margin newobj) 1) (setf (bottom-margin newobj) 1) (setf (orientation newobj) nil) (setf (scale newobj) nil) (setf (system-space newobj) (quote (1))) (setf (system-color newobj) (quote nil)) (setf (line-space newobj) 1) (setf (title newobj) nil) (setf (show-title? newobj) nil) (setf (show-page? newobj) nil) (setf (sheet-id newobj) nil) (setf (page-mode newobj) nil) newobj) (om-make-point 0 0) nil 0 (quote :soxplayer) 1 nil 1000 0 (om-make-point 568 351) (om-make-point 400 22) 0 1 (quote t) nil 0)) t nil nil nil) (om-load-editor-box1 "seagull.wav" (quote sound) (quote ((om-load-inputfun (quote input-funbox) "object" "self" nil) (om-load-inputfun (quote input-funbox) "a track index for multichannel mixing" "tracknum" 0) (om-load-inputfun (quote input-funbox) "a list of markers (s)" "markers" nil))) (om-make-point 105 108) (om-make-point 80 50) (let ((newobj (let ((thesound (load-sound (om-make-pathname :directory (quote (:absolute "Users" "Marlon_MBPro3" "Research" "OM-SoX" "OM-SoX 1.0" "resources" "sounds")) :device nil :host nil :name "seagull" :type "wav") 0 100 0))) (when thesound (setf (markers thesound) (quote nil))) thesound))) (load-port-info newobj (quote nil)) (init-mus-color newobj (quote nil)) (set-extra-pairs newobj (quote nil)) (set-patch-pairs newobj (quote nil)) (set-name newobj "seagull.wav") (set-tonalite newobj nil) newobj) "x" nil (pairlis (quote (approx fontsize staff cmnpref deltapict outport inport player zoom notechancolor? grillestep mode winsize winpos score-mode obj-mode show-stems scale palette-mode)) (list 2 24 (quote g) (let ((newobj (make-instance (quote edition-values)))) (setf (paper-size newobj) (om-make-point 600 800)) (setf (top-margin newobj) 2) (setf (left-margin newobj) 1) (setf (right-margin newobj) 1) (setf (bottom-margin newobj) 1) (setf (orientation newobj) nil) (setf (scale newobj) nil) (setf (system-space newobj) (quote (1))) (setf (system-color newobj) (quote nil)) (setf (line-space newobj) 1) (setf (title newobj) nil) (setf (show-title? newobj) nil) (setf (show-page? newobj) nil) (setf (sheet-id newobj) nil) (setf (page-mode newobj) nil) newobj) (om-make-point 0 0) nil 0 (quote :soxplayer) 1 nil 1000 0 (om-make-point 548 292) (om-make-point 400 22) 0 1 (quote t) nil 0)) t nil nil nil) (om-load-boxcall (quote genfun) "SOX-DITHER" (quote sox-dither) (quote ((om-load-inputfunmenu1 (quote input-funmenu) "Select a noise-shaping filter from the menu. Note that most filter types are available only with 44100Hz sample rate." "NOISESHAPE" "f-weighted" (list (list "triangular" "triangular") (list "sloped-triangular" "sloped-triangular") (list "lipshitz" "lipshitz") (list "f-weighted" "f-weighted") (list "modified-e-weighted" "modified-e-weighted") (list "improved-e-weighted" "improved-e-weighted") (list "gesemann" "gesemann") (list "shibata" "shibata") (list "low-shibata" "low-shibata") (list "high-shibata" "high-shibata"))))) (om-make-point 278 122) nil nil nil nil 1) (om-load-boxcomment "comment" (om-make-point 421 150) (quote "Apply dithering to the audio. Dithering deliberately adds a small $amount of noise to the signal in order to mask audible quantization $effects that can occur if the output sample size is less than 24 bits. $A particular noise-shaping filter (only for certain sample rates) can be selected from the menu. Most filter types are available only with 44100Hz sample rate. The filter types are distinguished by the following properties: audibility of noise, level of (inaudible, but in some circumstances, otherwise problematic) shaped high frequency noise, and processing speed. ") "" (om-make-point 424 99) nil (om-make-color 0.0 0.19194556 1.0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))) (om-load-boxcall (quote abstraction) "some infos on dithering" (om-load-patch-abs1 "some infos on dithering" (quote ((om-load-boxcomment "comment 2" (om-make-point 1094 254) (quote "Dithering is a technique used to maximise the dynamic range of audio stored at a particular bit-depth. $Any distortion introduced by quantisation is decorrelated by adding a small amount of white noise to the signal. $In most cases, SoX can determine whether the selected processing requires dither and will add it during output formatting if appropriate.$Specifically, by default, SoX automatically adds TPDF dither when the output bit-depth is less than 24 and any of the following are true:$$-bit-depth reduction has been specified explicitly using a command-line option $-the output file format supports only bit-depths lower than that of the input file format $-an effect has increased effective bit-depth within the internal processing chain$$For example, adjusting volume with vol 0.25 requires two additional bits in which to losslessly store its results (since 0.25 decimal equals 0.01 binary). $So if the input file bit-depth is 16, then SoX's internal representation will utilise 18 bits after processing this volume change. In order to store the output at the same depth as the input, dithering is used to remove the additional bits.$Use the -V option to see what processing SoX has automatically added. The -D option may be given to override automatic dithering. To invoke dithering manually (e.g. to select a noise-shaping curve), use sox-dither.") "" (om-make-point 37 109) nil (om-make-color 0.0 0.19194556 1.0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))) (om-load-boxcomment "comment" (om-make-point 129 34) (quote "About Dithering:") "" (om-make-point 37 64) nil (om-make-color 0.0 0.19194556 1.0) (om-make-font "Verdana" 14.0 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (quote nil) 6.070005 nil "" (om-make-point 200 200) (om-make-point 1207 441)) (quote nil) (om-make-point 606 292) nil nil nil "some infos on dithering") (om-load-boxcall (quote genfun) "SOX-PROCESS" (quote sox-process) (quote ((om-load-inputfun (quote input-funbox) "" "INPUT" nil) (om-load-inputfun (quote input-funbox) "" "COMMANDS" "") (om-load-inputkeyword (quote input-keyword) "Bitdepth of produced audio [number]" "bitdepth" (quote :bitdepth) 8 (list (list "8" 8) (list "16" 16) (list "24" 24) (list "32" 32) (list "64" 64))))) (om-make-point 145 205) nil nil nil nil 1) (om-load-boxcall (quote abstraction) "noise shaping presets" (om-load-patch-abs1 "noise shaping presets" (quote ((om-load-boxcomment "comment 2" (om-make-point 452 45) (quote "Response of the noise shaping filters:$(see http://sox.sourceforge.net/SoX/NoiseShaping for more information)") "" (om-make-point 77 35) nil (om-make-color 0.0 0.19194556 1.0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))) (om-load-boxcomment "comment" (om-make-point 61 30) (quote "DITHER:") "" (om-make-point 75 9) nil (om-make-color 0.0 0.19194556 1.0) (om-make-font "Verdana" 12 :family "Verdana" :style (quote (:plain)) :mode (quote nil))))) (quote nil) 6.070005 (list (let ((newpict (make-instance (quote patch-picture) :name "noise-shape2" :source (quote user) :pict-pathname (restore-pict-path (restore-path nil)) :thepict (om-get-picture "noise-shape2" (quote user)) :storemode :external :draw-params (quote (p 0 0 100 100)) :extraobjs nil))) (setf (pict-pos newpict) (om-make-point 78 415)) (setf (pict-size newpict) (om-make-point 622 274)) newpict) (let ((newpict (make-instance (quote patch-picture) :name "noise-shape" :source (quote user) :pict-pathname (restore-pict-path (restore-path nil)) :thepict (om-get-picture "noise-shape" (quote user)) :storemode :external :draw-params (quote (p 0 0 100 100)) :extraobjs nil))) (setf (pict-pos newpict) (om-make-point 78 97)) (setf (pict-size newpict) (om-make-point 618 267)) newpict)) "" (om-make-point 200 200) (om-make-point 767 743)) (quote nil) (om-make-point 430 290) nil nil nil "noise shaping presets"))) (quote ((6 0 1 0 nil 0) (2 0 6 0 nil 0) (3 0 6 1 nil 0))) (list (let ((newpict (make-instance (quote patch-picture) :name "omsox" :source (quote user) :pict-pathname (restore-pict-path (restore-path nil)) :thepict (om-get-picture "omsox" (quote user)) :storemode :external :draw-params (quote (p 0 0 100 100)) :extraobjs nil))) (setf (pict-pos newpict) (om-make-point 63 8)) (setf (pict-size newpict) (om-make-point 63 54)) newpict)) 6.070005))