mirror of
https://github.com/thestk/stk
synced 2026-04-19 22:16:54 +00:00
90 lines
5.6 KiB
HTML
90 lines
5.6 KiB
HTML
<HTML>
|
|
<HEAD>
|
|
<TITLE>The Synthesis ToolKit in C++ (STK)</TITLE>
|
|
<LINK HREF="doxygen.css" REL="stylesheet" TYPE="text/css">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#FFFFFF">
|
|
<CENTER>
|
|
<img src="princeton.gif"> <img src="ccrma.gif"> <img src="mcgill.gif"><P>
|
|
<a class="qindex" href="index.html">Home</a> <a class="qindex" href="information.html">Information</a> <a class="qindex" href="classes.html">Classes</a> <a class="qindex" href="download.html">Download</a> <a class="qindex" href="usage.html">Usage</a> <a class="qindex" href="maillist.html">Mail List</a> <a class="qindex" href="system.html">Requirements</a> <a class="qindex" href="links.html">Links</a> <a class="qindex" href="tutorial.html">Tutorial</a></CENTER>
|
|
<HR>
|
|
<!-- Generated by Doxygen 1.3.4 -->
|
|
<h1>Modal.h</h1><div class="fragment"><pre>00001 <span class="comment">/***************************************************/</span>
|
|
00012 <span class="comment">/***************************************************/</span>
|
|
00013
|
|
00014 <span class="preprocessor">#ifndef STK_MODAL_H</span>
|
|
00015 <span class="preprocessor"></span><span class="preprocessor">#define STK_MODAL_H</span>
|
|
00016 <span class="preprocessor"></span>
|
|
00017 <span class="preprocessor">#include "Instrmnt.h"</span>
|
|
00018 <span class="preprocessor">#include "Envelope.h"</span>
|
|
00019 <span class="preprocessor">#include "WaveLoop.h"</span>
|
|
00020 <span class="preprocessor">#include "BiQuad.h"</span>
|
|
00021 <span class="preprocessor">#include "OnePole.h"</span>
|
|
00022
|
|
<a name="l00023"></a><a class="code" href="classModal.html">00023</a> <span class="keyword">class </span><a class="code" href="classModal.html">Modal</a> : <span class="keyword">public</span> <a class="code" href="classInstrmnt.html">Instrmnt</a>
|
|
00024 {
|
|
00025 <span class="keyword">public</span>:
|
|
00027
|
|
00030 <a class="code" href="classModal.html#a0">Modal</a>( <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> modes = 4 );
|
|
00031
|
|
00033 <span class="keyword">virtual</span> <a class="code" href="classModal.html#a1">~Modal</a>();
|
|
00034
|
|
00036 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a2">clear</a>();
|
|
00037
|
|
00039 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classModal.html#a3">setFrequency</a>(StkFloat frequency);
|
|
00040
|
|
00042 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a4">setRatioAndRadius</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> modeIndex, StkFloat ratio, StkFloat radius);
|
|
00043
|
|
00045 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a5">setMasterGain</a>(StkFloat aGain);
|
|
00046
|
|
00048 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a6">setDirectGain</a>(StkFloat aGain);
|
|
00049
|
|
00051 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a7">setModeGain</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> modeIndex, StkFloat gain);
|
|
00052
|
|
00054 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classModal.html#a8">strike</a>(StkFloat amplitude);
|
|
00055
|
|
00057 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a9">damp</a>(StkFloat amplitude);
|
|
00058
|
|
00060 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a10">noteOn</a>(StkFloat frequency, StkFloat amplitude);
|
|
00061
|
|
00063 <span class="keywordtype">void</span> <a class="code" href="classModal.html#a11">noteOff</a>(StkFloat amplitude);
|
|
00064
|
|
00066 <span class="keyword">virtual</span> StkFloat <a class="code" href="classModal.html#a12">tick</a>();
|
|
00067
|
|
00069 <span class="keyword">virtual</span> StkFloat *<a class="code" href="classModal.html#a12">tick</a>(StkFloat *vector, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> vectorSize);
|
|
00070
|
|
00072
|
|
00078 <span class="keyword">virtual</span> <a class="code" href="classStkFrames.html">StkFrames</a>& <a class="code" href="classModal.html#a12">tick</a>( <a class="code" href="classStkFrames.html">StkFrames</a>& frames, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> channel = 1 );
|
|
00079
|
|
00081 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classModal.html#a15">controlChange</a>(<span class="keywordtype">int</span> number, StkFloat value) = 0;
|
|
00082
|
|
00083 <span class="keyword">protected</span>:
|
|
00084 <a class="code" href="classEnvelope.html">Envelope</a> envelope_;
|
|
00085 <a class="code" href="classWvIn.html">WvIn</a> *wave_;
|
|
00086 <a class="code" href="classBiQuad.html">BiQuad</a> **filters_;
|
|
00087 <a class="code" href="classOnePole.html">OnePole</a> onepole_;
|
|
00088 <a class="code" href="classWaveLoop.html">WaveLoop</a> *vibrato_;
|
|
00089
|
|
00090 <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> nModes_;
|
|
00091 std::vector<StkFloat> ratios_;
|
|
00092 std::vector<StkFloat> radii_;
|
|
00093
|
|
00094 StkFloat vibratoGain_;
|
|
00095 StkFloat masterGain_;
|
|
00096 StkFloat directGain_;
|
|
00097 StkFloat stickHardness_;
|
|
00098 StkFloat strikePosition_;
|
|
00099 StkFloat baseFrequency_;
|
|
00100 };
|
|
00101
|
|
00102 <span class="preprocessor">#endif</span>
|
|
</pre></div><HR>
|
|
|
|
<table>
|
|
<tr><td><A HREF="http://ccrma.stanford.edu/software/stk/"><I>The Synthesis ToolKit in C++ (STK)</I></A></td></tr>
|
|
<tr><td>©1995-2004 Perry R. Cook and Gary P. Scavone. All Rights Reserved.</td></tr>
|
|
</table>
|
|
|
|
</BODY>
|
|
</HTML>
|