| 1 | |
| 2 | <refentry id="lpf18"> |
| 3 | <indexterm id="Indexlpf18"><primary>lpf18</primary></indexterm> |
| 4 | <refentryinfo><title>Signal Modifiers:Standard Filters:Resonant</title></refentryinfo> |
| 5 | <refmeta> |
| 6 | <refentrytitle>lpf18</refentrytitle> |
| 7 | </refmeta> |
| 8 | |
| 9 | <refnamediv> |
| 10 | <refname>lpf18</refname> |
| 11 | <refpurpose> |
| 12 | A 3-pole sweepable resonant lowpass filter. |
| 13 | </refpurpose> |
| 14 | </refnamediv> |
| 15 | |
| 16 | <refsect1> |
| 17 | <title>Description</title> |
| 18 | <para> |
| 19 | Implementation of a 3 pole sweepable resonant lowpass filter. |
| 20 | </para> |
| 21 | </refsect1> |
| 22 | |
| 23 | <refsect1> |
| 24 | <title>Syntax</title> |
| 25 | <synopsis>ares <command>lpf18</command> asig, xfco, xres, xdist [, iskip]</synopsis> |
| 26 | </refsect1> |
| 27 | |
| 28 | <refsect1> |
| 29 | <title>Initialization</title> |
| 30 | <para> |
| 31 | <emphasis>iskip</emphasis> (optional, default=0) -- Skip initialization if present and non-zero. |
| 32 | </para> |
| 33 | </refsect1> |
| 34 | |
| 35 | <refsect1> |
| 36 | <title>Performance</title> |
| 37 | <para> |
| 38 | <emphasis>xfco</emphasis> -- the filter cutoff frequency in Hz. Should be in the range 0 to <emphasis>sr</emphasis>/2. |
| 39 | </para> |
| 40 | |
| 41 | <para> |
| 42 | <emphasis>xres</emphasis> -- the amount of resonance. Self-oscillation occurs when <emphasis>xres</emphasis> is approximately 1. Should usually be in the range 0 to 1, however, values slightly greater than 1 are possible for more sustained oscillation and an <quote>overdrive</quote> effect. |
| 43 | </para> |
| 44 | |
| 45 | <para> |
| 46 | <emphasis>xdist</emphasis> -- amount of distortion. <emphasis>kdist</emphasis> = 0 gives a clean output. <emphasis>xdist</emphasis> > 0 adds <emphasis>tanh</emphasis>() distortion controlled by the filter parameters, in such a way that both low cutoff and high resonance increase the distortion amount. Some experimentation is encouraged. |
| 47 | </para> |
| 48 | |
| 49 | <para> |
| 50 | <emphasis>lpf18</emphasis> is a digital emulation of a 3 pole (18 dB/oct.) lowpass filter capable of self-oscillation with a built-in distortion unit. It is really a 3-pole version of <link linkend="moogvcf"><citetitle>moogvcf</citetitle></link>, retuned, recalibrated and with some performance improvements. The tuning and feedback tables use no more than 6 adds and 6 multiplies per control rate. The distortion unit, itself, is based on a modified <link linkend="tanh"><citetitle>tanh</citetitle></link> function driven by the filter controls. |
| 51 | </para> |
| 52 | |
| 53 | <note> |
| 54 | <title>Note</title> |
| 55 | <para> |
| 56 | Before version 6.04 this filter requires that the input signal |
| 57 | be normalized to one. |
| 58 | </para> |
| 59 | </note> |
| 60 | </refsect1> |
| 61 | |
| 62 | <refsect1> |
| 63 | <title>Examples</title> |
| 64 | <para> |
| 65 | Here is an example of the lpf18 opcode. It uses the file <ulink url="examples/lpf18.csd"><citetitle>lpf18.csd</citetitle></ulink>. |
| 66 | <example> |
| 67 | <title>Example of the lpf18 opcode.</title> |
| 68 | <para>See the sections <link linkend="UsingRealTime"><citetitle>Real-time Audio</citetitle></link> and <link linkend="CommandFlags"><citetitle>Command Line Flags</citetitle></link> for more information on using command line flags.</para> |
| 69 | <xi:include href="examples-xml/lpf18.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> |
| 70 | </example> |
| 71 | </para> |
| 72 | </refsect1> |
| 73 | |
| 74 | <refsect1> |
| 75 | <title>See also</title> |
| 76 | <para><link linkend="SigmodStandard"><citetitle>Standard Filters: Resonant Low-pass filters</citetitle></link></para> |
| 77 | </refsect1> |
| 78 | |
| 79 | <refsect1> |
| 80 | <title>Credits</title> |
| 81 | <para> |
| 82 | <simplelist> |
| 83 | <member>Author: Josep M Comajuncosas</member> |
| 84 | <member>Spain</member> |
| 85 | <member>December 2000</member> |
| 86 | </simplelist> |
| 87 | </para> |
| 88 | <para>New in Csound version 4.10</para> |
| 89 | <para>Audio rate parameters introduced in version 6.02</para> |
| 90 | <para>October 2013.</para> |
| 91 | </refsect1> |
| 92 | </refentry> |