| 1 | <refentry id="STKBandedWG"> |
| 2 | <indexterm id="IndexStkbandedwg"><primary>STKBandedWG</primary></indexterm> |
| 3 | <refentryinfo><title>Signal Generators:STK Opcodes</title></refentryinfo> |
| 4 | <refmeta> |
| 5 | <refentrytitle>STKBandedWG</refentrytitle> |
| 6 | </refmeta> |
| 7 | |
| 8 | <refnamediv> |
| 9 | <refname>STKBandedWG</refname> |
| 10 | <refpurpose> |
| 11 | STKBandedWG uses banded waveguide techniques to model a variety of sounds. |
| 12 | </refpurpose> |
| 13 | </refnamediv> |
| 14 | |
| 15 | <refsect1> |
| 16 | <title>Description</title> |
| 17 | <para>Plugin opcode in stkopd. This opcode is part of the plugin repository and has to be installed separately. |
| 18 | The plugin repository can be found here: <ulink url="https://github.com/csound/plugins"><citetitle>https://github.com/csound/plugins</citetitle></ulink></para> |
| 19 | <para> |
| 20 | This opcode uses banded waveguide techniques to model a variety of sounds, including bowed bars, glasses, and bowls.</para> |
| 21 | </refsect1> |
| 22 | |
| 23 | <refsect1> |
| 24 | <title>Syntax</title> |
| 25 | <synopsis>asignal <command>STKBandedWG</command> ifrequency, iamplitude, [kpress, kv1[, kmot, kv2[, klfo, kv3[, klfodepth, kv4[, kvel, kv5[, kstrk, kv6[, kinstr, kv7]]]]]]]</synopsis> |
| 26 | </refsect1> |
| 27 | |
| 28 | <refsect1> |
| 29 | <title>Initialization</title> |
| 30 | <para> |
| 31 | <emphasis>ifrequency</emphasis> -- Frequency of note played, in Hertz. |
| 32 | </para> |
| 33 | |
| 34 | <para> |
| 35 | <emphasis>iamplitude</emphasis> -- Amplitude of note played (range 0-1). |
| 36 | </para> |
| 37 | </refsect1> |
| 38 | |
| 39 | <refsect1> |
| 40 | <title>Performance</title> |
| 41 | <para><emphasis>kpress</emphasis> -- controller 2, pressure of bow. Value range of kv1 is 0-127.</para> |
| 42 | <para><emphasis>kmot</emphasis> -- controller 4, motion of bow. Value range of kv2 is 0-127.</para> |
| 43 | <para><emphasis>klfo</emphasis> -- controller 11, speed of low-frequency oscillator. Value range of kv3 is 0-127.</para> |
| 44 | <para><emphasis>klfodepth</emphasis> -- controller 1, depth of low-frequency oscillator. Value range of kv4 is 0-127.</para> |
| 45 | <para><emphasis>kvel</emphasis> -- controller 128, velocity of bow. Value range of kv5 is 0-127.</para> |
| 46 | <para><emphasis>kstrk</emphasis> -- controller 64, striking of bow. Value range of kv6 is 0-127.</para> |
| 47 | <para><emphasis>kinstr</emphasis> -- controller 16, instrument presets (0 = uniform bar, 1 = tuned bar, 2 = glass harmonica, 3 = Tibetan bowl). Value range of kv7 is 0-3.</para> |
| 48 | </refsect1> |
| 49 | |
| 50 | <refsect1> |
| 51 | <note> |
| 52 | <title>Notes</title> |
| 53 | <para> |
| 54 | The code for this opcode is taken directly from the BandedWG class in the Synthesis Toolkit in C++ by Perry R. Cook and Gary P. Scavone. More on the STK classes can be found here: |
| 55 | <ulink url="https://ccrma.stanford.edu/software/stk/classes.html"><citetitle>https://ccrma.stanford.edu/software/stk/classes.html</citetitle></ulink> |
| 56 | </para> |
| 57 | <para> |
| 58 | <emphasis>kc1, kv1, kc2, kv2, kc3, kv3, kc4, kv4, kc5, kv5, kc6, kv6, kc7, kv7, kc8, kv8</emphasis> -- Up to 8 optional k-rate controller pairs for the STK opcodes. |
| 59 | Each controller pair consists of a controller number (kc) followed by a controller value (kv). Both the controller numbers and the controller values are krate variables. However, during a performance, normally the controller numbers stay fixed while the corresponding controller values may change at any time. |
| 60 | The order of the controller pair is arbitrary, as long as they are after <emphasis>iamplitude</emphasis>. Also, it is not needed that all controller pairs are used. |
| 61 | </para> |
| 62 | </note> |
| 63 | </refsect1> |
| 64 | |
| 65 | <refsect1> |
| 66 | <title>Examples</title> |
| 67 | <para> |
| 68 | Here is an example of the STKBandedWG opcode. It uses the file <ulink url="examples/STKBandedWG.csd"><citetitle>STKBandedWG.csd</citetitle></ulink>. |
| 69 | |
| 70 | <example> |
| 71 | <title>Example of the STKBandedWG opcode.</title> |
| 72 | <xi:include href="examples-xml/STKBandedWG.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> |
| 73 | </example> |
| 74 | </para> |
| 75 | </refsect1> |
| 76 | |
| 77 | <refsect1> |
| 78 | <title>See also</title> |
| 79 | <para><link linkend="STKTop"><citetitle>STK Opcodes</citetitle></link></para> |
| 80 | </refsect1> |
| 81 | |
| 82 | <refsect1> |
| 83 | <title>Credits</title> |
| 84 | <para> |
| 85 | <simplelist> |
| 86 | <member>Author: &namemichael; (after Georg Essl)</member> |
| 87 | <member>Irreducible Productions</member> |
| 88 | <member>New York, NY</member> |
| 89 | </simplelist> |
| 90 | </para> |
| 91 | <para>New in Csound version 5.11</para> |
| 92 | </refsect1> |
| 93 | </refentry> |
| 94 |