-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathgroup__iir__filter.html
More file actions
237 lines (225 loc) · 14.1 KB
/
group__iir__filter.html
File metadata and controls
237 lines (225 loc) · 14.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libfluidsynth: Effect - IIR Filter</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="custom.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">libfluidsynth
 <span id="projectnumber">2.5.4</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('group__iir__filter.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#enum-members">Enumerations</a> |
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">Effect - IIR Filter<div class="ingroups"><a class="el" href="group__synth.html">Synthesizer</a></div></div> </div>
</div><!--header-->
<div class="contents">
<p>Functions for configuring the built-in IIR filter effect.
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr class="memitem:ga1e682c5d6f22e13947cc07bcd92d7525"><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="group__iir__filter.html#ga1e682c5d6f22e13947cc07bcd92d7525">fluid_iir_filter_flags</a> { <br />
  <a class="el" href="group__iir__filter.html#gga1e682c5d6f22e13947cc07bcd92d7525a7a307ecda3d6856dc4da345df9dea667">FLUID_IIR_Q_LINEAR</a> = 1 << 0
, <br />
  <a class="el" href="group__iir__filter.html#gga1e682c5d6f22e13947cc07bcd92d7525a5aa913329adc2c9663486d8e7ceb1104">FLUID_IIR_Q_ZERO_OFF</a> = 1 << 1
, <br />
  <a class="el" href="group__iir__filter.html#gga1e682c5d6f22e13947cc07bcd92d7525a5ecac11504abbdc9c10843670799369d">FLUID_IIR_NO_GAIN_AMP</a> = 1 << 2
, <br />
  <a class="el" href="group__iir__filter.html#gga1e682c5d6f22e13947cc07bcd92d7525a347c1326bd6f2ecca54ede27e2d170d5">FLUID_IIR_BEANLAND</a> = 1 << 3
<br />
}</td></tr>
<tr class="memdesc:ga1e682c5d6f22e13947cc07bcd92d7525"><td class="mdescLeft"> </td><td class="mdescRight">Specifies optional settings to use for the custom IIR filter. <a href="group__iir__filter.html#ga1e682c5d6f22e13947cc07bcd92d7525">More...</a><br /></td></tr>
<tr class="separator:ga1e682c5d6f22e13947cc07bcd92d7525"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ga8a4cb4bd240d3654707ac0c5c7337a63"><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="group__iir__filter.html#ga8a4cb4bd240d3654707ac0c5c7337a63">fluid_iir_filter_type</a> { <br />
  <a class="el" href="group__iir__filter.html#gga8a4cb4bd240d3654707ac0c5c7337a63ac8e3072f6f29ea00c9cf728aeb900b00">FLUID_IIR_DISABLED</a> = 0
, <br />
  <a class="el" href="group__iir__filter.html#gga8a4cb4bd240d3654707ac0c5c7337a63a9e074b95c56f5ded53947c4169eb9785">FLUID_IIR_LOWPASS</a>
, <br />
  <a class="el" href="group__iir__filter.html#gga8a4cb4bd240d3654707ac0c5c7337a63ae3452abeba2f78ab30598b712da63cdd">FLUID_IIR_HIGHPASS</a>
, <br />
  <b>FLUID_IIR_LAST</b>
<br />
}</td></tr>
<tr class="memdesc:ga8a4cb4bd240d3654707ac0c5c7337a63"><td class="mdescLeft"> </td><td class="mdescRight">Specifies the type of filter to use for the custom IIR filter. <a href="group__iir__filter.html#ga8a4cb4bd240d3654707ac0c5c7337a63">More...</a><br /></td></tr>
<tr class="separator:ga8a4cb4bd240d3654707ac0c5c7337a63"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:gaaf4fda0f2b4e699fceed4b1202541f5f"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="group__iir__filter.html#gaaf4fda0f2b4e699fceed4b1202541f5f">fluid_synth_set_custom_filter</a> (<a class="el" href="group__Types.html#gae265f10ae174a13afe010de50d87e1a4">fluid_synth_t</a> *, int type, int flags)</td></tr>
<tr class="memdesc:gaaf4fda0f2b4e699fceed4b1202541f5f"><td class="mdescLeft"> </td><td class="mdescRight">Configure a general-purpose IIR biquad filter. <a href="group__iir__filter.html#gaaf4fda0f2b4e699fceed4b1202541f5f">More...</a><br /></td></tr>
<tr class="separator:gaaf4fda0f2b4e699fceed4b1202541f5f"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<p>Functions for configuring the built-in IIR filter effect. </p>
<h2 class="groupheader">Enumeration Type Documentation</h2>
<a id="ga1e682c5d6f22e13947cc07bcd92d7525"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1e682c5d6f22e13947cc07bcd92d7525">◆ </a></span>fluid_iir_filter_flags</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">enum <a class="el" href="group__iir__filter.html#ga1e682c5d6f22e13947cc07bcd92d7525">fluid_iir_filter_flags</a></td>
</tr>
</table>
</div><div class="memdoc">
<p>Specifies optional settings to use for the custom IIR filter. </p>
<p>Can be bitwise ORed. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="gga1e682c5d6f22e13947cc07bcd92d7525a7a307ecda3d6856dc4da345df9dea667"></a>FLUID_IIR_Q_LINEAR </td><td class="fielddoc"><p>The Soundfont spec requires the filter Q to be interpreted in dB. </p>
<p>If this flag is set the filter Q is instead assumed to be in a linear range </p>
</td></tr>
<tr><td class="fieldname"><a id="gga1e682c5d6f22e13947cc07bcd92d7525a5aa913329adc2c9663486d8e7ceb1104"></a>FLUID_IIR_Q_ZERO_OFF </td><td class="fielddoc"><p>If this flag the filter is switched off if Q == 0 (prior to any transformation) </p>
</td></tr>
<tr><td class="fieldname"><a id="gga1e682c5d6f22e13947cc07bcd92d7525a5ecac11504abbdc9c10843670799369d"></a>FLUID_IIR_NO_GAIN_AMP </td><td class="fielddoc"><p>The Soundfont spec requires to correct the gain of the filter depending on the filter's Q. </p>
<p>If this flag is set the filter gain will not be corrected. </p>
</td></tr>
<tr><td class="fieldname"><a id="gga1e682c5d6f22e13947cc07bcd92d7525a347c1326bd6f2ecca54ede27e2d170d5"></a>FLUID_IIR_BEANLAND </td><td class="fielddoc"><p>Setting this flag causes the custom filter's cutoff frequency (fc) to dynamically adjust to the notes played, so that it is possible to filter at the same spot relative to the sound of the sample playing. </p>
<p>In this sense, the filter fc honors the key and pitch of a note relative to the sample's root_key: if the key of a note is 2 semitones above the sample's root_key and additionally it's pitched up by 30 cents, the cutoff frequency would be automatically adjusted by +230 cents. E.g. for horns, one can add an emphasis on tones that would "stick to" the horn as it played different notes (provided that these notes use the same sample). The enum is named after Robin Beanland, who has used this technique in Conker's Bad Fur Day and (together with other composers) in Jet Force Gemini, implemented by Mike Currington on the N64. </p>
</td></tr>
</table>
</div>
</div>
<a id="ga8a4cb4bd240d3654707ac0c5c7337a63"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga8a4cb4bd240d3654707ac0c5c7337a63">◆ </a></span>fluid_iir_filter_type</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">enum <a class="el" href="group__iir__filter.html#ga8a4cb4bd240d3654707ac0c5c7337a63">fluid_iir_filter_type</a></td>
</tr>
</table>
</div><div class="memdoc">
<p>Specifies the type of filter to use for the custom IIR filter. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="gga8a4cb4bd240d3654707ac0c5c7337a63ac8e3072f6f29ea00c9cf728aeb900b00"></a>FLUID_IIR_DISABLED </td><td class="fielddoc"><p>Custom IIR filter is not operating. </p>
</td></tr>
<tr><td class="fieldname"><a id="gga8a4cb4bd240d3654707ac0c5c7337a63a9e074b95c56f5ded53947c4169eb9785"></a>FLUID_IIR_LOWPASS </td><td class="fielddoc"><p>Custom IIR filter is operating as low-pass filter. </p>
</td></tr>
<tr><td class="fieldname"><a id="gga8a4cb4bd240d3654707ac0c5c7337a63ae3452abeba2f78ab30598b712da63cdd"></a>FLUID_IIR_HIGHPASS </td><td class="fielddoc"><p>Custom IIR filter is operating as high-pass filter. </p>
</td></tr>
</table>
</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="gaaf4fda0f2b4e699fceed4b1202541f5f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaaf4fda0f2b4e699fceed4b1202541f5f">◆ </a></span>fluid_synth_set_custom_filter()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int fluid_synth_set_custom_filter </td>
<td>(</td>
<td class="paramtype"><a class="el" href="group__Types.html#gae265f10ae174a13afe010de50d87e1a4">fluid_synth_t</a> * </td>
<td class="paramname"><em>synth</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"><em>type</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"><em>flags</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Configure a general-purpose IIR biquad filter. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">synth</td><td>FluidSynth instance </td></tr>
<tr><td class="paramname">type</td><td>Type of the IIR filter to use (see <a class="el" href="group__iir__filter.html#ga8a4cb4bd240d3654707ac0c5c7337a63" title="Specifies the type of filter to use for the custom IIR filter.">fluid_iir_filter_type</a>) </td></tr>
<tr><td class="paramname">flags</td><td>Additional flags to customize this filter or zero to stay with the default (see <a class="el" href="group__iir__filter.html#ga1e682c5d6f22e13947cc07bcd92d7525" title="Specifies optional settings to use for the custom IIR filter.">fluid_iir_filter_flags</a>) </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="group__misc.html#gae4efb1c3ce0d550c922504adfb0fb886" title="Value that indicates success, used by most libfluidsynth functions.">FLUID_OK</a> if the settings have been successfully applied, otherwise <a class="el" href="group__misc.html#ga90e8bdbc5a507bbfa5c45bac85a63a61" title="Value that indicates failure, used by most libfluidsynth functions.">FLUID_FAILED</a></dd></dl>
<p>This is an optional, additional filter that operates independently from the default low-pass filter required by the Soundfont2 standard. By default this filter is off (<a class="el" href="group__iir__filter.html#gga8a4cb4bd240d3654707ac0c5c7337a63ac8e3072f6f29ea00c9cf728aeb900b00" title="Custom IIR filter is not operating.">FLUID_IIR_DISABLED</a>). </p>
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
</body>
</html>