cyfaust 0.1.0__cp311-cp311-macosx_15_0_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cyfaust/CMakeLists.txt +93 -0
- cyfaust/__init__.py +0 -0
- cyfaust/__main__.py +819 -0
- cyfaust/box.pxd +46 -0
- cyfaust/box.pyx +2459 -0
- cyfaust/common.pxd +5 -0
- cyfaust/common.pyx +61 -0
- cyfaust/cyfaust.cpython-311-darwin.so +0 -0
- cyfaust/faust_box.pxd +298 -0
- cyfaust/faust_box_oo.pyx +66 -0
- cyfaust/faust_gui.pxd +261 -0
- cyfaust/faust_interp.pxd +160 -0
- cyfaust/faust_player.pxd +80 -0
- cyfaust/faust_signal.pxd +257 -0
- cyfaust/gui_statics.cpp +15 -0
- cyfaust/interp.pyx +673 -0
- cyfaust/player.cpp +32519 -0
- cyfaust/player.pyx +191 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUBase.cpp +2327 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUBase.h +1019 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUDispatch.cpp +423 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUDispatch.h +82 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUInputElement.cpp +151 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUInputElement.h +119 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUOutputElement.cpp +62 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUOutputElement.h +66 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUPlugInDispatch.cpp +615 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUPlugInDispatch.h +128 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUScopeElement.cpp +512 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/AUScopeElement.h +544 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/ComponentBase.cpp +370 -0
- cyfaust/resources/architecture/AU/AUPublic/AUBase/ComponentBase.h +340 -0
- cyfaust/resources/architecture/AU/AUPublic/AUEffectBase/AUEffectBase.cpp +463 -0
- cyfaust/resources/architecture/AU/AUPublic/AUEffectBase/AUEffectBase.h +391 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/AUInstrumentBase.cpp +837 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/AUInstrumentBase.h +267 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/AUMIDIBase.cpp +495 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/AUMIDIBase.h +213 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/LockFreeFIFO.h +168 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/MIDIControlHandler.h +92 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/MusicDeviceBase.cpp +354 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/MusicDeviceBase.h +126 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthElement.cpp +419 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthElement.h +227 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthEvent.h +145 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthNote.cpp +138 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthNote.h +186 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthNoteList.cpp +93 -0
- cyfaust/resources/architecture/AU/AUPublic/AUInstrumentBase/SynthNoteList.h +232 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUBaseHelper.cpp +134 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUBaseHelper.h +80 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUBuffer.cpp +217 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUBuffer.h +267 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUMIDIDefs.h +136 -0
- cyfaust/resources/architecture/AU/AUPublic/Utility/AUSilentTimeout.h +93 -0
- cyfaust/resources/architecture/AU/English.lproj/InfoPlist.strings +0 -0
- cyfaust/resources/architecture/AU/FaustAU.exp +2 -0
- cyfaust/resources/architecture/AU/FaustAU.xcodeproj/project.pbxproj +968 -0
- cyfaust/resources/architecture/AU/FaustAU.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
- cyfaust/resources/architecture/AU/FaustAUCustomView.plist +14 -0
- cyfaust/resources/architecture/AU/Info.plist +47 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAAtomic.h +305 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAAtomicStack.h +239 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAAudioChannelLayout.cpp +153 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAAudioChannelLayout.h +199 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAAutoDisposer.h +508 -0
- cyfaust/resources/architecture/AU/PublicUtility/CABufferList.cpp +264 -0
- cyfaust/resources/architecture/AU/PublicUtility/CABufferList.h +319 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAByteOrder.h +161 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugMacros.cpp +88 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugMacros.h +580 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugPrintf.cpp +89 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugPrintf.h +115 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugger.cpp +77 -0
- cyfaust/resources/architecture/AU/PublicUtility/CADebugger.h +56 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAException.h +83 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAGuard.cpp +339 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAGuard.h +133 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAHostTimeBase.cpp +110 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAHostTimeBase.h +231 -0
- cyfaust/resources/architecture/AU/PublicUtility/CALogMacros.h +140 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAMath.h +68 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAMutex.cpp +345 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAMutex.h +163 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAReferenceCounted.h +87 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAStreamBasicDescription.cpp +795 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAStreamBasicDescription.h +409 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAThreadSafeList.h +255 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAVectorUnit.cpp +191 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAVectorUnit.h +100 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAVectorUnitTypes.h +59 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAXException.cpp +49 -0
- cyfaust/resources/architecture/AU/PublicUtility/CAXException.h +338 -0
- cyfaust/resources/architecture/AU/SectionPatternLight.tiff +0 -0
- cyfaust/resources/architecture/AU/Source/AUSource/FaustAU.h +38 -0
- cyfaust/resources/architecture/AU/Source/AUSource/FaustAU.r +153 -0
- cyfaust/resources/architecture/AU/Source/AUSource/FaustAUVersion.h +64 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Bargraph.h +18 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Bargraph.m +21 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Button.h +20 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Button.m +56 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_CustomView.h +87 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_CustomView.m +834 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_CustomViewFactory.h +13 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_CustomViewFactory.m +22 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Knob.h +81 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Knob.m +199 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Slider.h +18 -0
- cyfaust/resources/architecture/AU/Source/CocoaUI/FaustAU_Slider.m +21 -0
- cyfaust/resources/architecture/AU/version.plist +16 -0
- cyfaust/resources/architecture/VST/Info.plist +28 -0
- cyfaust/resources/architecture/VST/PkgInfo +1 -0
- cyfaust/resources/architecture/VST/README +11 -0
- cyfaust/resources/architecture/VST/VST.xcode/project.pbxproj +655 -0
- cyfaust/resources/architecture/alsa-console.cpp +246 -0
- cyfaust/resources/architecture/alsa-gtk.cpp +220 -0
- cyfaust/resources/architecture/alsa-qt.cpp +229 -0
- cyfaust/resources/architecture/api/DspFaust.cpp +612 -0
- cyfaust/resources/architecture/api/DspFaust.h +511 -0
- cyfaust/resources/architecture/api/README.md +237 -0
- cyfaust/resources/architecture/api/doc/Generic.md +38 -0
- cyfaust/resources/architecture/au-effect.cpp +487 -0
- cyfaust/resources/architecture/au-instrument.cpp +573 -0
- cyfaust/resources/architecture/bench.cpp +91 -0
- cyfaust/resources/architecture/c-jack-gtk.c +227 -0
- cyfaust/resources/architecture/ca-gtk.cpp +284 -0
- cyfaust/resources/architecture/ca-qt.cpp +424 -0
- cyfaust/resources/architecture/cpal.rs +195 -0
- cyfaust/resources/architecture/csound.cpp +245 -0
- cyfaust/resources/architecture/csvplot.cpp +227 -0
- cyfaust/resources/architecture/daisy/Makefile +14 -0
- cyfaust/resources/architecture/daisy/README.md +50 -0
- cyfaust/resources/architecture/daisy/ex_faust.cpp +173 -0
- cyfaust/resources/architecture/dssi.cpp +1262 -0
- cyfaust/resources/architecture/dummy-mem.cpp +186 -0
- cyfaust/resources/architecture/dummy.cpp +294 -0
- cyfaust/resources/architecture/faust/au/AUUI.h +404 -0
- cyfaust/resources/architecture/faust/audio/alsa-dsp.h +693 -0
- cyfaust/resources/architecture/faust/audio/android-dsp.h +583 -0
- cyfaust/resources/architecture/faust/audio/audio.h +115 -0
- cyfaust/resources/architecture/faust/audio/channels.h +122 -0
- cyfaust/resources/architecture/faust/audio/coreaudio-dsp.h +1543 -0
- cyfaust/resources/architecture/faust/audio/coreaudio-ios-dsp.h +743 -0
- cyfaust/resources/architecture/faust/audio/dummy-audio.h +255 -0
- cyfaust/resources/architecture/faust/audio/esp32-dsp.h +284 -0
- cyfaust/resources/architecture/faust/audio/fpe.h +164 -0
- cyfaust/resources/architecture/faust/audio/jack-dsp.h +534 -0
- cyfaust/resources/architecture/faust/audio/juce-dsp.h +119 -0
- cyfaust/resources/architecture/faust/audio/netjack-dsp.h +354 -0
- cyfaust/resources/architecture/faust/audio/oboe-dsp.h +308 -0
- cyfaust/resources/architecture/faust/audio/ofaudio-dsp.h +155 -0
- cyfaust/resources/architecture/faust/audio/opensles-android-dsp.h +631 -0
- cyfaust/resources/architecture/faust/audio/osc-dsp.h +120 -0
- cyfaust/resources/architecture/faust/audio/portaudio-dsp.h +236 -0
- cyfaust/resources/architecture/faust/audio/rtaudio-dsp.h +241 -0
- cyfaust/resources/architecture/faust/audio/samAudio.h +140 -0
- cyfaust/resources/architecture/faust/audio/teensy-dsp.h +171 -0
- cyfaust/resources/architecture/faust/dsp/cmajor-cpp-dsp.h +253 -0
- cyfaust/resources/architecture/faust/dsp/cmajorpatch-dsp.h +483 -0
- cyfaust/resources/architecture/faust/dsp/cpp-dsp-adapter.h +38 -0
- cyfaust/resources/architecture/faust/dsp/dsp-adapter.h +836 -0
- cyfaust/resources/architecture/faust/dsp/dsp-bench.h +611 -0
- cyfaust/resources/architecture/faust/dsp/dsp-checker.h +115 -0
- cyfaust/resources/architecture/faust/dsp/dsp-combiner.h +810 -0
- cyfaust/resources/architecture/faust/dsp/dsp-compute-adapter.h +159 -0
- cyfaust/resources/architecture/faust/dsp/dsp-multi.h +702 -0
- cyfaust/resources/architecture/faust/dsp/dsp-multifun.h +90 -0
- cyfaust/resources/architecture/faust/dsp/dsp-optimizer.h +511 -0
- cyfaust/resources/architecture/faust/dsp/dsp-tools.h +229 -0
- cyfaust/resources/architecture/faust/dsp/dsp.h +321 -0
- cyfaust/resources/architecture/faust/dsp/fastmath.cpp +301 -0
- cyfaust/resources/architecture/faust/dsp/faust-dynamic-engine.cpp +494 -0
- cyfaust/resources/architecture/faust/dsp/faust-dynamic-engine.h +386 -0
- cyfaust/resources/architecture/faust/dsp/faust-engine.h +75 -0
- cyfaust/resources/architecture/faust/dsp/faust-poly-engine.h +638 -0
- cyfaust/resources/architecture/faust/dsp/interpreter-dsp-c.h +288 -0
- cyfaust/resources/architecture/faust/dsp/interpreter-dsp.h +362 -0
- cyfaust/resources/architecture/faust/dsp/interpreter-machine-dsp.h +233 -0
- cyfaust/resources/architecture/faust/dsp/libfaust-box-c.h +817 -0
- cyfaust/resources/architecture/faust/dsp/libfaust-box.h +889 -0
- cyfaust/resources/architecture/faust/dsp/libfaust-c.h +116 -0
- cyfaust/resources/architecture/faust/dsp/libfaust-signal-c.h +649 -0
- cyfaust/resources/architecture/faust/dsp/libfaust-signal.h +731 -0
- cyfaust/resources/architecture/faust/dsp/llvm-dsp-adapter.h +160 -0
- cyfaust/resources/architecture/faust/dsp/llvm-dsp-c.h +524 -0
- cyfaust/resources/architecture/faust/dsp/llvm-dsp.h +575 -0
- cyfaust/resources/architecture/faust/dsp/llvm-machine-dsp.h +215 -0
- cyfaust/resources/architecture/faust/dsp/one-sample-dsp.h +477 -0
- cyfaust/resources/architecture/faust/dsp/poly-dsp.h +1079 -0
- cyfaust/resources/architecture/faust/dsp/poly-interpreter-dsp.h +143 -0
- cyfaust/resources/architecture/faust/dsp/poly-llvm-dsp.h +249 -0
- cyfaust/resources/architecture/faust/dsp/poly-wasm-dsp.h +257 -0
- cyfaust/resources/architecture/faust/dsp/proxy-dsp.h +108 -0
- cyfaust/resources/architecture/faust/dsp/proxy-osc-dsp.h +109 -0
- cyfaust/resources/architecture/faust/dsp/rnbo-dsp.h +187 -0
- cyfaust/resources/architecture/faust/dsp/sound-player.h +428 -0
- cyfaust/resources/architecture/faust/dsp/timed-dsp.h +279 -0
- cyfaust/resources/architecture/faust/dsp/wasm-dsp-imp.h +188 -0
- cyfaust/resources/architecture/faust/dsp/wasm-dsp.h +309 -0
- cyfaust/resources/architecture/faust/dsp/ysfx-dsp.h +188 -0
- cyfaust/resources/architecture/faust/export.h +61 -0
- cyfaust/resources/architecture/faust/gui/APIUI.h +726 -0
- cyfaust/resources/architecture/faust/gui/BelaOSCUI.h +170 -0
- cyfaust/resources/architecture/faust/gui/CGlue.h +667 -0
- cyfaust/resources/architecture/faust/gui/CInterface.h +142 -0
- cyfaust/resources/architecture/faust/gui/ControlSequenceUI.h +197 -0
- cyfaust/resources/architecture/faust/gui/ControlUI.h +137 -0
- cyfaust/resources/architecture/faust/gui/DaisyControlUI.h +283 -0
- cyfaust/resources/architecture/faust/gui/DaisyPatchInitControlUI.h +254 -0
- cyfaust/resources/architecture/faust/gui/DecoratorUI.h +115 -0
- cyfaust/resources/architecture/faust/gui/Esp32ControlUI.h +341 -0
- cyfaust/resources/architecture/faust/gui/Esp32Reader.h +102 -0
- cyfaust/resources/architecture/faust/gui/Esp32SensorUI.h +137 -0
- cyfaust/resources/architecture/faust/gui/FUI.h +147 -0
- cyfaust/resources/architecture/faust/gui/GTKUI.h +1414 -0
- cyfaust/resources/architecture/faust/gui/GUI.h +465 -0
- cyfaust/resources/architecture/faust/gui/JSONControl.h +48 -0
- cyfaust/resources/architecture/faust/gui/JSONUI.h +722 -0
- cyfaust/resources/architecture/faust/gui/JSONUIDecoder.h +589 -0
- cyfaust/resources/architecture/faust/gui/JuceGUI.h +2061 -0
- cyfaust/resources/architecture/faust/gui/JuceOSCUI.h +163 -0
- cyfaust/resources/architecture/faust/gui/JuceParameterUI.h +158 -0
- cyfaust/resources/architecture/faust/gui/JuceReader.h +103 -0
- cyfaust/resources/architecture/faust/gui/JuceStateUI.h +88 -0
- cyfaust/resources/architecture/faust/gui/LayoutUI.h +423 -0
- cyfaust/resources/architecture/faust/gui/LibsndfileReader.h +366 -0
- cyfaust/resources/architecture/faust/gui/MapUI.h +370 -0
- cyfaust/resources/architecture/faust/gui/MemoryReader.h +111 -0
- cyfaust/resources/architecture/faust/gui/MetaDataUI.h +357 -0
- cyfaust/resources/architecture/faust/gui/MidiUI.h +939 -0
- cyfaust/resources/architecture/faust/gui/OCVUI.h +688 -0
- cyfaust/resources/architecture/faust/gui/OSCUI.h +219 -0
- cyfaust/resources/architecture/faust/gui/PathBuilder.h +228 -0
- cyfaust/resources/architecture/faust/gui/PresetUI.h +337 -0
- cyfaust/resources/architecture/faust/gui/PrintCUI.h +152 -0
- cyfaust/resources/architecture/faust/gui/PrintUI.h +121 -0
- cyfaust/resources/architecture/faust/gui/QTUI.h +1891 -0
- cyfaust/resources/architecture/faust/gui/RosCI.h +493 -0
- cyfaust/resources/architecture/faust/gui/RosUI.h +488 -0
- cyfaust/resources/architecture/faust/gui/SaveUI.h +163 -0
- cyfaust/resources/architecture/faust/gui/SimpleParser.h +583 -0
- cyfaust/resources/architecture/faust/gui/SoundUI.h +217 -0
- cyfaust/resources/architecture/faust/gui/Soundfile.h +342 -0
- cyfaust/resources/architecture/faust/gui/Styles/Blue.qrc +5 -0
- cyfaust/resources/architecture/faust/gui/Styles/Blue.qss +177 -0
- cyfaust/resources/architecture/faust/gui/Styles/Default.qrc +5 -0
- cyfaust/resources/architecture/faust/gui/Styles/Default.qss +117 -0
- cyfaust/resources/architecture/faust/gui/Styles/Grey.qrc +5 -0
- cyfaust/resources/architecture/faust/gui/Styles/Grey.qss +174 -0
- cyfaust/resources/architecture/faust/gui/Styles/Salmon.qrc +5 -0
- cyfaust/resources/architecture/faust/gui/Styles/Salmon.qss +171 -0
- cyfaust/resources/architecture/faust/gui/UI.h +87 -0
- cyfaust/resources/architecture/faust/gui/ValueConverter.h +543 -0
- cyfaust/resources/architecture/faust/gui/WaveReader.h +364 -0
- cyfaust/resources/architecture/faust/gui/console.h +322 -0
- cyfaust/resources/architecture/faust/gui/httpdUI.h +372 -0
- cyfaust/resources/architecture/faust/gui/meta.h +39 -0
- cyfaust/resources/architecture/faust/gui/mspUI.h +580 -0
- cyfaust/resources/architecture/faust/gui/qrcodegen.h +269 -0
- cyfaust/resources/architecture/faust/gui/qrcodegen.impl.h +1025 -0
- cyfaust/resources/architecture/faust/gui/ring-buffer.h +414 -0
- cyfaust/resources/architecture/faust/midi/RtMidi.cpp +3054 -0
- cyfaust/resources/architecture/faust/midi/RtMidi.h +1034 -0
- cyfaust/resources/architecture/faust/midi/bela-midi.h +266 -0
- cyfaust/resources/architecture/faust/midi/daisy-midi.h +116 -0
- cyfaust/resources/architecture/faust/midi/esp32-midi.h +185 -0
- cyfaust/resources/architecture/faust/midi/gramophone-midi.h +107 -0
- cyfaust/resources/architecture/faust/midi/iplug2-midi.h +148 -0
- cyfaust/resources/architecture/faust/midi/jack-midi.h +247 -0
- cyfaust/resources/architecture/faust/midi/juce-midi.h +275 -0
- cyfaust/resources/architecture/faust/midi/midi.h +475 -0
- cyfaust/resources/architecture/faust/midi/rt-midi.h +315 -0
- cyfaust/resources/architecture/faust/midi/teensy-midi.h +89 -0
- cyfaust/resources/architecture/faust/misc.h +106 -0
- cyfaust/resources/architecture/faust/sound-file.h +132 -0
- cyfaust/resources/architecture/faust/unity/AudioPluginInterface.h +301 -0
- cyfaust/resources/architecture/faust/vst/faust.h +141 -0
- cyfaust/resources/architecture/faust/vst/voice.h +43 -0
- cyfaust/resources/architecture/faust/vst/vstui.h +524 -0
- cyfaust/resources/architecture/faustvst.cpp +3435 -0
- cyfaust/resources/architecture/faustvstqt.h +91 -0
- cyfaust/resources/architecture/gen-json.cpp +76 -0
- cyfaust/resources/architecture/jack-console.cpp +267 -0
- cyfaust/resources/architecture/jack-gtk-ros.cpp +139 -0
- cyfaust/resources/architecture/jack-gtk.cpp +282 -0
- cyfaust/resources/architecture/jack-internal.cpp +560 -0
- cyfaust/resources/architecture/jack-qt-chain-footer.cpp +87 -0
- cyfaust/resources/architecture/jack-qt-chain-header.cpp +92 -0
- cyfaust/resources/architecture/jack-qt.cpp +281 -0
- cyfaust/resources/architecture/jack.rs +171 -0
- cyfaust/resources/architecture/juce/README.md +84 -0
- cyfaust/resources/architecture/juce/juce-plugin.cpp +809 -0
- cyfaust/resources/architecture/juce/juce-standalone.cpp +413 -0
- cyfaust/resources/architecture/juce/plugin/plugin-llvm.jucer +184 -0
- cyfaust/resources/architecture/juce/plugin/plugin.jucer +159 -0
- cyfaust/resources/architecture/juce/standalone/standalone-llvm.jucer +216 -0
- cyfaust/resources/architecture/juce/standalone/standalone.jucer +191 -0
- cyfaust/resources/architecture/ladspa.cpp +543 -0
- cyfaust/resources/architecture/latexheader.tex +65 -0
- cyfaust/resources/architecture/lv2.cpp +2090 -0
- cyfaust/resources/architecture/lv2qtgui.h +62 -0
- cyfaust/resources/architecture/lv2ui.cpp +1966 -0
- cyfaust/resources/architecture/max-msp/README.md +109 -0
- cyfaust/resources/architecture/max-msp/faustgen-wrapper-poly.maxpat +184 -0
- cyfaust/resources/architecture/max-msp/faustgen-wrapper.maxpat +163 -0
- cyfaust/resources/architecture/max-msp/max-msp.cpp +734 -0
- cyfaust/resources/architecture/max-msp/max-msp64.cpp +789 -0
- cyfaust/resources/architecture/max-msp/py2max/README.md +277 -0
- cyfaust/resources/architecture/max-msp/py2max/py2max/__init__.py +3 -0
- cyfaust/resources/architecture/max-msp/py2max/py2max/common.py +7 -0
- cyfaust/resources/architecture/max-msp/py2max/py2max/core.py +1387 -0
- cyfaust/resources/architecture/max-msp/py2max/py2max/maxclassdb.py +318 -0
- cyfaust/resources/architecture/max-msp/py2max/py2max/utils.py +20 -0
- cyfaust/resources/architecture/max-msp/rnbo.py +1591 -0
- cyfaust/resources/architecture/max-msp/sndfile/sndfile.h +857 -0
- cyfaust/resources/architecture/max-msp/ui.js +230 -0
- cyfaust/resources/architecture/max-msp/wrapper-poly.maxpat +153 -0
- cyfaust/resources/architecture/max-msp/wrapper.maxpat +131 -0
- cyfaust/resources/architecture/minimal-bench.cpp +100 -0
- cyfaust/resources/architecture/minimal-effect.c +149 -0
- cyfaust/resources/architecture/minimal-effect.cpp +70 -0
- cyfaust/resources/architecture/minimal-fixed-point.cpp +195 -0
- cyfaust/resources/architecture/minimal-static.cpp +160 -0
- cyfaust/resources/architecture/minimal.c +103 -0
- cyfaust/resources/architecture/minimal.cpp +84 -0
- cyfaust/resources/architecture/minimal.rs +223 -0
- cyfaust/resources/architecture/module.cpp +91 -0
- cyfaust/resources/architecture/octave.cpp +471 -0
- cyfaust/resources/architecture/oscio-gtk.cpp +115 -0
- cyfaust/resources/architecture/oscio-qt.cpp +121 -0
- cyfaust/resources/architecture/owl.cpp +345 -0
- cyfaust/resources/architecture/pa-gtk.cpp +119 -0
- cyfaust/resources/architecture/pa-qt.cpp +261 -0
- cyfaust/resources/architecture/path-printer.cpp +100 -0
- cyfaust/resources/architecture/plot.cpp +128 -0
- cyfaust/resources/architecture/portaudio.rs +192 -0
- cyfaust/resources/architecture/puredata.cpp +636 -0
- cyfaust/resources/architecture/ra-qt.cpp +238 -0
- cyfaust/resources/architecture/sam/fast_pow2.h +69 -0
- cyfaust/resources/architecture/sam/fastexp.h +140 -0
- cyfaust/resources/architecture/sam/samFaustDSP.cpp +125 -0
- cyfaust/resources/architecture/sam/samFaustDSP.h +107 -0
- cyfaust/resources/architecture/scheduler.cpp +1391 -0
- cyfaust/resources/architecture/sndfile.cpp +291 -0
- cyfaust/resources/architecture/supercollider.cpp +611 -0
- cyfaust/resources/architecture/teensy/README.md +13 -0
- cyfaust/resources/architecture/teensy/teensy.cpp +214 -0
- cyfaust/resources/architecture/teensy/teensy.h +71 -0
- cyfaust/resources/architecture/thread.h +373 -0
- cyfaust/resources/architecture/vcvrack/README.md +78 -0
- cyfaust/resources/architecture/vcvrack/template/.gitignore +6 -0
- cyfaust/resources/architecture/vcvrack/template/Makefile +22 -0
- cyfaust/resources/architecture/vcvrack/template/res/FaustModule.svg +299 -0
- cyfaust/resources/architecture/vcvrack/template/src/FaustModule.cpp +942 -0
- cyfaust/resources/architecture/vst.cpp +947 -0
- cyfaust/resources/libraries/aanl.lib +900 -0
- cyfaust/resources/libraries/all.lib +36 -0
- cyfaust/resources/libraries/analyzers.lib +980 -0
- cyfaust/resources/libraries/basics.lib +2681 -0
- cyfaust/resources/libraries/compressors.lib +1341 -0
- cyfaust/resources/libraries/delays.lib +401 -0
- cyfaust/resources/libraries/demos.lib +1556 -0
- cyfaust/resources/libraries/dx7.lib +1036 -0
- cyfaust/resources/libraries/effect.lib +1645 -0
- cyfaust/resources/libraries/envelopes.lib +666 -0
- cyfaust/resources/libraries/examples/README.md +13 -0
- cyfaust/resources/libraries/examples/ambisonics/fourSourcesToOcto.dsp +20 -0
- cyfaust/resources/libraries/examples/ambisonics/oneSourceToStereo.dsp +12 -0
- cyfaust/resources/libraries/examples/analysis/FFT.dsp +26 -0
- cyfaust/resources/libraries/examples/analysis/dbmeter.dsp +19 -0
- cyfaust/resources/libraries/examples/analysis/spectralLevel.dsp +8 -0
- cyfaust/resources/libraries/examples/analysis/spectralTiltLab.dsp +20 -0
- cyfaust/resources/libraries/examples/analysis/vumeter.dsp +18 -0
- cyfaust/resources/libraries/examples/autodiff/delay/diff.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/delay/gt.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/gain/diff.dsp +7 -0
- cyfaust/resources/libraries/examples/autodiff/gain/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/gain_dc/diff.dsp +7 -0
- cyfaust/resources/libraries/examples/autodiff/gain_dc/gt.dsp +4 -0
- cyfaust/resources/libraries/examples/autodiff/gain_exp/diff.dsp +9 -0
- cyfaust/resources/libraries/examples/autodiff/gain_exp/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/gain_pow/diff.dsp +9 -0
- cyfaust/resources/libraries/examples/autodiff/gain_pow/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/gain_pow_trig/diff.dsp +12 -0
- cyfaust/resources/libraries/examples/autodiff/gain_pow_trig/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/gain_sq/diff.dsp +7 -0
- cyfaust/resources/libraries/examples/autodiff/gain_sq/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/mem/diff.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/mem/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/noise.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/noop.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/one_zero/diff.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/one_zero/gt.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/ramp.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/recursion/diff.dsp +2 -0
- cyfaust/resources/libraries/examples/autodiff/recursion/gt.dsp +1 -0
- cyfaust/resources/libraries/examples/autodiff/recursion/target.dsp +13 -0
- cyfaust/resources/libraries/examples/autodiff/tremolo/diff.dsp +14 -0
- cyfaust/resources/libraries/examples/autodiff/tremolo/diffable.lib +7 -0
- cyfaust/resources/libraries/examples/autodiff/tremolo/gt.dsp +11 -0
- cyfaust/resources/libraries/examples/delayEcho/echo.dsp +15 -0
- cyfaust/resources/libraries/examples/delayEcho/quadEcho.dsp +21 -0
- cyfaust/resources/libraries/examples/delayEcho/smoothDelay.dsp +26 -0
- cyfaust/resources/libraries/examples/delayEcho/stereoEcho.dsp +16 -0
- cyfaust/resources/libraries/examples/delayEcho/tapiir.dsp +44 -0
- cyfaust/resources/libraries/examples/dynamic/compressor.dsp +8 -0
- cyfaust/resources/libraries/examples/dynamic/distortion.dsp +8 -0
- cyfaust/resources/libraries/examples/dynamic/gateCompressor.dsp +10 -0
- cyfaust/resources/libraries/examples/dynamic/noiseGate.dsp +8 -0
- cyfaust/resources/libraries/examples/dynamic/volume.dsp +15 -0
- cyfaust/resources/libraries/examples/filtering/APF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/BPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/DNN.dsp +25 -0
- cyfaust/resources/libraries/examples/filtering/HPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/LPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/bandFilter.dsp +44 -0
- cyfaust/resources/libraries/examples/filtering/cryBaby.dsp +4 -0
- cyfaust/resources/libraries/examples/filtering/diodeLadder.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/filterBank.dsp +6 -0
- cyfaust/resources/libraries/examples/filtering/graphicEqLab.dsp +10 -0
- cyfaust/resources/libraries/examples/filtering/highShelf.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/korg35HPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/korg35LPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/lfBoost.dsp +40 -0
- cyfaust/resources/libraries/examples/filtering/lowBoost.dsp +40 -0
- cyfaust/resources/libraries/examples/filtering/lowCut.dsp +40 -0
- cyfaust/resources/libraries/examples/filtering/lowShelf.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/moogHalfLadder.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/moogLadder.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/moogVCF.dsp +6 -0
- cyfaust/resources/libraries/examples/filtering/multibandFilter.dsp +14 -0
- cyfaust/resources/libraries/examples/filtering/notch.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/oberheim.dsp +14 -0
- cyfaust/resources/libraries/examples/filtering/oberheimBPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/oberheimBSF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/oberheimHPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/oberheimLPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/parametricEqLab.dsp +10 -0
- cyfaust/resources/libraries/examples/filtering/parametricEqualizer.dsp +6 -0
- cyfaust/resources/libraries/examples/filtering/peakNotch.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/peakingEQ.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/sallenKey2ndOrder.dsp +14 -0
- cyfaust/resources/libraries/examples/filtering/sallenKey2ndOrderBPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/sallenKey2ndOrderHPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/sallenKey2ndOrderLPF.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/sallenKeyOnePole.dsp +13 -0
- cyfaust/resources/libraries/examples/filtering/sallenKeyOnePoleHPF.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/sallenKeyOnePoleLPF.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/spectralTilt.dsp +8 -0
- cyfaust/resources/libraries/examples/filtering/vcfWahLab.dsp +12 -0
- cyfaust/resources/libraries/examples/filtering/vocoder.dsp +8 -0
- cyfaust/resources/libraries/examples/filtering/wahPedal.dsp +6 -0
- cyfaust/resources/libraries/examples/gameaudio/bubble.dsp +42 -0
- cyfaust/resources/libraries/examples/gameaudio/door.dsp +58 -0
- cyfaust/resources/libraries/examples/gameaudio/fire.dsp +46 -0
- cyfaust/resources/libraries/examples/gameaudio/insects.dsp +148 -0
- cyfaust/resources/libraries/examples/gameaudio/rain.dsp +27 -0
- cyfaust/resources/libraries/examples/gameaudio/wind.dsp +23 -0
- cyfaust/resources/libraries/examples/generator/filterOsc.dsp +8 -0
- cyfaust/resources/libraries/examples/generator/noise.dsp +52 -0
- cyfaust/resources/libraries/examples/generator/noiseMetadata.dsp +74 -0
- cyfaust/resources/libraries/examples/generator/osc.dsp +17 -0
- cyfaust/resources/libraries/examples/generator/osci.dsp +17 -0
- cyfaust/resources/libraries/examples/generator/sawtoothLab.dsp +8 -0
- cyfaust/resources/libraries/examples/generator/virtualAnalog.dsp +8 -0
- cyfaust/resources/libraries/examples/generator/virtualAnalogLab.dsp +10 -0
- cyfaust/resources/libraries/examples/misc/UITester.dsp +71 -0
- cyfaust/resources/libraries/examples/misc/autopan.dsp +59 -0
- cyfaust/resources/libraries/examples/misc/capture.dsp +24 -0
- cyfaust/resources/libraries/examples/misc/drumkit.dsp +36 -0
- cyfaust/resources/libraries/examples/misc/guitarix.dsp +184 -0
- cyfaust/resources/libraries/examples/misc/matrix.dsp +17 -0
- cyfaust/resources/libraries/examples/misc/midiTester.dsp +122 -0
- cyfaust/resources/libraries/examples/misc/mixer.dsp +27 -0
- cyfaust/resources/libraries/examples/misc/statespace.dsp +39 -0
- cyfaust/resources/libraries/examples/misc/switcher.dsp +20 -0
- cyfaust/resources/libraries/examples/misc/tester.dsp +32 -0
- cyfaust/resources/libraries/examples/misc/tester2.dsp +31 -0
- cyfaust/resources/libraries/examples/old/README.md +5 -0
- cyfaust/resources/libraries/examples/old/freeverb.dsp +109 -0
- cyfaust/resources/libraries/examples/old/rewriting/Makefile +21 -0
- cyfaust/resources/libraries/examples/old/rewriting/fact.dsp +3 -0
- cyfaust/resources/libraries/examples/old/rewriting/fold.dsp +61 -0
- cyfaust/resources/libraries/examples/old/rewriting/mesh.dsp +43 -0
- cyfaust/resources/libraries/examples/old/rewriting/mesh.pd +37 -0
- cyfaust/resources/libraries/examples/old/rewriting/sample.pd +12 -0
- cyfaust/resources/libraries/examples/old/rewriting/serial.dsp +7 -0
- cyfaust/resources/libraries/examples/old/rewriting/sum.dsp +55 -0
- cyfaust/resources/libraries/examples/old/rewriting/test.pd +48 -0
- cyfaust/resources/libraries/examples/phasing/flanger.dsp +8 -0
- cyfaust/resources/libraries/examples/phasing/phaser.dsp +8 -0
- cyfaust/resources/libraries/examples/phasing/phaserFlangerLab.dsp +12 -0
- cyfaust/resources/libraries/examples/physicalModeling/brass.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/brassMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/churchBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/clarinet.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/clarinetMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/djembeMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/elecGuitarMIDI.dsp +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/englishBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/NLFeks.dsp +91 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/NLFfm.dsp +70 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/README +125 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/bass.dsp +84 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/bass.h +91 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/blowBottle.dsp +102 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/bowed.dsp +114 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/brass.dsp +103 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/clarinet.dsp +110 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/flute.dsp +116 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/fluteStk.dsp +121 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/glassHarmonica.dsp +131 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/harpsi.dsp +90 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/harpsichord.h +185 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/instrument.h +114 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/modalBar.dsp +122 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/modalBar.h +48 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/bottle.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/clarinets.pd +15 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/canon/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/canon/bass.pd +162 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/canon/canon.pd +55 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/canon/flute.pd +343 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/canon/pachelbel.mid +0 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/daisy/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/daisy/daisy.mid +0 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/daisy/daisy.pd +45 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/daisy/piano.pd +205 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/daisy/voiceForm.pd +340 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/take5/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/take5/blowHole.pd +330 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/take5/piano.pd +205 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/take5/take5.mid +0 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/take5/take5.pd +45 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/turkish-march/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/turkish-march/harpsi.pd +204 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/turkish-march/turkish-march.mid +0 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/turkish-march/turkish-march.pd +31 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/audio-out.pd +33 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/bass.pd +162 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/modalBar.pd +258 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/piano.pd +205 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/what-a-friend.pd +52 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fancy/what-a-friend/what_a_friend.mid +0 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/flutes.pd +15 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/fm.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/glassBare.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/harpsichord-poly.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/ironBare.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/midi-in.pd +111 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/modal.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/osc.pd +26 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/piano-poly.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/plucked.pd +20 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/saxophone.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/tibetan.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/trumpet.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/violin.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/voiceSynth.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/pd-patches/woodenBare.pd +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/phonemes.h +189 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/piano.dsp +255 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/piano.h +751 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/saxophony.dsp +114 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/sitar.dsp +48 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/tibetanBowl.dsp +155 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/tunedBar.dsp +123 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/uniBar.dsp +100 -0
- cyfaust/resources/libraries/examples/physicalModeling/faust-stk/voiceForm.dsp +125 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/1dDampedWaveEquation.dsp +43 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/2dKirchhoffThinPlate.dsp +75 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/BowedString.dsp +61 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/ControllableNonPhysicalString.dsp +72 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/HammeredString.dsp +74 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/PianoHammeredString.dsp +85 -0
- cyfaust/resources/libraries/examples/physicalModeling/fds/StiffString.dsp +54 -0
- cyfaust/resources/libraries/examples/physicalModeling/flute.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/fluteMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/frenchBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/germanBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/guitarMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/karplus.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/marimbaMIDI.dsp +10 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/00_BasicOscillator/harmonicOscillator.dsp +58 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/00_BasicOscillator/harmonicOscillator2.dsp +62 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/00_BasicOscillator/harmonicOscillator3.dsp +65 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/01_ParamControl/paramOsc.dsp +63 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/02_AudioParamControl/audioParamOsc.dsp +63 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/03_HammerTime/hammerOsc.dsp +71 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/04_Gravity/bouncingOsc.dsp +64 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/05_PluckedOscillator/pluckedOsc.dsp +57 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/06_BowedOscillator/bowedOsc.dsp +65 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/07_NonLinearOscillator/nlOsc.dsp +78 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/08_TwoMassChain/2massChain.dsp +75 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/09_TinyString/tinyString.dsp +101 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/10_PluckedString/pluckedString.dsp +678 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/11_BowedString/bowedString.dsp +671 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/12_TriangleMesh/triangleMesh.dsp +448 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/13_Construction/construction.dsp +1036 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/14_Polyphonic/polyTriangle.dsp +79 -0
- cyfaust/resources/libraries/examples/physicalModeling/mi-faust/15_PhysicalLFO/physicalLFO.dsp +107 -0
- cyfaust/resources/libraries/examples/physicalModeling/modularInterpInstrMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/nylonGuitarMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/old/harpe.dsp +45 -0
- cyfaust/resources/libraries/examples/physicalModeling/old/karplus.dsp +34 -0
- cyfaust/resources/libraries/examples/physicalModeling/old/karplus32.dsp +47 -0
- cyfaust/resources/libraries/examples/physicalModeling/russianBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/standardBell.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/violin.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/violinMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/vocalBP.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/vocalBPMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/vocalFOF.dsp +8 -0
- cyfaust/resources/libraries/examples/physicalModeling/vocalFOFMIDI.dsp +8 -0
- cyfaust/resources/libraries/examples/pitchShifting/pitchShifter.dsp +20 -0
- cyfaust/resources/libraries/examples/psychoacoustic/harmonicExciter.dsp +10 -0
- cyfaust/resources/libraries/examples/quantizing/quantizedChords.dsp +49 -0
- cyfaust/resources/libraries/examples/reverb/dattorro.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/fdnRev.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/freeverb.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/greyhole.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/jprev.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/reverbDesigner.dsp +12 -0
- cyfaust/resources/libraries/examples/reverb/reverbTester.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/zitaRev.dsp +8 -0
- cyfaust/resources/libraries/examples/reverb/zitaRevFDN.dsp +8 -0
- cyfaust/resources/libraries/examples/smartKeyboard/acGuitar.dsp +100 -0
- cyfaust/resources/libraries/examples/smartKeyboard/associatedEffects/elecGuitarEffect.dsp +8 -0
- cyfaust/resources/libraries/examples/smartKeyboard/associatedEffects/myEffect.dsp +5 -0
- cyfaust/resources/libraries/examples/smartKeyboard/associatedEffects/reverb.dsp +5 -0
- cyfaust/resources/libraries/examples/smartKeyboard/bells.dsp +80 -0
- cyfaust/resources/libraries/examples/smartKeyboard/bowed.dsp +87 -0
- cyfaust/resources/libraries/examples/smartKeyboard/brass.dsp +82 -0
- cyfaust/resources/libraries/examples/smartKeyboard/clarinet.dsp +113 -0
- cyfaust/resources/libraries/examples/smartKeyboard/crazyGuiro.dsp +96 -0
- cyfaust/resources/libraries/examples/smartKeyboard/drums.dsp +74 -0
- cyfaust/resources/libraries/examples/smartKeyboard/dubDub.dsp +87 -0
- cyfaust/resources/libraries/examples/smartKeyboard/elecGuitar.dsp +67 -0
- cyfaust/resources/libraries/examples/smartKeyboard/fm.dsp +78 -0
- cyfaust/resources/libraries/examples/smartKeyboard/frog.dsp +74 -0
- cyfaust/resources/libraries/examples/smartKeyboard/harp.dsp +84 -0
- cyfaust/resources/libraries/examples/smartKeyboard/midiOnly.dsp +62 -0
- cyfaust/resources/libraries/examples/smartKeyboard/multiSynth.dsp +75 -0
- cyfaust/resources/libraries/examples/smartKeyboard/toy.dsp +71 -0
- cyfaust/resources/libraries/examples/smartKeyboard/trumpet.dsp +59 -0
- cyfaust/resources/libraries/examples/smartKeyboard/turenas.dsp +114 -0
- cyfaust/resources/libraries/examples/smartKeyboard/violin.dsp +91 -0
- cyfaust/resources/libraries/examples/smartKeyboard/violin2.dsp +84 -0
- cyfaust/resources/libraries/examples/smartKeyboard/vocal.dsp +43 -0
- cyfaust/resources/libraries/examples/spat/panpot.dsp +17 -0
- cyfaust/resources/libraries/examples/spat/spat.dsp +25 -0
- cyfaust/resources/libraries/fds.lib +535 -0
- cyfaust/resources/libraries/filter.lib +1710 -0
- cyfaust/resources/libraries/filters.lib +3125 -0
- cyfaust/resources/libraries/hoa.lib +1081 -0
- cyfaust/resources/libraries/instruments.lib +263 -0
- cyfaust/resources/libraries/interpolators.lib +675 -0
- cyfaust/resources/libraries/math.lib +602 -0
- cyfaust/resources/libraries/maths.lib +798 -0
- cyfaust/resources/libraries/maxmsp.lib +237 -0
- cyfaust/resources/libraries/mi.lib +528 -0
- cyfaust/resources/libraries/misceffects.lib +998 -0
- cyfaust/resources/libraries/music.lib +496 -0
- cyfaust/resources/libraries/noises.lib +487 -0
- cyfaust/resources/libraries/oscillator.lib +450 -0
- cyfaust/resources/libraries/oscillators.lib +1838 -0
- cyfaust/resources/libraries/phaflangers.lib +235 -0
- cyfaust/resources/libraries/physmodels.lib +3990 -0
- cyfaust/resources/libraries/platform.lib +59 -0
- cyfaust/resources/libraries/quantizers.lib +310 -0
- cyfaust/resources/libraries/reducemaps.lib +235 -0
- cyfaust/resources/libraries/reverbs.lib +686 -0
- cyfaust/resources/libraries/routes.lib +262 -0
- cyfaust/resources/libraries/sf.lib +53 -0
- cyfaust/resources/libraries/signals.lib +570 -0
- cyfaust/resources/libraries/soundfiles.lib +234 -0
- cyfaust/resources/libraries/spats.lib +173 -0
- cyfaust/resources/libraries/stdfaust.lib +38 -0
- cyfaust/resources/libraries/synths.lib +322 -0
- cyfaust/resources/libraries/tonestacks.lib +427 -0
- cyfaust/resources/libraries/tubes.lib +5039 -0
- cyfaust/resources/libraries/vaeffects.lib +984 -0
- cyfaust/resources/libraries/version.lib +22 -0
- cyfaust/resources/libraries/wdmodels.lib +2276 -0
- cyfaust/resources/libraries/webaudio.lib +402 -0
- cyfaust/signal.pxd +44 -0
- cyfaust/signal.pyx +1993 -0
- cyfaust-0.1.0.dist-info/METADATA +355 -0
- cyfaust-0.1.0.dist-info/RECORD +693 -0
- cyfaust-0.1.0.dist-info/WHEEL +5 -0
- cyfaust-0.1.0.dist-info/entry_points.txt +3 -0
- cyfaust-0.1.0.dist-info/licenses/LICENSE +26 -0
|
@@ -0,0 +1,1556 @@
|
|
|
1
|
+
//#################################### demos.lib ##########################################
|
|
2
|
+
// This library contains a set of demo functions based on examples located in the
|
|
3
|
+
// `/examples` folder. Its official prefix is `dm`.
|
|
4
|
+
//
|
|
5
|
+
// #### References
|
|
6
|
+
// * <https://github.com/grame-cncm/faustlibraries/blob/master/demos.lib>
|
|
7
|
+
//########################################################################################
|
|
8
|
+
|
|
9
|
+
/************************************************************************
|
|
10
|
+
************************************************************************
|
|
11
|
+
FAUST library file, GRAME section
|
|
12
|
+
|
|
13
|
+
Except where noted otherwise, Copyright (C) 2003-2017 by GRAME,
|
|
14
|
+
Centre National de Creation Musicale.
|
|
15
|
+
----------------------------------------------------------------------
|
|
16
|
+
GRAME LICENSE
|
|
17
|
+
|
|
18
|
+
This program is free software; you can redistribute it and/or modify
|
|
19
|
+
it under the terms of the GNU Lesser General Public License as
|
|
20
|
+
published by the Free Software Foundation; either version 2.1 of the
|
|
21
|
+
License, or (at your option) any later version.
|
|
22
|
+
|
|
23
|
+
This program is distributed in the hope that it will be useful,
|
|
24
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
25
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
26
|
+
GNU Lesser General Public License for more details.
|
|
27
|
+
|
|
28
|
+
You should have received a copy of the GNU Lesser General Public
|
|
29
|
+
License along with the GNU C Library; if not, write to the Free
|
|
30
|
+
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|
31
|
+
02111-1307 USA.
|
|
32
|
+
|
|
33
|
+
EXCEPTION TO THE LGPL LICENSE : As a special exception, you may create a
|
|
34
|
+
larger FAUST program which directly or indirectly imports this library
|
|
35
|
+
file and still distribute the compiled code generated by the FAUST
|
|
36
|
+
compiler, or a modified version of this compiled code, under your own
|
|
37
|
+
copyright and license. This EXCEPTION TO THE LGPL LICENSE explicitly
|
|
38
|
+
grants you the right to freely choose the license for the resulting
|
|
39
|
+
compiled code. In particular the resulting compiled code has no obligation
|
|
40
|
+
to be LGPL or GPL. For example you are free to choose a commercial or
|
|
41
|
+
closed source license or any other license if you decide so.
|
|
42
|
+
************************************************************************
|
|
43
|
+
************************************************************************/
|
|
44
|
+
|
|
45
|
+
ma = library("maths.lib");
|
|
46
|
+
ba = library("basics.lib");
|
|
47
|
+
de = library("delays.lib");
|
|
48
|
+
si = library("signals.lib");
|
|
49
|
+
an = library("analyzers.lib");
|
|
50
|
+
fi = library("filters.lib");
|
|
51
|
+
os = library("oscillators.lib");
|
|
52
|
+
no = library("noises.lib");
|
|
53
|
+
ef = library("misceffects.lib");
|
|
54
|
+
co = library("compressors.lib");
|
|
55
|
+
ve = library("vaeffects.lib");
|
|
56
|
+
pf = library("phaflangers.lib");
|
|
57
|
+
re = library("reverbs.lib");
|
|
58
|
+
en = library("envelopes.lib");
|
|
59
|
+
|
|
60
|
+
declare name "Faust Demos Library";
|
|
61
|
+
declare version "1.1.0";
|
|
62
|
+
|
|
63
|
+
//########################################################################################
|
|
64
|
+
/************************************************************************
|
|
65
|
+
FAUST library file, jos section
|
|
66
|
+
|
|
67
|
+
Except where noted otherwise, The Faust functions below in this
|
|
68
|
+
section are Copyright (C) 2003-2019 by Julius O. Smith III <jos@ccrma.stanford.edu>
|
|
69
|
+
([jos](http://ccrma.stanford.edu/~jos/)), and released under the
|
|
70
|
+
(MIT-style) [STK-4.3](#stk-4.3-license) license.
|
|
71
|
+
|
|
72
|
+
MarkDown comments in this section are Copyright 2016-2019 by Romain
|
|
73
|
+
Michon and Julius O. Smith III, and are released under the
|
|
74
|
+
[CCA4I](https://creativecommons.org/licenses/by/4.0/) license (TODO: if/when Romain agrees!)
|
|
75
|
+
|
|
76
|
+
************************************************************************/
|
|
77
|
+
|
|
78
|
+
//====================================Analyzers===========================================
|
|
79
|
+
//========================================================================================
|
|
80
|
+
|
|
81
|
+
//----------------------`(dm.)mth_octave_spectral_level_demo`----------------------
|
|
82
|
+
// Demonstrate mth_octave_spectral_level in a standalone GUI.
|
|
83
|
+
//
|
|
84
|
+
// #### Usage
|
|
85
|
+
// ```
|
|
86
|
+
// _ : mth_octave_spectral_level_demo(BandsPerOctave) : _
|
|
87
|
+
// _ : spectral_level_demo : _ // 2/3 octave
|
|
88
|
+
// ```
|
|
89
|
+
//------------------------------------------------------------
|
|
90
|
+
declare mth_octave_spectral_level_demo author "Julius O. Smith III and Yann Orlarey";
|
|
91
|
+
declare mth_octave_spectral_level_demo licence "MIT";
|
|
92
|
+
|
|
93
|
+
mth_octave_spectral_level_demo(BPO) = an.mth_octave_spectral_level_default(M,ftop,N,tau,dB_offset)
|
|
94
|
+
with{
|
|
95
|
+
M = BPO;
|
|
96
|
+
ftop = 16000;
|
|
97
|
+
Noct = 10; // number of octaves down from ftop
|
|
98
|
+
// Lowest band-edge is at ftop*2^(-Noct+2) = 62.5 Hz when ftop=16 kHz:
|
|
99
|
+
N = int(Noct*M); // without 'int()', segmentation fault observed for M=1.67
|
|
100
|
+
ctl_group(x) = hgroup("[1] SPECTRUM ANALYZER CONTROLS", x);
|
|
101
|
+
tau = ctl_group(hslider("[0] Level Averaging Time [unit:ms] [scale:log]
|
|
102
|
+
[tooltip: band-level averaging time in milliseconds]",
|
|
103
|
+
100,1,10000,1)) * 0.001;
|
|
104
|
+
dB_offset = ctl_group(hslider("[1] Level dB Offset [unit:dB]
|
|
105
|
+
[tooltip: Level offset in decibels]",
|
|
106
|
+
50,-50,100,1));
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
spectral_level_demo = mth_octave_spectral_level_demo(1.5); // 2/3 octave
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
//======================================Filters===========================================
|
|
113
|
+
//========================================================================================
|
|
114
|
+
|
|
115
|
+
//--------------------------`(dm.)parametric_eq_demo`------------------------------
|
|
116
|
+
// A parametric equalizer application.
|
|
117
|
+
//
|
|
118
|
+
// #### Usage:
|
|
119
|
+
//
|
|
120
|
+
// ```
|
|
121
|
+
// _ : parametric_eq_demo : _
|
|
122
|
+
// ```
|
|
123
|
+
//------------------------------------------------------------
|
|
124
|
+
declare parametric_eq_demo author "Julius O. Smith III";
|
|
125
|
+
declare parametric_eq_demo licence "MIT";
|
|
126
|
+
|
|
127
|
+
parametric_eq_demo = fi.low_shelf(LL,FL) : fi.peak_eq(LP,FP,BP) : fi.high_shelf(LH,FH)
|
|
128
|
+
with{
|
|
129
|
+
eq_group(x) = hgroup("[0] PARAMETRIC EQ SECTIONS [tooltip: See Faust's filters.lib
|
|
130
|
+
for info and pointers]",x);
|
|
131
|
+
ls_group(x) = eq_group(vgroup("[1] Low Shelf",x));
|
|
132
|
+
|
|
133
|
+
LL = ls_group(hslider("[0] Low Boost|Cut [unit:dB] [style:knob]
|
|
134
|
+
[tooltip: Amount of low-frequency boost or cut in decibels]",0,-40,40,0.1));
|
|
135
|
+
FL = ls_group(hslider("[1] Transition Frequency [unit:Hz] [style:knob] [scale:log]
|
|
136
|
+
[tooltip: Transition-frequency from boost (cut) to unity gain]",200,1,5000,1));
|
|
137
|
+
|
|
138
|
+
pq_group(x) = eq_group(vgroup("[2] Peaking Equalizer[tooltip: Parametric Equalizer
|
|
139
|
+
sections from filters.lib]",x));
|
|
140
|
+
LP = pq_group(hslider("[0] Peak Boost|Cut [unit:dB] [style:knob][tooltip: Amount of
|
|
141
|
+
local boost or cut in decibels]",0,-40,40,0.1));
|
|
142
|
+
FP = pq_group(hslider("[1] Peak Frequency [unit:PK] [style:knob] [tooltip: Peak
|
|
143
|
+
Frequency in Piano Key (PK) units (A440 = 49PK)]",49,1,100,1)) : si.smooth(0.999)
|
|
144
|
+
: ba.pianokey2hz;
|
|
145
|
+
Q = pq_group(hslider("[2] Peak Q [style:knob] [scale:log] [tooltip: Quality factor
|
|
146
|
+
(Q) of the peak = center-frequency/bandwidth]",40,1,1000,0.1));
|
|
147
|
+
|
|
148
|
+
BP = FP/Q;
|
|
149
|
+
|
|
150
|
+
hs_group(x) = eq_group(vgroup("[3] High Shelf [tooltip: A high shelf provides a boost
|
|
151
|
+
or cut above some frequency]",x));
|
|
152
|
+
LH = hs_group(hslider("[0] High Boost|Cut [unit:dB] [style:knob] [tooltip: Amount of
|
|
153
|
+
high-frequency boost or cut in decibels]",0,-40,40,.1));
|
|
154
|
+
FH = hs_group(hslider("[1] Transition Frequency [unit:Hz] [style:knob] [scale:log]
|
|
155
|
+
[tooltip: Transition-frequency from boost (cut) to unity gain]",8000,20,10000,1));
|
|
156
|
+
};
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
//-------------------`(dm.)spectral_tilt_demo`-----------------------
|
|
160
|
+
// A spectral tilt application.
|
|
161
|
+
//
|
|
162
|
+
// #### Usage
|
|
163
|
+
//
|
|
164
|
+
// ```
|
|
165
|
+
// _ : spectral_tilt_demo(N) : _
|
|
166
|
+
// ```
|
|
167
|
+
//
|
|
168
|
+
// Where:
|
|
169
|
+
//
|
|
170
|
+
// * `N`: filter order (integer)
|
|
171
|
+
//
|
|
172
|
+
// All other parameters interactive
|
|
173
|
+
//------------------------------------------------------------
|
|
174
|
+
declare spectral_tilt_demo author "Julius O. Smith III";
|
|
175
|
+
declare spectral_tilt_demo licence "MIT";
|
|
176
|
+
|
|
177
|
+
spectral_tilt_demo(N) = fi.spectral_tilt(O,f0,bw,alpha)
|
|
178
|
+
with{
|
|
179
|
+
O = N;
|
|
180
|
+
alpha = hslider("[1] Slope of Spectral Tilt across Band",-1/2,-1,1,0.001);
|
|
181
|
+
f0 = hslider("[2] Band Start Frequency [unit:Hz]",100,20,10000,1);
|
|
182
|
+
bw = hslider("[3] Band Width [unit:Hz]",5000,100,10000,1);
|
|
183
|
+
};
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
//---------`(dm.)mth_octave_filterbank_demo` and `(dm.)filterbank_demo`-------------
|
|
187
|
+
// Graphic Equalizer: each filter-bank output signal routes through a fader.
|
|
188
|
+
//
|
|
189
|
+
// #### Usage
|
|
190
|
+
//
|
|
191
|
+
// ```
|
|
192
|
+
// _ : mth_octave_filterbank_demo(M) : _
|
|
193
|
+
// _ : filterbank_demo : _
|
|
194
|
+
// ```
|
|
195
|
+
//
|
|
196
|
+
// Where:
|
|
197
|
+
//
|
|
198
|
+
// * `M`: number of bands per octave
|
|
199
|
+
//--------------------------------------------------------------
|
|
200
|
+
declare mth_octave_filterbank_demo author "Julius O. Smith III";
|
|
201
|
+
declare mth_octave_filterbank_demo licence "MIT";
|
|
202
|
+
|
|
203
|
+
mth_octave_filterbank_demo(O) = bp1(bp,mthoctavefilterbankdemo)
|
|
204
|
+
with{
|
|
205
|
+
M = O;
|
|
206
|
+
bp1 = ba.bypass1;
|
|
207
|
+
mofb_group(x) = vgroup("CONSTANT-Q FILTER BANK (Butterworth dyadic tree)
|
|
208
|
+
[tooltip: See Faust's filters.lib for documentation and references]", x);
|
|
209
|
+
bypass_group(x) = mofb_group(hgroup("[0]", x));
|
|
210
|
+
slider_group(x) = mofb_group(hgroup("[1]", x));
|
|
211
|
+
|
|
212
|
+
N = 10*M; // total number of bands (highpass band, octave-bands, dc band)
|
|
213
|
+
ftop = 10000;
|
|
214
|
+
mthoctavefilterbankdemo = chan;
|
|
215
|
+
chan = fi.mth_octave_filterbank_default(M,ftop,N) : sum(i,N,(*(ba.db2linear(fader(N-i)))));
|
|
216
|
+
fader(i) = slider_group(vslider("Band%2i [unit:dB] [tooltip: Bandpass filter
|
|
217
|
+
gain in dB]", -10, -70, 10, 0.1)) : si.smoo;
|
|
218
|
+
bp = bypass_group(checkbox("[0] Bypass
|
|
219
|
+
[tooltip: When this is checked, the filter-bank has no effect]"));
|
|
220
|
+
};
|
|
221
|
+
|
|
222
|
+
filterbank_demo = mth_octave_filterbank_demo(1); // octave-bands = default
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
//======================================Effects===========================================
|
|
226
|
+
//========================================================================================
|
|
227
|
+
|
|
228
|
+
//---------------------------`(dm.)cubicnl_demo`--------------------------
|
|
229
|
+
// Distortion demo application.
|
|
230
|
+
//
|
|
231
|
+
// #### Usage:
|
|
232
|
+
//
|
|
233
|
+
// ```
|
|
234
|
+
// _ : cubicnl_demo : _
|
|
235
|
+
// ```
|
|
236
|
+
//------------------------------------------------------------
|
|
237
|
+
declare cubicnl_demo author "Julius O. Smith III";
|
|
238
|
+
declare cubicnl_demo licence "MIT";
|
|
239
|
+
|
|
240
|
+
cubicnl_demo = ba.bypass1(bp, ef.cubicnl_nodc(drive:si.smoo,offset:si.smoo))
|
|
241
|
+
with{
|
|
242
|
+
cnl_group(x) = vgroup("CUBIC NONLINEARITY cubicnl [tooltip: Reference:
|
|
243
|
+
https://ccrma.stanford.edu/~jos/pasp/Cubic_Soft_Clipper.html]", x);
|
|
244
|
+
bp = cnl_group(checkbox("[0] Bypass [tooltip: When this is checked, the
|
|
245
|
+
nonlinearity has no effect]"));
|
|
246
|
+
drive = cnl_group(hslider("[1] Drive [tooltip: Amount of distortion]",
|
|
247
|
+
0, 0, 1, 0.01));
|
|
248
|
+
offset = cnl_group(hslider("[2] Offset [tooltip: Brings in even harmonics]",
|
|
249
|
+
0, 0, 1, 0.01));
|
|
250
|
+
};
|
|
251
|
+
|
|
252
|
+
|
|
253
|
+
//----------------------------`(dm.)gate_demo`-------------------------
|
|
254
|
+
// Gate demo application.
|
|
255
|
+
//
|
|
256
|
+
// #### Usage
|
|
257
|
+
//
|
|
258
|
+
// ```
|
|
259
|
+
// _,_ : gate_demo : _,_
|
|
260
|
+
// ```
|
|
261
|
+
//------------------------------------------------------------
|
|
262
|
+
declare gate_demo author "Julius O. Smith III";
|
|
263
|
+
declare gate_demo licence "MIT";
|
|
264
|
+
|
|
265
|
+
gate_demo = ba.bypass2(gbp,gate_stereo_demo)
|
|
266
|
+
with{
|
|
267
|
+
gate_group(x) = vgroup("GATE [tooltip: Reference:
|
|
268
|
+
http://en.wikipedia.org/wiki/Noise_gate]", x);
|
|
269
|
+
meter_group(x) = gate_group(hgroup("[0]", x));
|
|
270
|
+
knob_group(x) = gate_group(hgroup("[1]", x));
|
|
271
|
+
|
|
272
|
+
gbp = meter_group(checkbox("[0] Bypass [tooltip: When this is checked,
|
|
273
|
+
the gate has no effect]"));
|
|
274
|
+
|
|
275
|
+
gateview = ef.gate_gain_mono(gatethr,gateatt,gatehold,gaterel) : ba.linear2db :
|
|
276
|
+
meter_group(hbargraph("[1] Gate Gain [unit:dB] [tooltip: Current gain of the
|
|
277
|
+
gate in dB]", -50,+10)); // [style:led]
|
|
278
|
+
|
|
279
|
+
gate_stereo_demo(x,y) = attach(x,gateview(abs(x)+abs(y))),y :
|
|
280
|
+
ef.gate_stereo(gatethr,gateatt,gatehold,gaterel);
|
|
281
|
+
|
|
282
|
+
gatethr = knob_group(hslider("[1] Threshold [unit:dB] [style:knob] [tooltip: When
|
|
283
|
+
the signal level falls below the Threshold (expressed in dB), the signal is
|
|
284
|
+
muted]", -30, -120, 0, 0.1));
|
|
285
|
+
|
|
286
|
+
gateatt = knob_group(hslider("[2] Attack [unit:us] [style:knob] [scale:log]
|
|
287
|
+
[tooltip: Time constant in MICROseconds (1/e smoothing time) for the gate
|
|
288
|
+
gain to go (exponentially) from 0 (muted) to 1 (unmuted)]",
|
|
289
|
+
10, 10, 10000, 1)) : *(0.000001) : max(1.0/float(ma.SR));
|
|
290
|
+
|
|
291
|
+
gatehold = knob_group(hslider("[3] Hold [unit:ms] [style:knob] [scale:log]
|
|
292
|
+
[tooltip: Time in ms to keep the gate open (no muting) after the signal
|
|
293
|
+
level falls below the Threshold]", 200, 1, 1000, 1)) : *(0.001) :
|
|
294
|
+
max(1.0/float(ma.SR));
|
|
295
|
+
|
|
296
|
+
gaterel = knob_group(hslider("[4] Release [unit:ms] [style:knob] [scale:log]
|
|
297
|
+
[tooltip: Time constant in ms (1/e smoothing time) for the gain to go
|
|
298
|
+
(exponentially) from 1 (unmuted) to 0 (muted)]",
|
|
299
|
+
100, 1, 1000, 1)) : *(0.001) : max(1.0/float(ma.SR));
|
|
300
|
+
};
|
|
301
|
+
|
|
302
|
+
|
|
303
|
+
//----------------------------`(dm.)compressor_demo`-------------------------
|
|
304
|
+
// Compressor demo application.
|
|
305
|
+
//
|
|
306
|
+
// #### Usage
|
|
307
|
+
//
|
|
308
|
+
// ```
|
|
309
|
+
// _,_ : compressor_demo : _,_
|
|
310
|
+
// ```
|
|
311
|
+
//------------------------------------------------------------
|
|
312
|
+
declare compressor_demo author "Julius O. Smith III";
|
|
313
|
+
declare compressor_demo licence "MIT";
|
|
314
|
+
|
|
315
|
+
compressor_demo = ba.bypass2(cbp,compressor_stereo_demo)
|
|
316
|
+
with{
|
|
317
|
+
comp_group(x) = vgroup("COMPRESSOR [tooltip: Reference:
|
|
318
|
+
http://en.wikipedia.org/wiki/Dynamic_range_compression]", x);
|
|
319
|
+
|
|
320
|
+
meter_group(x) = comp_group(hgroup("[0]", x));
|
|
321
|
+
knob_group(x) = comp_group(hgroup("[1]", x));
|
|
322
|
+
|
|
323
|
+
cbp = meter_group(checkbox("[0] Bypass [tooltip: When this is checked, the compressor
|
|
324
|
+
has no effect]"));
|
|
325
|
+
gainview = co.compression_gain_mono(ratio,threshold,attack,release) : ba.linear2db :
|
|
326
|
+
meter_group(hbargraph("[1] Compressor Gain [unit:dB] [tooltip: Current gain of
|
|
327
|
+
the compressor in dB]",-50,+10));
|
|
328
|
+
|
|
329
|
+
displaygain = _,_ <: _,_,(abs,abs:+) : _,_,gainview : _,attach;
|
|
330
|
+
|
|
331
|
+
compressor_stereo_demo =
|
|
332
|
+
displaygain(co.compressor_stereo(ratio,threshold,attack,release)) :
|
|
333
|
+
*(makeupgain), *(makeupgain);
|
|
334
|
+
|
|
335
|
+
ctl_group(x) = knob_group(hgroup("[3] Compression Control", x));
|
|
336
|
+
|
|
337
|
+
ratio = ctl_group(hslider("[0] Ratio [style:knob]
|
|
338
|
+
[tooltip: A compression Ratio of N means that for each N dB increase in input
|
|
339
|
+
signal level above Threshold, the output level goes up 1 dB]",
|
|
340
|
+
5, 1, 20, 0.1));
|
|
341
|
+
|
|
342
|
+
threshold = ctl_group(hslider("[1] Threshold [unit:dB] [style:knob]
|
|
343
|
+
[tooltip: When the signal level exceeds the Threshold (in dB), its level
|
|
344
|
+
is compressed according to the Ratio]",
|
|
345
|
+
-30, -100, 10, 0.1));
|
|
346
|
+
|
|
347
|
+
env_group(x) = knob_group(hgroup("[4] Compression Response", x));
|
|
348
|
+
|
|
349
|
+
attack = env_group(hslider("[1] Attack [unit:ms] [style:knob] [scale:log]
|
|
350
|
+
[tooltip: Time constant in ms (1/e smoothing time) for the compression gain
|
|
351
|
+
to approach (exponentially) a new lower target level (the compression
|
|
352
|
+
`kicking in')]", 50, 1, 1000, 0.1)) : *(0.001) : max(1/ma.SR);
|
|
353
|
+
|
|
354
|
+
release = env_group(hslider("[2] Release [unit:ms] [style: knob] [scale:log]
|
|
355
|
+
[tooltip: Time constant in ms (1/e smoothing time) for the compression gain
|
|
356
|
+
to approach (exponentially) a new higher target level (the compression
|
|
357
|
+
'releasing')]", 500, 1, 1000, 0.1)) : *(0.001) : max(1/ma.SR);
|
|
358
|
+
|
|
359
|
+
makeupgain = comp_group(hslider("[5] Makeup Gain [unit:dB]
|
|
360
|
+
[tooltip: The compressed-signal output level is increased by this amount
|
|
361
|
+
(in dB) to make up for the level lost due to compression]",
|
|
362
|
+
40, -96, 96, 0.1)) : ba.db2linear;
|
|
363
|
+
};
|
|
364
|
+
|
|
365
|
+
|
|
366
|
+
//-------------------------`(dm.)moog_vcf_demo`---------------------------
|
|
367
|
+
// Illustrate and compare all three Moog VCF implementations above.
|
|
368
|
+
//
|
|
369
|
+
// #### Usage
|
|
370
|
+
//
|
|
371
|
+
// ```
|
|
372
|
+
// _ : moog_vcf_demo : _
|
|
373
|
+
// ```
|
|
374
|
+
//------------------------------------------------------------
|
|
375
|
+
declare moog_vcf_demo author "Julius O. Smith III";
|
|
376
|
+
declare moog_vcf_demo licence "MIT";
|
|
377
|
+
|
|
378
|
+
moog_vcf_demo = ba.bypass1(bp,vcf)
|
|
379
|
+
with{
|
|
380
|
+
mvcf_group(x) = hgroup("MOOG VCF (Voltage Controlled Filter) [tooltip: See Faust's
|
|
381
|
+
vaeffects.lib for info and references]",x);
|
|
382
|
+
cb_group(x) = mvcf_group(hgroup("[0]",x));
|
|
383
|
+
|
|
384
|
+
bp = cb_group(checkbox("[0] Bypass [tooltip: When this is checked, the Moog VCF
|
|
385
|
+
has no effect]"));
|
|
386
|
+
archsw = cb_group(checkbox("[1] Use Biquads [tooltip: Select moog_vcf_2b (two-biquad)
|
|
387
|
+
implementation, instead of the default moog_vcf (analog style) implementation]"));
|
|
388
|
+
bqsw = cb_group(checkbox("[2] Normalized Ladders [tooltip: If using biquads, make
|
|
389
|
+
them normalized ladders (moog_vcf_2bn)]"));
|
|
390
|
+
|
|
391
|
+
freq = mvcf_group(hslider("[1] Corner Frequency [unit:PK] [tooltip: The VCF resonates
|
|
392
|
+
at the corner frequency (specified in PianoKey (PK) units, with A440 = 49 PK).
|
|
393
|
+
The VCF response is flat below the corner frequency, and rolls off -24 dB per
|
|
394
|
+
octave above.]",
|
|
395
|
+
25, 1, 88, 0.01) : ba.pianokey2hz) : si.smoo;
|
|
396
|
+
|
|
397
|
+
res = mvcf_group(hslider("[2] Corner Resonance [style:knob] [tooltip: Amount of
|
|
398
|
+
resonance near VCF corner frequency (specified between 0 and 1)]", 0.9, 0, 1, 0.01));
|
|
399
|
+
|
|
400
|
+
outgain = mvcf_group(hslider("[3] VCF Output Level [unit:dB] [style:knob] [tooltip:
|
|
401
|
+
output level in decibels]", 5, -60, 20, 0.1)) : ba.db2linear : si.smoo;
|
|
402
|
+
|
|
403
|
+
vcfbq = _ <: select2(bqsw, ve.moog_vcf_2b(res,freq), ve.moog_vcf_2bn(res,freq));
|
|
404
|
+
vcfarch = _ <: select2(archsw, ve.moog_vcf(res^4,freq), vcfbq);
|
|
405
|
+
vcf = vcfarch : *(outgain);
|
|
406
|
+
};
|
|
407
|
+
|
|
408
|
+
|
|
409
|
+
//-------------------------`(dm.)wah4_demo`---------------------------
|
|
410
|
+
// Wah pedal application.
|
|
411
|
+
//
|
|
412
|
+
// #### Usage
|
|
413
|
+
//
|
|
414
|
+
// ```
|
|
415
|
+
// _ : wah4_demo : _
|
|
416
|
+
// ```
|
|
417
|
+
//------------------------------------------------------------
|
|
418
|
+
declare wah4_demo author "Julius O. Smith III";
|
|
419
|
+
declare wah4_demo licence "MIT";
|
|
420
|
+
|
|
421
|
+
wah4_demo = ba.bypass1(bp, ve.wah4(fr))
|
|
422
|
+
with{
|
|
423
|
+
wah4_group(x) = hgroup("WAH4 [tooltip: Fourth-order wah effect made using moog_vcf]", x);
|
|
424
|
+
bp = wah4_group(checkbox("[0] Bypass [tooltip: When this is checked, the wah pedal has
|
|
425
|
+
no effect]"));
|
|
426
|
+
fr = wah4_group(hslider("[1] Resonance Frequency [scale:log] [tooltip: wah resonance
|
|
427
|
+
frequency in Hz]", 200,100,2000,1));
|
|
428
|
+
// Avoid dc with the moog_vcf (amplitude too high when freq comes up from dc)
|
|
429
|
+
// Also, avoid very high resonance frequencies (e.g., 5kHz or above).
|
|
430
|
+
};
|
|
431
|
+
|
|
432
|
+
//-------------------------`(dm.)crybaby_demo`---------------------------
|
|
433
|
+
// Crybaby effect application.
|
|
434
|
+
//
|
|
435
|
+
// #### Usage
|
|
436
|
+
//
|
|
437
|
+
// ```
|
|
438
|
+
// _ : crybaby_demo : _
|
|
439
|
+
// ```
|
|
440
|
+
//------------------------------------------------------------
|
|
441
|
+
declare crybaby_demo author "Julius O. Smith III";
|
|
442
|
+
declare crybaby_demo licence "MIT";
|
|
443
|
+
|
|
444
|
+
crybaby_demo = ba.bypass1(bp, ve.crybaby(wah))
|
|
445
|
+
with{
|
|
446
|
+
crybaby_group(x) = hgroup("CRYBABY [tooltip: Reference:
|
|
447
|
+
https://ccrma.stanford.edu/~jos/pasp/vegf.html]", x);
|
|
448
|
+
bp = crybaby_group(checkbox("[0] Bypass [tooltip: When this is checked, the wah
|
|
449
|
+
pedal has no effect]"));
|
|
450
|
+
wah = crybaby_group(hslider("[1] Wah parameter [tooltip: wah pedal angle between
|
|
451
|
+
0 (rocked back) and 1 (rocked forward)]",0.8,0,1,0.01));
|
|
452
|
+
};
|
|
453
|
+
|
|
454
|
+
//-------------------------`(dm.)flanger_demo`---------------------------
|
|
455
|
+
// Flanger effect application.
|
|
456
|
+
//
|
|
457
|
+
// #### Usage
|
|
458
|
+
//
|
|
459
|
+
// ```
|
|
460
|
+
// _,_ : flanger_demo : _,_
|
|
461
|
+
// ```
|
|
462
|
+
//------------------------------------------------------------
|
|
463
|
+
declare flanger_demo author "Julius O. Smith III";
|
|
464
|
+
declare flanger_demo licence "MIT";
|
|
465
|
+
|
|
466
|
+
flanger_demo = ba.bypass2(fbp,flanger_stereo_demo)
|
|
467
|
+
with{
|
|
468
|
+
flanger_group(x) = vgroup("FLANGER
|
|
469
|
+
[tooltip: Reference: https://ccrma.stanford.edu/~jos/pasp/Flanging.html]", x);
|
|
470
|
+
meter_group(x) = flanger_group(hgroup("[0]", x));
|
|
471
|
+
ctl_group(x) = flanger_group(hgroup("[1]", x));
|
|
472
|
+
del_group(x) = flanger_group(hgroup("[2] Delay Controls", x));
|
|
473
|
+
lvl_group(x) = flanger_group(hgroup("[3]", x));
|
|
474
|
+
|
|
475
|
+
fbp = meter_group(checkbox("[0] Bypass [tooltip: When this is checked, the flanger
|
|
476
|
+
has no effect]"));
|
|
477
|
+
invert = meter_group(checkbox("[1] Invert Flange Sum"));
|
|
478
|
+
|
|
479
|
+
// FIXME: This should be an amplitude-response display:
|
|
480
|
+
flangeview = lfor(freq) + lfol(freq) : meter_group(hbargraph("[2] Flange LFO
|
|
481
|
+
[style: led] [tooltip: Display sum of flange delays]", -1.5,+1.5));
|
|
482
|
+
|
|
483
|
+
flanger_stereo_demo(x,y) = attach(x,flangeview),y :
|
|
484
|
+
*(level),*(level) : pf.flanger_stereo(dmax,curdel1,curdel2,depth,fb,invert);
|
|
485
|
+
|
|
486
|
+
lfol = os.oscrs;
|
|
487
|
+
lfor = os.oscrc;
|
|
488
|
+
|
|
489
|
+
dmax = 2048;
|
|
490
|
+
dflange = 0.001 * ma.SR *
|
|
491
|
+
del_group(hslider("[1] Flange Delay [unit:ms] [style:knob]", 10, 0, 20, 0.001));
|
|
492
|
+
odflange = 0.001 * ma.SR *
|
|
493
|
+
del_group(hslider("[2] Delay Offset [unit:ms] [style:knob]", 1, 0, 20, 0.001));
|
|
494
|
+
freq = ctl_group(hslider("[1] Speed [unit:Hz] [style:knob]", 0.5, 0, 10, 0.01));
|
|
495
|
+
depth = ctl_group(hslider("[2] Depth [style:knob]", 1, 0, 1, 0.001));
|
|
496
|
+
fb = ctl_group(hslider("[3] Feedback [style:knob]", 0, -0.999, 0.999, 0.001));
|
|
497
|
+
level = lvl_group(hslider("Flanger Output Level [unit:dB]", 0, -60, 10, 0.1)) :
|
|
498
|
+
ba.db2linear;
|
|
499
|
+
curdel1 = odflange+dflange*(1 + lfol(freq))/2;
|
|
500
|
+
curdel2 = odflange+dflange*(1 + lfor(freq))/2;
|
|
501
|
+
};
|
|
502
|
+
|
|
503
|
+
|
|
504
|
+
//-------------------------`(dm.)phaser2_demo`---------------------------
|
|
505
|
+
// Phaser effect demo application.
|
|
506
|
+
//
|
|
507
|
+
// #### Usage
|
|
508
|
+
//
|
|
509
|
+
// ```
|
|
510
|
+
// _,_ : phaser2_demo : _,_
|
|
511
|
+
// ```
|
|
512
|
+
//------------------------------------------------------------
|
|
513
|
+
declare phaser2_demo author "Julius O. Smith III";
|
|
514
|
+
declare phaser2_demo licence "MIT";
|
|
515
|
+
|
|
516
|
+
phaser2_demo = ba.bypass2(pbp,phaser2_stereo_demo)
|
|
517
|
+
with{
|
|
518
|
+
phaser2_group(x) = vgroup("PHASER2 [tooltip: Reference:
|
|
519
|
+
https://ccrma.stanford.edu/~jos/pasp/Flanging.html]", x);
|
|
520
|
+
meter_group(x) = phaser2_group(hgroup("[0]", x));
|
|
521
|
+
ctl_group(x) = phaser2_group(hgroup("[1]", x));
|
|
522
|
+
nch_group(x) = phaser2_group(hgroup("[2]", x));
|
|
523
|
+
lvl_group(x) = phaser2_group(hgroup("[3]", x));
|
|
524
|
+
|
|
525
|
+
pbp = meter_group(checkbox("[0] Bypass [tooltip: When this is checked, the phaser
|
|
526
|
+
has no effect]"));
|
|
527
|
+
invert = meter_group(checkbox("[1] Invert Internal Phaser Sum"));
|
|
528
|
+
vibr = meter_group(checkbox("[2] Vibrato Mode")); // In this mode you can hear any "Doppler"
|
|
529
|
+
|
|
530
|
+
// FIXME: This should be an amplitude-response display:
|
|
531
|
+
// flangeview = phaser2_amp_resp : meter_group(hspectrumview("[2] Phaser Amplitude Response", 0,1));
|
|
532
|
+
// phaser2_stereo_demo(x,y) = attach(x,flangeview),y : ...
|
|
533
|
+
|
|
534
|
+
phaser2_stereo_demo = *(level),*(level) :
|
|
535
|
+
pf.phaser2_stereo(Notches,width,frqmin,fratio,frqmax,speed,mdepth,fb,invert);
|
|
536
|
+
|
|
537
|
+
Notches = 4; // Compile-time parameter: 2 is typical for analog phaser stomp-boxes
|
|
538
|
+
|
|
539
|
+
// FIXME: Add tooltips
|
|
540
|
+
speed = ctl_group(hslider("[1] Speed [unit:Hz] [style:knob]", 0.5, 0, 10, 0.001));
|
|
541
|
+
depth = ctl_group(hslider("[2] Notch Depth (Intensity) [style:knob]", 1, 0, 1, 0.001));
|
|
542
|
+
fb = ctl_group(hslider("[3] Feedback Gain [style:knob]", 0, -0.999, 0.999, 0.001));
|
|
543
|
+
|
|
544
|
+
width = nch_group(hslider("[1] Notch width [unit:Hz] [style:knob] [scale:log]",
|
|
545
|
+
1000, 10, 5000, 1));
|
|
546
|
+
frqmin = nch_group(hslider("[2] Min Notch1 Freq [unit:Hz] [style:knob] [scale:log]",
|
|
547
|
+
100, 20, 5000, 1));
|
|
548
|
+
frqmax = nch_group(hslider("[3] Max Notch1 Freq [unit:Hz] [style:knob] [scale:log]",
|
|
549
|
+
800, 20, 10000, 1)) : max(frqmin);
|
|
550
|
+
fratio = nch_group(hslider("[4] Notch Freq Ratio: NotchFreq(n+1)/NotchFreq(n) [style:knob]",
|
|
551
|
+
1.5, 1.1, 4, 0.001));
|
|
552
|
+
|
|
553
|
+
level = lvl_group(hslider("Phaser Output Level [unit:dB]", 0, -60, 10, 0.1)) :
|
|
554
|
+
ba.db2linear;
|
|
555
|
+
|
|
556
|
+
mdepth = select2(vibr,depth,2); // Improve "ease of use"
|
|
557
|
+
};
|
|
558
|
+
|
|
559
|
+
//======================================Reverbs===========================================
|
|
560
|
+
//========================================================================================
|
|
561
|
+
|
|
562
|
+
//----------------------------`(dm.)freeverb_demo`-------------------------
|
|
563
|
+
// Freeverb demo application.
|
|
564
|
+
//
|
|
565
|
+
// #### Usage
|
|
566
|
+
//
|
|
567
|
+
// ```
|
|
568
|
+
// _,_ : freeverb_demo : _,_
|
|
569
|
+
// ```
|
|
570
|
+
//------------------------------------------------------------
|
|
571
|
+
declare freeverb_demo author " Romain Michon";
|
|
572
|
+
declare freeverb_demo licence "LGPL";
|
|
573
|
+
|
|
574
|
+
freeverb_demo = _,_ <: (*(g)*fixedgain,*(g)*fixedgain :
|
|
575
|
+
re.stereo_freeverb(combfeed, allpassfeed, damping, spatSpread)),
|
|
576
|
+
*(1-g), *(1-g) :> _,_
|
|
577
|
+
with{
|
|
578
|
+
scaleroom = 0.28;
|
|
579
|
+
offsetroom = 0.7;
|
|
580
|
+
allpassfeed = 0.5;
|
|
581
|
+
scaledamp = 0.4;
|
|
582
|
+
fixedgain = 0.1;
|
|
583
|
+
origSR = 44100;
|
|
584
|
+
|
|
585
|
+
parameters(x) = hgroup("Freeverb",x);
|
|
586
|
+
knobGroup(x) = parameters(vgroup("[0]",x));
|
|
587
|
+
damping = knobGroup(vslider("[0] Damp [style: knob] [tooltip: Somehow control the
|
|
588
|
+
density of the reverb.]",0.5, 0, 1, 0.025)*scaledamp*origSR/ma.SR);
|
|
589
|
+
combfeed = knobGroup(vslider("[1] RoomSize [style: knob] [tooltip: The room size
|
|
590
|
+
between 0 and 1 with 1 for the largest room.]", 0.5, 0, 1, 0.025)*scaleroom*
|
|
591
|
+
origSR/ma.SR + offsetroom);
|
|
592
|
+
spatSpread = knobGroup(vslider("[2] Stereo Spread [style: knob] [tooltip: Spatial
|
|
593
|
+
spread between 0 and 1 with 1 for maximum spread.]",0.5,0,1,0.01)*46*ma.SR/origSR
|
|
594
|
+
: int);
|
|
595
|
+
g = parameters(vslider("[1] Wet [tooltip: The amount of reverb applied to the signal
|
|
596
|
+
between 0 and 1 with 1 for the maximum amount of reverb.]", 0.3333, 0, 1, 0.025));
|
|
597
|
+
};
|
|
598
|
+
|
|
599
|
+
//---------------------`(dm.)stereo_reverb_tester`--------------------
|
|
600
|
+
// Handy test inputs for reverberator demos below.
|
|
601
|
+
//
|
|
602
|
+
// #### Usage
|
|
603
|
+
//
|
|
604
|
+
// ```
|
|
605
|
+
// _ : stereo_reverb_tester : _
|
|
606
|
+
// ```
|
|
607
|
+
//------------------------------------------------------------
|
|
608
|
+
declare stereo_reverb_tester author "Julius O. Smith III";
|
|
609
|
+
declare stereo_reverb_tester licence "MIT";
|
|
610
|
+
|
|
611
|
+
stereo_reverb_tester(revin_group,x,y) = reverb_tester(_)
|
|
612
|
+
with {
|
|
613
|
+
reverb_tester(revin_group,x,y) = inx,iny with {
|
|
614
|
+
ck_group(x) = revin_group(vgroup("[1] Input Config",x));
|
|
615
|
+
mutegain = 1 - ck_group(checkbox("[1] Mute Ext Inputs
|
|
616
|
+
[tooltip: When this is checked, the stereo external audio inputs are
|
|
617
|
+
disabled (good for hearing the impulse response or pink-noise response alone)]"));
|
|
618
|
+
pinkin = ck_group(checkbox("[2] Pink Noise
|
|
619
|
+
[tooltip: Pink Noise (or 1/f noise) is Constant-Q Noise (useful for adjusting
|
|
620
|
+
the EQ sections)]"));
|
|
621
|
+
|
|
622
|
+
imp_group(x) = revin_group(hgroup("[2] Impulse Selection",x));
|
|
623
|
+
pulseL = imp_group(button("[1] Left
|
|
624
|
+
[tooltip: Send impulse into LEFT channel]")) : ba.impulsify;
|
|
625
|
+
pulseC = imp_group(button("[2] Center
|
|
626
|
+
[tooltip: Send impulse into LEFT and RIGHT channels]")) : ba.impulsify;
|
|
627
|
+
pulseR = imp_group(button("[3] Right
|
|
628
|
+
[tooltip: Send impulse into RIGHT channel]")) : ba.impulsify;
|
|
629
|
+
|
|
630
|
+
inx = x*mutegain + (pulseL+pulseC) + pn;
|
|
631
|
+
iny = y*mutegain + (pulseR+pulseC) + pn;
|
|
632
|
+
pn = 0.1*pinkin*no.pink_noise;
|
|
633
|
+
};
|
|
634
|
+
};
|
|
635
|
+
|
|
636
|
+
|
|
637
|
+
//-------------------------`(dm.)fdnrev0_demo`---------------------------
|
|
638
|
+
// A reverb application using `fdnrev0`.
|
|
639
|
+
//
|
|
640
|
+
// #### Usage
|
|
641
|
+
//
|
|
642
|
+
// ```
|
|
643
|
+
// _,_,_,_ : fdnrev0_demo(N,NB,BBSO) : _,_
|
|
644
|
+
// ```
|
|
645
|
+
//
|
|
646
|
+
// Where:
|
|
647
|
+
//
|
|
648
|
+
// * `N`: feedback Delay Network (FDN) order / number of delay lines used =
|
|
649
|
+
// order of feedback matrix / 2, 4, 8, or 16 [extend primes array below for
|
|
650
|
+
// 32, 64, ...]
|
|
651
|
+
// * `NB`: number of frequency bands / Number of (nearly) independent T60 controls
|
|
652
|
+
// / Integer 3 or greater
|
|
653
|
+
// * `BBSO` : butterworth band-split order / order of lowpass/highpass bandsplit
|
|
654
|
+
// used at each crossover freq / odd positive integer
|
|
655
|
+
//------------------------------------------------------------
|
|
656
|
+
declare fdnrev0_demo author "Julius O. Smith III";
|
|
657
|
+
declare fdnrev0_demo licence "MIT";
|
|
658
|
+
|
|
659
|
+
fdnrev0_demo(N,NB,BBSO) = stereo_reverb_tester(revin_group)
|
|
660
|
+
<: re.fdnrev0(MAXDELAY,delays,BBSO,freqs,durs,loopgainmax,nonl)
|
|
661
|
+
:> *(gain),*(gain)
|
|
662
|
+
with{
|
|
663
|
+
MAXDELAY = 8192; // sync w delays and prime_power_delays above
|
|
664
|
+
defdurs = (8.4,6.5,5.0,3.8,2.7); // NB default durations (sec)
|
|
665
|
+
deffreqs = (500,1000,2000,4000); // NB-1 default crossover frequencies (Hz)
|
|
666
|
+
deflens = (56.3,63.0); // 2 default min and max path lengths
|
|
667
|
+
|
|
668
|
+
fdn_group(x) = vgroup("FEEDBACK DELAY NETWORK (FDN) REVERBERATOR, ORDER 16
|
|
669
|
+
[tooltip: See Faust's reverbs.lib for documentation and references]", x);
|
|
670
|
+
|
|
671
|
+
freq_group(x) = fdn_group(vgroup("[1] Band Crossover Frequencies", x));
|
|
672
|
+
t60_group(x) = fdn_group(hgroup("[2] Band Decay Times (T60)", x));
|
|
673
|
+
path_group(x) = fdn_group(vgroup("[3] Room Dimensions", x));
|
|
674
|
+
revin_group(x) = fdn_group(hgroup("[4] Input Controls", x));
|
|
675
|
+
nonl_group(x) = revin_group(vgroup("[4] Nonlinearity",x));
|
|
676
|
+
quench_group(x) = revin_group(vgroup("[3] Reverb State",x));
|
|
677
|
+
|
|
678
|
+
nonl = nonl_group(hslider("[style:knob] [tooltip: nonlinear mode coupling]",
|
|
679
|
+
0, -0.999, 0.999, 0.001));
|
|
680
|
+
loopgainmax = 1.0-0.5*quench_group(button("[1] Quench
|
|
681
|
+
[tooltip: Hold down 'Quench' to clear the reverberator]"));
|
|
682
|
+
|
|
683
|
+
pathmin = path_group(hslider("[1] min acoustic ray length [unit:m] [scale:log]
|
|
684
|
+
[tooltip: This length (in meters) determines the shortest delay-line used in the FDN
|
|
685
|
+
reverberator. Think of it as the shortest wall-to-wall separation in the room.]",
|
|
686
|
+
46, 0.1, 63, 0.1));
|
|
687
|
+
pathmax = path_group(hslider("[2] max acoustic ray length [unit:m] [scale:log]
|
|
688
|
+
[tooltip: This length (in meters) determines the longest delay-line used in the
|
|
689
|
+
FDN reverberator. Think of it as the largest wall-to-wall separation in the room.]",
|
|
690
|
+
63, 0.1, 63, 0.1));
|
|
691
|
+
|
|
692
|
+
durvals(i) = t60_group(vslider("[%i] %i [unit:s] [scale:log][tooltip: T60 is the 60dB
|
|
693
|
+
decay-time in seconds. For concert halls, an overall reverberation time (T60) near
|
|
694
|
+
1.9 seconds is typical [Beranek 2004]. Here we may set T60 independently in each
|
|
695
|
+
frequency band. In real rooms, higher frequency bands generally decay faster due
|
|
696
|
+
to absorption and scattering.]",ba.take(i+1,defdurs), 0.1, 100, 0.1));
|
|
697
|
+
durs = par(i,NB,durvals(NB-1-i));
|
|
698
|
+
|
|
699
|
+
freqvals(i) = freq_group(hslider("[%i] Band %i upper edge in Hz [unit:Hz] [scale:log]
|
|
700
|
+
[tooltip: Each delay-line signal is split into frequency-bands for separate
|
|
701
|
+
decay-time control in each band]",ba.take(i+1,deffreqs), 100, 10000, 1));
|
|
702
|
+
freqs = par(i,NB-1,freqvals(i));
|
|
703
|
+
|
|
704
|
+
delays = de.prime_power_delays(N,pathmin,pathmax);
|
|
705
|
+
|
|
706
|
+
gain = hslider("[3] Output Level (dB) [unit:dB][tooltip: Output scale factor]",
|
|
707
|
+
-40, -70, 20, 0.1) : ba.db2linear;
|
|
708
|
+
// (can cause infinite loop:) with { db2linear(x) = pow(10, x/20.0); };
|
|
709
|
+
};
|
|
710
|
+
|
|
711
|
+
//---------------------------`(dm.)zita_rev_fdn_demo`------------------------------
|
|
712
|
+
// Reverb demo application based on `zita_rev_fdn`.
|
|
713
|
+
//
|
|
714
|
+
// #### Usage
|
|
715
|
+
//
|
|
716
|
+
// ```
|
|
717
|
+
// si.bus(8) : zita_rev_fdn_demo : si.bus(8)
|
|
718
|
+
// ```
|
|
719
|
+
//------------------------------------------------------------
|
|
720
|
+
declare zita_rev_fdn_demo author "Julius O. Smith III";
|
|
721
|
+
declare zita_rev_fdn_demo licence "MIT";
|
|
722
|
+
|
|
723
|
+
zita_rev_fdn_demo = re.zita_rev_fdn(f1,f2,t60dc,t60m,fsmax)
|
|
724
|
+
with{
|
|
725
|
+
fsmax = 48000.0;
|
|
726
|
+
fdn_group(x) = hgroup("Zita_Rev Internal FDN Reverb [tooltip: ~ Zita_Rev's internal
|
|
727
|
+
8x8 Feedback Delay Network (FDN) & Schroeder allpass-comb reverberator. See
|
|
728
|
+
Faust's reverbs.lib for documentation and references]",x);
|
|
729
|
+
t60dc = fdn_group(vslider("[1] Low RT60 [unit:s] [style:knob][style:knob]
|
|
730
|
+
[tooltip: T60 = time (in seconds) to decay 60dB in low-frequency band]",
|
|
731
|
+
3, 1, 8, 0.1));
|
|
732
|
+
f1 = fdn_group(vslider("[2] LF X [unit:Hz] [style:knob] [scale:log]
|
|
733
|
+
[tooltip: Crossover frequency (Hz) separating low and middle frequencies]",
|
|
734
|
+
200, 50, 1000, 1));
|
|
735
|
+
t60m = fdn_group(vslider("[3] Mid RT60 [unit:s] [style:knob] [scale:log]
|
|
736
|
+
[tooltip: T60 = time (in seconds) to decay 60dB in middle band]",
|
|
737
|
+
2, 1, 8, 0.1));
|
|
738
|
+
f2 = fdn_group(vslider("[4] HF Damping [unit:Hz] [style:knob] [scale:log]
|
|
739
|
+
[tooltip: Frequency (Hz) at which the high-frequency T60 is half the middle-band's T60]",
|
|
740
|
+
6000, 1500, 0.49*fsmax, 1));
|
|
741
|
+
};
|
|
742
|
+
|
|
743
|
+
//---------------------------`(dm.)zita_light`------------------------------
|
|
744
|
+
// Light version of `dm.zita_rev1` with only 2 UI elements.
|
|
745
|
+
//
|
|
746
|
+
// #### Usage
|
|
747
|
+
//
|
|
748
|
+
// ```
|
|
749
|
+
// _,_ : zita_light : _,_
|
|
750
|
+
// ```
|
|
751
|
+
//------------------------------------------------------------
|
|
752
|
+
declare zita_light author "Julius O. Smith III";
|
|
753
|
+
declare zita_light licence "MIT";
|
|
754
|
+
|
|
755
|
+
zita_light = hgroup("Zita Light",(_,_ <: re.zita_rev1_stereo(rdel,f1,f2,t60dc,t60m,fsmax),_,_ :
|
|
756
|
+
out_eq,_,_ : dry_wet : out_level))
|
|
757
|
+
with{
|
|
758
|
+
fsmax = 48000.0; // highest sampling rate that will be used
|
|
759
|
+
rdel = 60;
|
|
760
|
+
f1 = 200;
|
|
761
|
+
t60dc = 3;
|
|
762
|
+
t60m = 2;
|
|
763
|
+
f2 = 6000;
|
|
764
|
+
out_eq = pareq_stereo(eq1f,eq1l,eq1q) : pareq_stereo(eq2f,eq2l,eq2q);
|
|
765
|
+
pareq_stereo(eqf,eql,Q) = fi.peak_eq_rm(eql,eqf,tpbt), fi.peak_eq_rm(eql,eqf,tpbt)
|
|
766
|
+
with {
|
|
767
|
+
tpbt = wcT/sqrt(max(0,g)); // tan(PI*B/SR), B bw in Hz (Q^2 ~ g/4)
|
|
768
|
+
wcT = 2*ma.PI*eqf/ma.SR; // peak frequency in rad/sample
|
|
769
|
+
g = ba.db2linear(eql); // peak gain
|
|
770
|
+
};
|
|
771
|
+
eq1f = 315;
|
|
772
|
+
eq1l = 0;
|
|
773
|
+
eq1q = 3;
|
|
774
|
+
eq2f = 1500;
|
|
775
|
+
eq2l = 0;
|
|
776
|
+
eq2q = 3;
|
|
777
|
+
dry_wet(x,y) = *(wet) + dry*x, *(wet) + dry*y
|
|
778
|
+
with {
|
|
779
|
+
wet = 0.5*(drywet+1.0);
|
|
780
|
+
dry = 1.0-wet;
|
|
781
|
+
};
|
|
782
|
+
drywet = vslider("[1] Dry/Wet Mix [style:knob] [tooltip: -1 = dry, 1 = wet]",
|
|
783
|
+
0,-1.0,1.0,0.01) : si.smoo;
|
|
784
|
+
gain = vslider("[2] Level [unit:dB] [style:knob] [tooltip: Output scale
|
|
785
|
+
factor]", -6, -70, 40, 0.1) : ba.db2linear : si.smoo;
|
|
786
|
+
out_level = *(gain),*(gain);
|
|
787
|
+
};
|
|
788
|
+
|
|
789
|
+
//----------------------------------`(dm.)zita_rev1`------------------------------
|
|
790
|
+
// Example GUI for `zita_rev1_stereo` (mostly following the Linux `zita-rev1` GUI).
|
|
791
|
+
//
|
|
792
|
+
// Only the dry/wet and output level parameters are "dezippered" here. If
|
|
793
|
+
// parameters are to be varied in real time, use `smooth(0.999)` or the like
|
|
794
|
+
// in the same way.
|
|
795
|
+
//
|
|
796
|
+
// #### Usage
|
|
797
|
+
//
|
|
798
|
+
// ```
|
|
799
|
+
// _,_ : zita_rev1 : _,_
|
|
800
|
+
// ```
|
|
801
|
+
//
|
|
802
|
+
// #### Reference
|
|
803
|
+
//
|
|
804
|
+
// <http://www.kokkinizita.net/linuxaudio/zita-rev1-doc/quickguide.html>
|
|
805
|
+
//------------------------------------------------------------
|
|
806
|
+
declare zita_rev1 author "Julius O. Smith III";
|
|
807
|
+
declare zita_rev1 licence "MIT";
|
|
808
|
+
|
|
809
|
+
zita_rev1 = _,_ <: re.zita_rev1_stereo(rdel,f1,f2,t60dc,t60m,fsmax),_,_ : out_eq,_,_ :
|
|
810
|
+
dry_wet : out_level
|
|
811
|
+
with{
|
|
812
|
+
fsmax = 48000.0; // highest sampling rate that will be used
|
|
813
|
+
|
|
814
|
+
fdn_group(x) = hgroup(
|
|
815
|
+
"[0] Zita_Rev1 [tooltip: ~ ZITA REV1 FEEDBACK DELAY NETWORK (FDN) & SCHROEDER
|
|
816
|
+
ALLPASS-COMB REVERBERATOR (8x8). See Faust's reverbs.lib for documentation and
|
|
817
|
+
references]", x);
|
|
818
|
+
|
|
819
|
+
in_group(x) = fdn_group(hgroup("[1] Input", x));
|
|
820
|
+
|
|
821
|
+
rdel = in_group(vslider("[1] In Delay [unit:ms] [style:knob] [tooltip: Delay in ms
|
|
822
|
+
before reverberation begins]",60,20,100,1));
|
|
823
|
+
|
|
824
|
+
freq_group(x) = fdn_group(hgroup("[2] Decay Times in Bands (see tooltips)", x));
|
|
825
|
+
|
|
826
|
+
f1 = freq_group(vslider("[1] LF X [unit:Hz] [style:knob] [scale:log] [tooltip:
|
|
827
|
+
Crossover frequency (Hz) separating low and middle frequencies]", 200, 50, 1000, 1));
|
|
828
|
+
|
|
829
|
+
t60dc = freq_group(vslider("[2] Low RT60 [unit:s] [style:knob] [scale:log]
|
|
830
|
+
[style:knob] [tooltip: T60 = time (in seconds) to decay 60dB in low-frequency band]",
|
|
831
|
+
3, 1, 8, 0.1));
|
|
832
|
+
|
|
833
|
+
t60m = freq_group(vslider("[3] Mid RT60 [unit:s] [style:knob] [scale:log] [tooltip:
|
|
834
|
+
T60 = time (in seconds) to decay 60dB in middle band]",2, 1, 8, 0.1));
|
|
835
|
+
|
|
836
|
+
f2 = freq_group(vslider("[4] HF Damping [unit:Hz] [style:knob] [scale:log]
|
|
837
|
+
[tooltip: Frequency (Hz) at which the high-frequency T60 is half the middle-band's T60]",
|
|
838
|
+
6000, 1500, 0.49*fsmax, 1));
|
|
839
|
+
|
|
840
|
+
out_eq = pareq_stereo(eq1f,eq1l,eq1q) : pareq_stereo(eq2f,eq2l,eq2q);
|
|
841
|
+
// Zolzer style peaking eq (not used in zita-rev1) (filters.lib):
|
|
842
|
+
// pareq_stereo(eqf,eql,Q) = peak_eq(eql,eqf,eqf/Q), peak_eq(eql,eqf,eqf/Q);
|
|
843
|
+
// Regalia-Mitra peaking eq with "Q" hard-wired near sqrt(g)/2 (filters.lib):
|
|
844
|
+
pareq_stereo(eqf,eql,Q) = fi.peak_eq_rm(eql,eqf,tpbt), fi.peak_eq_rm(eql,eqf,tpbt)
|
|
845
|
+
with {
|
|
846
|
+
tpbt = wcT/sqrt(max(0,g)); // tan(PI*B/SR), B bw in Hz (Q^2 ~ g/4)
|
|
847
|
+
wcT = 2*ma.PI*eqf/ma.SR; // peak frequency in rad/sample
|
|
848
|
+
g = ba.db2linear(eql); // peak gain
|
|
849
|
+
};
|
|
850
|
+
|
|
851
|
+
eq1_group(x) = fdn_group(hgroup("[3] RM Peaking Equalizer 1", x));
|
|
852
|
+
|
|
853
|
+
eq1f = eq1_group(vslider("[1] Eq1 Freq [unit:Hz] [style:knob] [scale:log] [tooltip:
|
|
854
|
+
Center-frequency of second-order Regalia-Mitra peaking equalizer section 1]",
|
|
855
|
+
315, 40, 2500, 1));
|
|
856
|
+
|
|
857
|
+
eq1l = eq1_group(vslider("[2] Eq1 Level [unit:dB] [style:knob] [tooltip: Peak level
|
|
858
|
+
in dB of second-order Regalia-Mitra peaking equalizer section 1]", 0, -15, 15, 0.1));
|
|
859
|
+
|
|
860
|
+
eq1q = eq1_group(vslider("[3] Eq1 Q [style:knob] [tooltip: Q = centerFrequency/bandwidth
|
|
861
|
+
of second-order peaking equalizer section 1]", 3, 0.1, 10, 0.1));
|
|
862
|
+
|
|
863
|
+
eq2_group(x) = fdn_group(hgroup("[4] RM Peaking Equalizer 2", x));
|
|
864
|
+
|
|
865
|
+
eq2f = eq2_group(vslider("[1] Eq2 Freq [unit:Hz] [style:knob] [scale:log] [tooltip:
|
|
866
|
+
Center-frequency of second-order Regalia-Mitra peaking equalizer section 2]",
|
|
867
|
+
1500, 160, 10000, 1));
|
|
868
|
+
|
|
869
|
+
eq2l = eq2_group(vslider("[2] Eq2 Level [unit:dB] [style:knob] [tooltip: Peak level
|
|
870
|
+
in dB of second-order Regalia-Mitra peaking equalizer section 2]", 0, -15, 15, 0.1));
|
|
871
|
+
|
|
872
|
+
eq2q = eq2_group(vslider("[3] Eq2 Q [style:knob] [tooltip: Q = centerFrequency/bandwidth
|
|
873
|
+
of second-order peaking equalizer section 2]", 3, 0.1, 10, 0.1));
|
|
874
|
+
|
|
875
|
+
out_group(x) = fdn_group(hgroup("[5] Output", x));
|
|
876
|
+
|
|
877
|
+
dry_wet(x,y) = *(wet) + dry*x, *(wet) + dry*y with {
|
|
878
|
+
wet = 0.5*(drywet+1.0);
|
|
879
|
+
dry = 1.0-wet;
|
|
880
|
+
};
|
|
881
|
+
|
|
882
|
+
drywet = out_group(vslider("[1] Dry/Wet Mix [style:knob] [tooltip: -1 = dry, 1 = wet]",
|
|
883
|
+
0, -1.0, 1.0, 0.01)) : si.smoo;
|
|
884
|
+
|
|
885
|
+
out_level = *(gain),*(gain);
|
|
886
|
+
|
|
887
|
+
gain = out_group(vslider("[2] Level [unit:dB] [style:knob] [tooltip: Output scale
|
|
888
|
+
factor]", -20, -70, 40, 0.1)) : ba.db2linear : si.smoo;
|
|
889
|
+
};
|
|
890
|
+
|
|
891
|
+
//----------------------------------`(dm.)dattorro_rev_demo`------------------------------
|
|
892
|
+
// Example GUI for `dattorro_rev` with all parameters exposed. With additional
|
|
893
|
+
// dry/wet and output gain control.
|
|
894
|
+
//
|
|
895
|
+
// #### Usage
|
|
896
|
+
//
|
|
897
|
+
// ```
|
|
898
|
+
// _,_ : dattorro_rev_demo : _,_
|
|
899
|
+
// ```
|
|
900
|
+
//
|
|
901
|
+
//------------------------------------------------------------
|
|
902
|
+
declare dattorro_rev_demo author "Jakob Zerbian";
|
|
903
|
+
declare dattorro_rev_demo license "MIT-style STK-4.3 license";
|
|
904
|
+
|
|
905
|
+
dattorro_rev_demo = _,_ <: re.dattorro_rev(pre_delay, bw, i_diff1, i_diff2, decay, d_diff1, d_diff2, damping),_,_:
|
|
906
|
+
dry_wet : out_level
|
|
907
|
+
with {
|
|
908
|
+
rev_group(x) = hgroup("[0] Dattorro Reverb",x);
|
|
909
|
+
|
|
910
|
+
in_group(x) = rev_group(hgroup("[0] Input",x));
|
|
911
|
+
pre_delay = 0;
|
|
912
|
+
bw = in_group(vslider("[1] Prefilter [style:knob] [tooltip: lowpass-like filter, 0 = no signal, 1 = no filtering]",0.7,0.0,1.0,0.001) : si.smoo);
|
|
913
|
+
i_diff1 = in_group(vslider("[2] Diffusion 1 [style:knob] [tooltip: diffusion factor, influences reverb color and density]",0.625,0.0,1.0,0.001) : si.smoo);
|
|
914
|
+
i_diff2 = in_group(vslider("[3] Diffusion 2 [style:knob] [tooltip: diffusion factor, influences reverb color and density]",0.625,0.0,1.0,0.001) : si.smoo);
|
|
915
|
+
|
|
916
|
+
fdb_group(x) = rev_group(hgroup("[1] Feedback",x));
|
|
917
|
+
d_diff1 = fdb_group(vslider("[1] Diffusion 1 [style:knob] [tooltip: diffusion factor, influences reverb color and density]",0.625,0.0,1.0,0.001) : si.smoo);
|
|
918
|
+
d_diff2 = fdb_group(vslider("[2] Diffusion 2 [style:knob] [tooltip: diffusion factor, influences reverb color and density]",0.625,0.0,1.0,0.001) : si.smoo);
|
|
919
|
+
decay = fdb_group(vslider("[3] Decay Rate [style:knob] [tooltip: decay length, 1 = infinite]",0.7,0.0,1.0,0.001) : si.smoo);
|
|
920
|
+
damping = fdb_group(vslider("[4] Damping [style:knob] [tooltip: dampening in feedback network]",0.625,0.0,1.0,0.001) : si.smoo);
|
|
921
|
+
|
|
922
|
+
out_group(x) = rev_group(hgroup("[2] Output",x));
|
|
923
|
+
dry_wet(x,y) = *(dry) + wet*x, *(dry) + wet*y
|
|
924
|
+
with {
|
|
925
|
+
wet = 0.5*(drywet+1.0);
|
|
926
|
+
dry = 1.0-wet;
|
|
927
|
+
};
|
|
928
|
+
drywet = out_group(vslider("[1] Dry/Wet Mix [style:knob] [tooltip: -1 = dry, 1 = wet]",0,-1.0,1.0,0.01) : si.smoo);
|
|
929
|
+
gain = out_group(vslider("[2] Level [unit:dB] [style:knob] [tooltip: Output Gain]", -6, -70, 40, 0.1) : ba.db2linear : si.smoo);
|
|
930
|
+
out_level = *(gain),*(gain);
|
|
931
|
+
};
|
|
932
|
+
|
|
933
|
+
//----------------------------------`(dm.)jprev_demo`------------------------------
|
|
934
|
+
// Example GUI for `jprev` with all parameters exposed.
|
|
935
|
+
//
|
|
936
|
+
// #### Usage
|
|
937
|
+
//
|
|
938
|
+
// ```
|
|
939
|
+
// _,_ : jprev_demo : _,_
|
|
940
|
+
// ```
|
|
941
|
+
//
|
|
942
|
+
//------------------------------------------------------------
|
|
943
|
+
declare jprev_demo author "Till Bovermann";
|
|
944
|
+
declare jprev_demo license "GPL2+";
|
|
945
|
+
|
|
946
|
+
jprev_demo = re.jpverb(t60, damp, size, early_diff, mod_depth, mod_freq, low, mid, high, low_cutoff, high_cutoff)
|
|
947
|
+
with {
|
|
948
|
+
rev_group(x) = vgroup("[0] JPrev",x);
|
|
949
|
+
|
|
950
|
+
mix_group(x) = rev_group(hgroup("[0] Mix",x));
|
|
951
|
+
early_diff = mix_group(hslider("[1]earlyDiff [style:knob]", 0.707, 0, 0.990, 0.001));
|
|
952
|
+
size = mix_group(hslider("[2]size [style:knob]", 1, 0.5, 3, 0.01));
|
|
953
|
+
t60 = mix_group(hslider("[3]t60 [style:knob]", 1, 0.1, 60, 0.1));
|
|
954
|
+
damp = mix_group(hslider("[4]damp [style:knob]", 0, 0, 0.999, 0.0001));
|
|
955
|
+
|
|
956
|
+
eq_group(x) = rev_group(hgroup("[1] EQ",x));
|
|
957
|
+
low = eq_group(hslider("[07]lowX [style:knob]", 1, 0, 1, 0.01));
|
|
958
|
+
mid = eq_group(hslider("[08]midX [style:knob]", 1, 0, 1, 0.01));
|
|
959
|
+
high = eq_group(hslider("[09]highX [style:knob]", 1, 0, 1, 0.01));
|
|
960
|
+
low_cutoff = eq_group(hslider("[10]lowBand [style:knob]", 500, 100, 6000, 0.1));
|
|
961
|
+
high_cutoff = eq_group(hslider("[11]highBand [style:knob]", 2000, 1000, 10000, 0.1));
|
|
962
|
+
|
|
963
|
+
mod_group(x) = rev_group(hgroup("[2] Mod",x));
|
|
964
|
+
mod_depth = mod_group(hslider("[1]mDepth [style:knob]", 0.1, 0, 1, 0.001));
|
|
965
|
+
mod_freq = mod_group(hslider("[2]mFreq [style:knob]", 2, 0, 10, 0.010));
|
|
966
|
+
};
|
|
967
|
+
|
|
968
|
+
|
|
969
|
+
//----------------------------------`(dm.)greyhole_demo`------------------------------
|
|
970
|
+
// Example GUI for `greyhole` with all parameters exposed.
|
|
971
|
+
//
|
|
972
|
+
// #### Usage
|
|
973
|
+
//
|
|
974
|
+
// ```
|
|
975
|
+
// _,_ : greyhole_demo : _,_
|
|
976
|
+
// ```
|
|
977
|
+
//
|
|
978
|
+
//------------------------------------------------------------
|
|
979
|
+
declare greyhole_demo author "Till Bovermann";
|
|
980
|
+
declare greyhole_demo license "GPL2+";
|
|
981
|
+
|
|
982
|
+
greyhole_demo = re.greyhole(dt, damp, size, early_diff, feedback, mod_depth, mod_freq)
|
|
983
|
+
with {
|
|
984
|
+
|
|
985
|
+
rev_group(x) = vgroup("[0] Greyhole",x);
|
|
986
|
+
|
|
987
|
+
mix_group(x) = rev_group(hgroup("[0] Mix",x));
|
|
988
|
+
dt = mix_group(hslider("[01]delayTime [style:knob]", 0.2, 0.001, 1.45, 0.0001));
|
|
989
|
+
damp = mix_group(hslider("[02]damping [style:knob]", 0, 0, 0.99, 0.001));
|
|
990
|
+
size = mix_group(hslider("[03]size [style:knob]", 1, 0.5, 3, 0.0001));
|
|
991
|
+
early_diff = mix_group(hslider("[04]diffusion [style:knob]", 0.5, 0, 0.99, 0.0001));
|
|
992
|
+
feedback = mix_group(hslider("[05]feedback [style:knob]", 0.9, 0, 1, 0.01));
|
|
993
|
+
|
|
994
|
+
mod_group(x) = rev_group(hgroup("[1] Mod",x));
|
|
995
|
+
mod_depth = mod_group(hslider("[06]modDepth [style:knob]", 0.1, 0, 1, 0.001));
|
|
996
|
+
mod_freq = mod_group(hslider("[07]modFreq [style:knob]", 2, 0, 10, 0.01));
|
|
997
|
+
};
|
|
998
|
+
|
|
999
|
+
//====================================Generators==========================================
|
|
1000
|
+
//========================================================================================
|
|
1001
|
+
|
|
1002
|
+
//--------------------------`(dm.)sawtooth_demo`---------------------------
|
|
1003
|
+
// An application demonstrating the different sawtooth oscillators of Faust.
|
|
1004
|
+
//
|
|
1005
|
+
// #### Usage
|
|
1006
|
+
//
|
|
1007
|
+
// ```
|
|
1008
|
+
// sawtooth_demo : _
|
|
1009
|
+
// ```
|
|
1010
|
+
//------------------------------------------------------------
|
|
1011
|
+
declare sawtooth_demo author "Julius O. Smith III";
|
|
1012
|
+
declare sawtooth_demo licence "MIT";
|
|
1013
|
+
|
|
1014
|
+
sawtooth_demo = signal
|
|
1015
|
+
with{
|
|
1016
|
+
osc_group(x) = vgroup("[0] SAWTOOTH OSCILLATOR [tooltip: See Faust's oscillators.lib
|
|
1017
|
+
for documentation and references]",x);
|
|
1018
|
+
knob_group(x) = osc_group(hgroup("[1]", x));
|
|
1019
|
+
ampdb = knob_group(vslider("[1] Amplitude [unit:dB] [style:knob] [tooltip: Sawtooth
|
|
1020
|
+
waveform amplitude]",-20,-120,10,0.1));
|
|
1021
|
+
amp = ampdb : ba.db2linear : si.smoo;
|
|
1022
|
+
freq = knob_group(vslider("[2] Frequency [unit:PK] [style:knob] [tooltip: Sawtooth
|
|
1023
|
+
frequency as a Piano Key (PK) number (A440 = key 49)]",49,1,88,0.01) : ba.pianokey2hz);
|
|
1024
|
+
detune1 = 1 + 0.01 * knob_group(
|
|
1025
|
+
vslider("[3] Detuning 1 [unit:%%] [style:knob] [tooltip: Percentage frequency-shift
|
|
1026
|
+
up or down for second oscillator]",-0.1,-10,10,0.01));
|
|
1027
|
+
detune2 = 1 + 0.01 * knob_group(vslider("[4] Detuning 2 [unit:%%] [style:knob] [tooltip:
|
|
1028
|
+
Percentage frequency-shift up or down for third detuned oscillator]",+0.1,-10,10,0.01));
|
|
1029
|
+
portamento = knob_group(vslider("[5] Portamento [unit:sec] [style:knob] [scale:log]
|
|
1030
|
+
[tooltip: Portamento (frequency-glide) time-constant in seconds]",0.1,0.001,10,0.001));
|
|
1031
|
+
sfreq = freq : si.smooth(ba.tau2pole(portamento));
|
|
1032
|
+
saworder = knob_group(nentry("[6] Saw Order [tooltip: Order of sawtootn aliasing
|
|
1033
|
+
suppression]",2,1,os.MAX_SAW_ORDER,1));
|
|
1034
|
+
sawchoice = _ <: par(i,os.MAX_SAW_ORDER,os.sawN(i+1)) :
|
|
1035
|
+
ba.selectn(int(os.MAX_SAW_ORDER), int(saworder-1)); // when max is pwr of 2
|
|
1036
|
+
tone = (amp/3) * (sawchoice(sfreq) + sawchoice(sfreq*detune1) + sawchoice(sfreq*detune2));
|
|
1037
|
+
signal = amp * select2(ei, select2(ss, tone, white_or_pink_noise), _);
|
|
1038
|
+
white_or_pink_noise = select2(wp,no.noise,no.pink_noise);
|
|
1039
|
+
checkbox_group(x) = knob_group(vgroup("[7] Alternate Signals",x));
|
|
1040
|
+
ss = checkbox_group(checkbox("[0] Noise (White or Pink - uses only Amplitude control on
|
|
1041
|
+
the left)"));
|
|
1042
|
+
wp = checkbox_group(checkbox("[1] Pink instead of White Noise (also called 1/f Noise)
|
|
1043
|
+
[tooltip: Pink Noise (or 1/f noise) is Constant-Q Noise, meaning that it has the
|
|
1044
|
+
same total power in every octave]"));
|
|
1045
|
+
ei = checkbox_group(checkbox("[2] External Signal Input (overrides Sawtooth/Noise
|
|
1046
|
+
selection above)"));
|
|
1047
|
+
};
|
|
1048
|
+
|
|
1049
|
+
|
|
1050
|
+
//----------------------`(dm.)virtual_analog_oscillator_demo`----------------------
|
|
1051
|
+
// Virtual analog oscillator demo application.
|
|
1052
|
+
//
|
|
1053
|
+
// #### Usage
|
|
1054
|
+
//
|
|
1055
|
+
// ```
|
|
1056
|
+
// virtual_analog_oscillator_demo : _
|
|
1057
|
+
// ```
|
|
1058
|
+
//------------------------------------------------------------
|
|
1059
|
+
declare virtual_analog_oscillator_demo author "Julius O. Smith III";
|
|
1060
|
+
declare virtual_analog_oscillator_demo licence "MIT";
|
|
1061
|
+
|
|
1062
|
+
virtual_analog_oscillator_demo = signal
|
|
1063
|
+
with{
|
|
1064
|
+
osc_group(x) = vgroup("[0] VIRTUAL ANALOG OSCILLATORS
|
|
1065
|
+
[tooltip: See Faust's oscillators.lib for documentation and references]",x);
|
|
1066
|
+
|
|
1067
|
+
// Signals
|
|
1068
|
+
sawchoice = _ <:
|
|
1069
|
+
// When MAX_SAW_ORDER is a power of 2:
|
|
1070
|
+
par(i,os.MAX_SAW_ORDER,os.sawN(i+1)) : ba.selectn(int(os.MAX_SAW_ORDER), int(saworder-1));
|
|
1071
|
+
// When MAX_SAW_ORDER is NOT a power of 2:
|
|
1072
|
+
// (par(i,MAX_SAW_ORDER,sawN(i+1)), par(j,MAX_SAW_ORDER_NEXTPOW2-MAX_SAW_ORDER,_))
|
|
1073
|
+
// : selectn(MAX_SAW_ORDER_NEXTPOW2, saworder-1);
|
|
1074
|
+
saw = (amp/3) *
|
|
1075
|
+
(sawchoice(sfreq) + sawchoice(sfreq*detune1) + sawchoice(sfreq*detune2));
|
|
1076
|
+
sq = (amp/3) *
|
|
1077
|
+
(os.square(sfreq) + os.square(sfreq*detune1) + os.square(sfreq*detune2));
|
|
1078
|
+
tri = (amp/3) *
|
|
1079
|
+
(os.triangle(sfreq) + os.triangle(sfreq*detune1) + os.triangle(sfreq*detune2));
|
|
1080
|
+
pt = (amp/3) * (os.pulsetrain(sfreq,ptd)
|
|
1081
|
+
+ os.pulsetrain(sfreq*detune1,ptd)
|
|
1082
|
+
+ os.pulsetrain(sfreq*detune2,ptd));
|
|
1083
|
+
ptN = (amp/3) * (os.pulsetrainN(N,sfreq,ptd)
|
|
1084
|
+
+ os.pulsetrainN(N,sfreq*detune1,ptd)
|
|
1085
|
+
+ os.pulsetrainN(N,sfreq*detune2,ptd)) with { N=3; };
|
|
1086
|
+
pn = amp * no.pink_noise;
|
|
1087
|
+
|
|
1088
|
+
signal = ssaw*saw + ssq*sq + stri*tri
|
|
1089
|
+
+ spt*((ssptN*ptN)+(1-ssptN)*pt)
|
|
1090
|
+
+ spn*pn + sei*_;
|
|
1091
|
+
|
|
1092
|
+
// Signal controls:
|
|
1093
|
+
signal_group(x) = osc_group(hgroup("[0] Signal Levels",x));
|
|
1094
|
+
ssaw = signal_group(vslider("[0] Sawtooth [style:vslider]",1,0,1,0.01));
|
|
1095
|
+
|
|
1096
|
+
pt_group(x) = signal_group(vgroup("[1] Pulse Train",x));
|
|
1097
|
+
ssptN = pt_group(checkbox("[0] Order 3
|
|
1098
|
+
[tooltip: When checked, use 3rd-order aliasing suppression (up from 2)
|
|
1099
|
+
See if you can hear a difference with the freq high and swept]"));
|
|
1100
|
+
spt = pt_group(vslider("[1] [style:vslider]",0,0,1,0.01));
|
|
1101
|
+
ptd = pt_group(vslider("[2] Duty Cycle [style:knob]",0.5,0,1,0.01))
|
|
1102
|
+
: si.smooth(0.99);
|
|
1103
|
+
|
|
1104
|
+
ssq = signal_group(vslider("[2] Square [style:vslider]",0,0,1,0.01));
|
|
1105
|
+
stri = signal_group(vslider("[3] Triangle [style:vslider]",0,0,1,0.01));
|
|
1106
|
+
spn = signal_group(vslider(
|
|
1107
|
+
"[4] Pink Noise [style:vslider][tooltip: Pink Noise (or 1/f noise) is
|
|
1108
|
+
Constant-Q Noise, meaning that it has the same total power in every octave
|
|
1109
|
+
(uses only amplitude controls)]",0,0,1,0.01));
|
|
1110
|
+
sei = signal_group(vslider("[5] Ext Input [style:vslider]",0,0,1,0.01));
|
|
1111
|
+
|
|
1112
|
+
// Signal Parameters
|
|
1113
|
+
knob_group(x) = osc_group(hgroup("[1] Signal Parameters", x));
|
|
1114
|
+
af_group(x) = knob_group(vgroup("[0]", x));
|
|
1115
|
+
ampdb = af_group(hslider("[1] Mix Amplitude [unit:dB] [style:hslider]
|
|
1116
|
+
[tooltip: Sawtooth waveform amplitude]",-20,-120,10,0.1));
|
|
1117
|
+
amp = ampdb : ba.db2linear : si.smoo;
|
|
1118
|
+
freq = af_group(hslider("[2] Frequency [unit:PK] [style:hslider] [tooltip: Sawtooth
|
|
1119
|
+
frequency as a Piano Key (PK) number (A440 = key 49)]",49,1,88,0.01) : ba.pianokey2hz);
|
|
1120
|
+
|
|
1121
|
+
detune1 = 1 - 0.01 * knob_group(
|
|
1122
|
+
vslider("[3] Detuning 1 [unit:%%] [style:knob]
|
|
1123
|
+
[tooltip: Percentage frequency-shift up or down for second oscillator]",
|
|
1124
|
+
-0.1,-10,10,0.01));
|
|
1125
|
+
detune2 = 1 + 0.01 * knob_group(
|
|
1126
|
+
vslider("[4] Detuning 2 [unit:%%] [style:knob]
|
|
1127
|
+
[tooltip: Percentage frequency-shift up or down for third detuned oscillator]",
|
|
1128
|
+
+0.1,-10,10,0.01));
|
|
1129
|
+
portamento = knob_group(
|
|
1130
|
+
vslider("[5] Portamento [unit:sec] [style:knob] [scale:log]
|
|
1131
|
+
[tooltip: Portamento (frequency-glide) time-constant in seconds]",
|
|
1132
|
+
0.1,0.001,10,0.001));
|
|
1133
|
+
saworder = knob_group(nentry("[6] Saw Order [tooltip: Order of sawtooth aliasing
|
|
1134
|
+
suppression]",2,1,os.MAX_SAW_ORDER,1));
|
|
1135
|
+
sfreq = freq : si.smooth(ba.tau2pole(portamento));
|
|
1136
|
+
};
|
|
1137
|
+
|
|
1138
|
+
|
|
1139
|
+
//--------------------------`(dm.)oscrs_demo` ---------------------------
|
|
1140
|
+
// Simple application demoing filter based oscillators.
|
|
1141
|
+
//
|
|
1142
|
+
// #### Usage
|
|
1143
|
+
//
|
|
1144
|
+
// ```
|
|
1145
|
+
// oscrs_demo : _
|
|
1146
|
+
// ```
|
|
1147
|
+
//-------------------------------------------------------------------
|
|
1148
|
+
declare oscrs_demo author "Julius O. Smith III";
|
|
1149
|
+
declare oscrs_demo licence "MIT";
|
|
1150
|
+
|
|
1151
|
+
oscrs_demo = signal
|
|
1152
|
+
with{
|
|
1153
|
+
osc_group(x) = vgroup("[0] SINE WAVE OSCILLATOR oscrs [tooltip: Sine oscillator based
|
|
1154
|
+
on 2D vector rotation]",x);
|
|
1155
|
+
ampdb = osc_group(hslider("[1] Amplitude [unit:dB] [tooltip: Sawtooth waveform
|
|
1156
|
+
amplitude]",-20,-120,10,0.1));
|
|
1157
|
+
amp = ampdb : ba.db2linear : si.smoo;
|
|
1158
|
+
freq = osc_group(
|
|
1159
|
+
hslider("[2] Frequency [unit:PK]
|
|
1160
|
+
[tooltip: Sine wave frequency as a Piano Key (PK) number (A440 = 49 PK)]",
|
|
1161
|
+
49,1,88,0.01) : ba.pianokey2hz);
|
|
1162
|
+
portamento = osc_group(
|
|
1163
|
+
hslider("[3] Portamento [unit:sec] [scale:log]
|
|
1164
|
+
[tooltip: Portamento (frequency-glide) time-constant in seconds]",
|
|
1165
|
+
0.1,0.001,10,0.001));
|
|
1166
|
+
sfreq = freq : si.smooth(ba.tau2pole(portamento));
|
|
1167
|
+
signal = amp * os.oscrs(sfreq);
|
|
1168
|
+
};
|
|
1169
|
+
|
|
1170
|
+
oscr_demo = oscrs_demo; // synonym
|
|
1171
|
+
|
|
1172
|
+
|
|
1173
|
+
//--------------------------`(dm.)velvet_noise_demo`---------------------------
|
|
1174
|
+
// Listen to velvet_noise!
|
|
1175
|
+
//
|
|
1176
|
+
// #### Usage
|
|
1177
|
+
//
|
|
1178
|
+
// ```
|
|
1179
|
+
// velvet_noise_demo : _
|
|
1180
|
+
// ```
|
|
1181
|
+
//-------------------------------------------------------------------
|
|
1182
|
+
declare velvet_noise_demo author "Julius O. Smith III";
|
|
1183
|
+
declare velvet_noise_demo licence "MIT";
|
|
1184
|
+
|
|
1185
|
+
velvet_noise_demo = vn
|
|
1186
|
+
with{
|
|
1187
|
+
amp = hslider("Amp [unit:dB]",-10,-70,10,0.1) : ba.db2linear;
|
|
1188
|
+
f0 = 10.0, hslider("Freq [unit:log10(Hz)]",3,0,4,0.001) : pow;
|
|
1189
|
+
vn = no.velvet_noise(amp,f0);
|
|
1190
|
+
};
|
|
1191
|
+
|
|
1192
|
+
|
|
1193
|
+
//--------------------------`(dm.)latch_demo`---------------------------
|
|
1194
|
+
// Illustrate latch operation.
|
|
1195
|
+
//
|
|
1196
|
+
// #### Usage
|
|
1197
|
+
//
|
|
1198
|
+
// ```
|
|
1199
|
+
// echo 'import("stdfaust.lib");' > latch_demo.dsp
|
|
1200
|
+
// echo 'process = dm.latch_demo;' >> latch_demo.dsp
|
|
1201
|
+
// faust2octave latch_demo.dsp
|
|
1202
|
+
// Octave:1> plot(faustout);
|
|
1203
|
+
// ```
|
|
1204
|
+
//-------------------------------------------------------------------
|
|
1205
|
+
declare latch_demo author "Julius O. Smith III";
|
|
1206
|
+
declare latch_demo licence "MIT";
|
|
1207
|
+
|
|
1208
|
+
latch_demo = x, c, ba.latch(c,x) // plot(faustout) after faust2octave
|
|
1209
|
+
with{
|
|
1210
|
+
f = float(ma.SR)/1000.0;
|
|
1211
|
+
x = os.oscr(f);
|
|
1212
|
+
c = 0.5 * os.oscrs(5*f); // sample 5 times per period
|
|
1213
|
+
};
|
|
1214
|
+
|
|
1215
|
+
|
|
1216
|
+
//--------------------------`(dm.)envelopes_demo`---------------------------
|
|
1217
|
+
// Illustrate various envelopes overlaid, including their gate * 1.1.
|
|
1218
|
+
//
|
|
1219
|
+
// #### Usage
|
|
1220
|
+
//
|
|
1221
|
+
// ```
|
|
1222
|
+
// echo 'import("stdfaust.lib");' > envelopes_demo.dsp
|
|
1223
|
+
// echo 'process = dm.envelopes_demo;' >> envelopes_demo.dsp
|
|
1224
|
+
// faust2octave envelopes_demo.dsp
|
|
1225
|
+
// Octave:1> plot(faustout);
|
|
1226
|
+
// ```
|
|
1227
|
+
//-------------------------------------------------------------------
|
|
1228
|
+
declare envelopes_demo author "Julius O. Smith III";
|
|
1229
|
+
declare envelopes_demo licence "MIT";
|
|
1230
|
+
|
|
1231
|
+
envelopes_demo = gate <: _*1.1,envSE,envAR,envARFE,envARE,envASR,envADSR,envADSRE
|
|
1232
|
+
with{
|
|
1233
|
+
gate = (1-(1@500)) + 0.5*(1@750-(1@1700)); // retrigger at 1/2 amp
|
|
1234
|
+
envSE = en.smoothEnvelope(attSec/6.91); // uses time-constant not t60
|
|
1235
|
+
envAR = en.ar(attSec,relT60);
|
|
1236
|
+
envARFE = en.arfe(attSec,relT60,0.25);
|
|
1237
|
+
envARE = en.are(attSec,relT60);
|
|
1238
|
+
envASR = en.asr(attSec,susLvl,relT60);
|
|
1239
|
+
envADSR = en.adsr(attSec,decT60,susLvl,relT60);
|
|
1240
|
+
envADSRE = en.adsre(attSec,decT60,susLvl,relT60);
|
|
1241
|
+
attSec=0.002; // 2 ms attack time
|
|
1242
|
+
decT60=0.010; // 10 ms decay-to-sustain time
|
|
1243
|
+
susLvl=0.80; // Sustain level = 0.8
|
|
1244
|
+
relT60=0.010; // 10 ms release (decay-to-zero) time
|
|
1245
|
+
};
|
|
1246
|
+
|
|
1247
|
+
//-------------------`(dm.)fft_spectral_level_demo`------------------
|
|
1248
|
+
// Make a real-time spectrum analyzer using FFT from analyzers.lib.
|
|
1249
|
+
//
|
|
1250
|
+
// #### Usage
|
|
1251
|
+
//
|
|
1252
|
+
// ```
|
|
1253
|
+
// echo 'import("stdfaust.lib");' > fft_spectral_level_demo.dsp
|
|
1254
|
+
// echo 'process = dm.fft_spectral_level_demo;' >> fft_spectral_level_demo.dsp
|
|
1255
|
+
// Mac:
|
|
1256
|
+
// faust2caqt fft_spectral_level_demo.dsp
|
|
1257
|
+
// open fft_spectral_level_demo.app
|
|
1258
|
+
// Linux GTK:
|
|
1259
|
+
// faust2jack fft_spectral_level_demo.dsp
|
|
1260
|
+
// ./fft_spectral_level_demo
|
|
1261
|
+
// Linux QT:
|
|
1262
|
+
// faust2jaqt fft_spectral_level_demo.dsp
|
|
1263
|
+
// ./fft_spectral_level_demo
|
|
1264
|
+
// ```
|
|
1265
|
+
//-------------------------------------------------------------------
|
|
1266
|
+
declare fft_spectral_level_demo author "Julius O. Smith III";
|
|
1267
|
+
declare fft_spectral_level_demo licence "MIT";
|
|
1268
|
+
|
|
1269
|
+
fft_spectral_level_demo(N) = an.rfft_spectral_level(N,tau,dB_offset)
|
|
1270
|
+
with{
|
|
1271
|
+
ctl_group(x) = hgroup("[1] FFT SPECTRUM ANALYZER CONTROLS", x);
|
|
1272
|
+
tau = ctl_group(hslider("[0] Level Averaging Time [unit:ms] [scale:log]
|
|
1273
|
+
[tooltip: band-level averaging time in milliseconds]",
|
|
1274
|
+
100,1,10000,1)) * 0.001;
|
|
1275
|
+
dB_offset = ctl_group(hslider("[1] Level dB Offset [unit:dB]
|
|
1276
|
+
[tooltip: Level offset in decibels]",
|
|
1277
|
+
50,-50,100,1));
|
|
1278
|
+
};
|
|
1279
|
+
|
|
1280
|
+
//-----------------`(dm.)reverse_echo_demo(nChans)`----------------
|
|
1281
|
+
// Multichannel echo effect with reverse delays.
|
|
1282
|
+
//
|
|
1283
|
+
// #### Usage
|
|
1284
|
+
//
|
|
1285
|
+
// ```
|
|
1286
|
+
// echo 'import("stdfaust.lib");' > reverse_echo_demo.dsp
|
|
1287
|
+
// echo 'nChans = 3; // Any integer > 1 should work here' >> reverse_echo_demo.dsp
|
|
1288
|
+
// echo 'process = dm.reverse_echo_demo(nChans);' >> reverse_echo_demo.dsp
|
|
1289
|
+
// Mac:
|
|
1290
|
+
// faust2caqt reverse_echo_demo.dsp
|
|
1291
|
+
// open reverse_echo_demo.app
|
|
1292
|
+
// Linux GTK:
|
|
1293
|
+
// faust2jack reverse_echo_demo.dsp
|
|
1294
|
+
// ./reverse_echo_demo
|
|
1295
|
+
// Linux QT:
|
|
1296
|
+
// faust2jaqt reverse_echo_demo.dsp
|
|
1297
|
+
// ./reverse_echo_demo
|
|
1298
|
+
// Etc.
|
|
1299
|
+
// ```
|
|
1300
|
+
//-------------------------------------------------------------------
|
|
1301
|
+
declare reverse_echo_demo author "Julius O. Smith III";
|
|
1302
|
+
declare reverse_echo_demo licence "MIT";
|
|
1303
|
+
|
|
1304
|
+
reverse_echo_demo(nChans) = ef.reverseEchoN(nChans,delMax) : ef.uniformPanToStereo(nChans)
|
|
1305
|
+
with {
|
|
1306
|
+
delMax = 2^int(nentry("Log2(Delay)",15,5,16,1)); // delay line length
|
|
1307
|
+
};
|
|
1308
|
+
|
|
1309
|
+
//------------------------`(dm.)pospass_demo`------------------------
|
|
1310
|
+
// Use Positive-Pass Filter pospass() to frequency-shift a sine tone.
|
|
1311
|
+
// First, a real sinusoid is converted to its analytic-signal form
|
|
1312
|
+
// using pospass() to filter out its negative frequency component.
|
|
1313
|
+
// Next, it is multiplied by a modulating complex sinusoid at the
|
|
1314
|
+
// shifting frequency to create the frequency-shifted result.
|
|
1315
|
+
// The real and imaginary parts are output to channels 1 & 2.
|
|
1316
|
+
// For a more interesting frequency-shifting example, check the
|
|
1317
|
+
// "Use Mic" checkbox to replace the input sinusoid by mic input.
|
|
1318
|
+
// Note that frequency shifting is not the same as frequency scaling.
|
|
1319
|
+
// A frequency-shifted harmonic signal is usually not harmonic.
|
|
1320
|
+
// Very small frequency shifts give interesting chirp effects when
|
|
1321
|
+
// there is feedback around the frequency shifter.
|
|
1322
|
+
//
|
|
1323
|
+
// #### Usage
|
|
1324
|
+
//
|
|
1325
|
+
// ```
|
|
1326
|
+
// echo 'import("stdfaust.lib");' > pospass_demo.dsp
|
|
1327
|
+
// echo 'process = dm.pospass_demo;' >> pospass_demo.dsp
|
|
1328
|
+
// Mac:
|
|
1329
|
+
// faust2caqt pospass_demo.dsp
|
|
1330
|
+
// open pospass_demo.app
|
|
1331
|
+
// Linux GTK:
|
|
1332
|
+
// faust2jack pospass_demo.dsp
|
|
1333
|
+
// ./pospass_demo
|
|
1334
|
+
// Linux QT:
|
|
1335
|
+
// faust2jaqt pospass_demo.dsp
|
|
1336
|
+
// ./pospass_demo
|
|
1337
|
+
// Etc.
|
|
1338
|
+
// ```
|
|
1339
|
+
//-------------------------------------------------------------------
|
|
1340
|
+
declare pospass_demo author "Julius O. Smith III";
|
|
1341
|
+
declare pospass_demo licence "MIT";
|
|
1342
|
+
|
|
1343
|
+
pospass_demo(x) = analytic_signal, modulator : si.cmul with {
|
|
1344
|
+
N = 6; // pospass filter order
|
|
1345
|
+
fc = ma.SR/(2*N); // guard-band for filter roll-off
|
|
1346
|
+
octavesShift = hslider("Frequency Shift in octaves away from SR/16",
|
|
1347
|
+
-2,-7,3,0.001) : si.smooth(0.999);
|
|
1348
|
+
in_select = checkbox("Use Mic");
|
|
1349
|
+
sine_tone = os.oscrs(f0);
|
|
1350
|
+
f0 = ma.SR/16.0; // original frequency to be shifted
|
|
1351
|
+
fn = f0 * 2.0^octavesShift; // modulated frequency
|
|
1352
|
+
df = fn - f0; // frequency-shift as a difference
|
|
1353
|
+
input = select2(in_select, sine_tone, x);
|
|
1354
|
+
analytic_signal = input : fi.pospass6e(fc); // filter out neg freqs
|
|
1355
|
+
//analytic_signal = os.oscrs(f0) : fi.pospass(N,fc); // Butterworth case
|
|
1356
|
+
modulator = os.oscrq(df) : si.cconj; // complex modulation sinusoid
|
|
1357
|
+
// modulator(n) = exp(sqrt(-1) * 2 * ma.PI * df * n / ma.SR) // if complex ok
|
|
1358
|
+
};
|
|
1359
|
+
|
|
1360
|
+
// end jos section
|
|
1361
|
+
/************************************************************************
|
|
1362
|
+
************************************************************************
|
|
1363
|
+
FAUST library file, GRAME section
|
|
1364
|
+
|
|
1365
|
+
Except where noted otherwise, Copyright (C) 2003-2017 by GRAME,
|
|
1366
|
+
Centre National de Creation Musicale.
|
|
1367
|
+
----------------------------------------------------------------------
|
|
1368
|
+
GRAME LICENSE
|
|
1369
|
+
|
|
1370
|
+
This program is free software; you can redistribute it and/or modify
|
|
1371
|
+
it under the terms of the GNU Lesser General Public License as
|
|
1372
|
+
published by the Free Software Foundation; either version 2.1 of the
|
|
1373
|
+
License, or (at your option) any later version.
|
|
1374
|
+
|
|
1375
|
+
This program is distributed in the hope that it will be useful,
|
|
1376
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1377
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1378
|
+
GNU Lesser General Public License for more details.
|
|
1379
|
+
|
|
1380
|
+
You should have received a copy of the GNU Lesser General Public
|
|
1381
|
+
License along with the GNU C Library; if not, write to the Free
|
|
1382
|
+
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
|
1383
|
+
02111-1307 USA.
|
|
1384
|
+
|
|
1385
|
+
EXCEPTION TO THE LGPL LICENSE : As a special exception, you may create a
|
|
1386
|
+
larger FAUST program which directly or indirectly imports this library
|
|
1387
|
+
file and still distribute the compiled code generated by the FAUST
|
|
1388
|
+
compiler, or a modified version of this compiled code, under your own
|
|
1389
|
+
copyright and license. This EXCEPTION TO THE LGPL LICENSE explicitly
|
|
1390
|
+
grants you the right to freely choose the license for the resulting
|
|
1391
|
+
compiled code. In particular the resulting compiled code has no obligation
|
|
1392
|
+
to be LGPL or GPL. For example you are free to choose a commercial or
|
|
1393
|
+
closed source license or any other license if you decide so.
|
|
1394
|
+
************************************************************************
|
|
1395
|
+
************************************************************************/
|
|
1396
|
+
|
|
1397
|
+
// TODO: Add GRAME functions here
|
|
1398
|
+
|
|
1399
|
+
//########################################################################################
|
|
1400
|
+
/************************************************************************
|
|
1401
|
+
FAUST library file, further contributions section
|
|
1402
|
+
|
|
1403
|
+
All contributions below should indicate both the contributor and terms
|
|
1404
|
+
of license. If no such indication is found, "git blame" will say who
|
|
1405
|
+
last edited each line, and that person can be emailed to inquire about
|
|
1406
|
+
license disposition, if their license choice is not already indicated
|
|
1407
|
+
elsewhere among the libraries. It is expected that all software will be
|
|
1408
|
+
released under LGPL, STK-4.3, MIT, BSD, or a similar FOSS license.
|
|
1409
|
+
************************************************************************/
|
|
1410
|
+
|
|
1411
|
+
//-------------------------------`(dm.)exciter`-------------------------------
|
|
1412
|
+
// Psychoacoustic harmonic exciter, with GUI.
|
|
1413
|
+
//
|
|
1414
|
+
// #### Usage
|
|
1415
|
+
//
|
|
1416
|
+
// ```
|
|
1417
|
+
// _ : exciter : _
|
|
1418
|
+
// ```
|
|
1419
|
+
//
|
|
1420
|
+
// #### References
|
|
1421
|
+
//
|
|
1422
|
+
// * <https://secure.aes.org/forum/pubs/ebriefs/?elib=16939>
|
|
1423
|
+
// * <https://www.researchgate.net/publication/258333577_Modeling_the_Harmonic_Exciter>
|
|
1424
|
+
//-------------------------------------------------------------------------------------
|
|
1425
|
+
declare exciter author "PPriyanka Shekar and Julius O. Smith III";
|
|
1426
|
+
declare exciter licence "STK-4.3";
|
|
1427
|
+
|
|
1428
|
+
//-------------------------------------------------------------------------------------
|
|
1429
|
+
exciter = _ <: (fi.highpass(2, fc) : compressor : pregain : harmonicCreator :
|
|
1430
|
+
postgain), _ : balance
|
|
1431
|
+
with{
|
|
1432
|
+
// TODO: rewrite to use the standard compressor from compressors.lib
|
|
1433
|
+
compressor = ba.bypass1(cbp,compressorMono)
|
|
1434
|
+
with{
|
|
1435
|
+
comp_group(x) = vgroup("COMPRESSOR [tooltip: Reference:
|
|
1436
|
+
http://en.wikipedia.org/wiki/Dynamic_range_compression]", x);
|
|
1437
|
+
|
|
1438
|
+
meter_group(x) = comp_group(hgroup("[0]", x));
|
|
1439
|
+
knob_group(x) = comp_group(hgroup("[1]", x));
|
|
1440
|
+
|
|
1441
|
+
cbp = meter_group(checkbox("[0] Bypass [tooltip: When this is checked,
|
|
1442
|
+
the compressor has no effect]"));
|
|
1443
|
+
|
|
1444
|
+
gainview = co.compression_gain_mono(ratio,threshold,attack,release) : ba.linear2db
|
|
1445
|
+
: meter_group(hbargraph("[1] Compressor Gain [unit:dB] [tooltip: Current gain
|
|
1446
|
+
of the compressor in dB]",-50,+10));
|
|
1447
|
+
|
|
1448
|
+
displaygain = _ <: _,abs : _,gainview : attach;
|
|
1449
|
+
|
|
1450
|
+
compressorMono = displaygain(co.compressor_mono(ratio,threshold,attack,release));
|
|
1451
|
+
|
|
1452
|
+
ctl_group(x) = knob_group(hgroup("[3] Compression Control", x));
|
|
1453
|
+
|
|
1454
|
+
ratio = ctl_group(hslider("[0] Ratio [style:knob] [tooltip: A compression Ratio
|
|
1455
|
+
of N means that for each N dB increase in input signal level above Threshold, the
|
|
1456
|
+
output level goes up 1 dB]", 5, 1, 20, 0.1));
|
|
1457
|
+
|
|
1458
|
+
threshold = ctl_group(hslider("[1] Threshold [unit:dB] [style:knob] [tooltip:
|
|
1459
|
+
When the signal level exceeds the Threshold (in dB), its level is compressed
|
|
1460
|
+
according to the Ratio]", -30, -100, 10, 0.1));
|
|
1461
|
+
|
|
1462
|
+
env_group(x) = knob_group(hgroup("[4] Compression Response", x));
|
|
1463
|
+
|
|
1464
|
+
attack = env_group(hslider("[1] Attack [unit:ms] [style:knob] [tooltip:
|
|
1465
|
+
Time constant in ms (1/e smoothing time) for the compression gain to approach
|
|
1466
|
+
(exponentially) a new lower target level (the compression `kicking in')]",
|
|
1467
|
+
50, 0, 500, 0.1)) : *(0.001) : max(1/ma.SR);
|
|
1468
|
+
|
|
1469
|
+
release = env_group(hslider("[2] Release [unit:ms] [style: knob] [tooltip:
|
|
1470
|
+
Time constant in ms (1/e smoothing time) for the compression gain to approach
|
|
1471
|
+
(exponentially) a new higher target level (the compression 'releasing')]",
|
|
1472
|
+
500, 0, 1000, 0.1)) : *(0.001) : max(1/ma.SR);
|
|
1473
|
+
};
|
|
1474
|
+
|
|
1475
|
+
//Exciter GUI controls
|
|
1476
|
+
ex_group(x) = hgroup("EXCITER [tooltip: Reference: Patent US4150253 A]", x);
|
|
1477
|
+
|
|
1478
|
+
//Highpass - selectable cutoff frequency
|
|
1479
|
+
fc = ex_group(hslider("[0] Cutoff Frequency [unit:Hz] [style:knob] [scale:log]
|
|
1480
|
+
[tooltip: Cutoff frequency for highpassed components to be excited]",
|
|
1481
|
+
5000, 1000, 10000, 100));
|
|
1482
|
+
|
|
1483
|
+
//Pre-distortion gain - selectable percentage of harmonics
|
|
1484
|
+
ph = ex_group(hslider("[1] Harmonics [unit:percent] [style:knob] [tooltip:
|
|
1485
|
+
Percentage of harmonics generated]", 20, ma.EPSILON, 200, 1)) / 100;
|
|
1486
|
+
pregain = * (ph);
|
|
1487
|
+
|
|
1488
|
+
// TODO: same thing: why doesn't this use cubicnl?
|
|
1489
|
+
//Asymmetric cubic soft clipper
|
|
1490
|
+
harmonicCreator(x) = x <: cubDist1, cubDist2, cubDist3 :> _;
|
|
1491
|
+
cubDist1(x) = (x < 0) * x;
|
|
1492
|
+
cubDist2(x) = (x >= 0) * (x <= 1) * (x - x ^ 3 / 3);
|
|
1493
|
+
cubDist3(x) = (x > 1) * 2/3;
|
|
1494
|
+
|
|
1495
|
+
//Post-distortion gain - undoes effect of pre-gain
|
|
1496
|
+
postgain = * (1/ph);
|
|
1497
|
+
|
|
1498
|
+
//Balance - selectable dry/wet mix
|
|
1499
|
+
ml = ex_group(hslider("[2] Mix [style:knob] [tooltip: Dry/Wet mix of original signal
|
|
1500
|
+
to excited signal]", 0.5, 0, 1, 0.01));
|
|
1501
|
+
balance = (_ * ml), (_ * (1.0 - ml)) :> _;
|
|
1502
|
+
};
|
|
1503
|
+
|
|
1504
|
+
|
|
1505
|
+
//----------------------------`(dm.)vocoder_demo`-------------------------
|
|
1506
|
+
// Use example of the vocoder function where an impulse train is used
|
|
1507
|
+
// as excitation.
|
|
1508
|
+
//
|
|
1509
|
+
// #### Usage
|
|
1510
|
+
//
|
|
1511
|
+
// ```
|
|
1512
|
+
// _ : vocoder_demo : _
|
|
1513
|
+
// ```
|
|
1514
|
+
//------------------------------------------------------------
|
|
1515
|
+
declare vocoder_demo author "Romain Michon";
|
|
1516
|
+
declare vocoder_demo licence "LGPL";
|
|
1517
|
+
|
|
1518
|
+
vocoder_demo = hgroup("My Vocoder",_,os.lf_imptrain(freq)*gain :
|
|
1519
|
+
ve.vocoder(bands,att,rel,BWRatio) <: _,_)
|
|
1520
|
+
with{
|
|
1521
|
+
bands = 32;
|
|
1522
|
+
vocoderGroup(x) = vgroup("Vocoder",x);
|
|
1523
|
+
att = vocoderGroup(hslider("[0] Attack [style:knob] [tooltip: Attack time in seconds]",
|
|
1524
|
+
5,0.1,100,0.1)*0.001);
|
|
1525
|
+
rel = vocoderGroup(hslider("[1] Release [style:knob] [tooltip: Release time in seconds]",
|
|
1526
|
+
5,0.1,100,0.1)*0.001);
|
|
1527
|
+
BWRatio = vocoderGroup(hslider("[2] BW [style:knob] [tooltip: Coefficient to adjust the
|
|
1528
|
+
bandwidth of each band]",0.5,0.1,2,0.001));
|
|
1529
|
+
excitGroup(x) = vgroup("Excitation",x);
|
|
1530
|
+
freq = excitGroup(hslider("[0] Freq [style:knob]",330,50,2000,0.1));
|
|
1531
|
+
gain = excitGroup(vslider("[1] Gain",0.5,0,1,0.01) : si.smoo);
|
|
1532
|
+
};
|
|
1533
|
+
|
|
1534
|
+
//-----------------`(dm.)colored_noise_demo`--------------------
|
|
1535
|
+
// A coloured noise signal generator.
|
|
1536
|
+
//
|
|
1537
|
+
// #### Usage
|
|
1538
|
+
//
|
|
1539
|
+
// ```
|
|
1540
|
+
// colored_noise_demo : _
|
|
1541
|
+
// ```
|
|
1542
|
+
//
|
|
1543
|
+
//-------------------------------------------------
|
|
1544
|
+
declare colored_noise author "Constantinos Odysseas Economou";
|
|
1545
|
+
declare colored_noise license "MIT";
|
|
1546
|
+
|
|
1547
|
+
colored_noise_demo = no.colored_noise(N,alpha) : *(ampdb) : *(gate)
|
|
1548
|
+
with {
|
|
1549
|
+
N = 12;
|
|
1550
|
+
|
|
1551
|
+
alpha = hslider("[0] Alpha [style:knob] [tooltip: Spectral roll-off factor]", 0.0, -1.0, 1.0, 0.001) : si.smoo;
|
|
1552
|
+
ampdb = hslider("[1] Amplitude [unit:dB] [style:knob] [tooltip: Noise amplitude]", -20, -120, 10, 0.1) : ba.db2linear : si.smoo;
|
|
1553
|
+
gate = checkbox("[2] Gate");
|
|
1554
|
+
};
|
|
1555
|
+
|
|
1556
|
+
// end further contributions section
|