Pluck the string at a normalized position.
- Parameters
-
| position | Normalized position along string (0.0 to 1.0) |
| strength | Excitation amplitude (0.0 to 1.0+) |
Fills the delay line with a shaped noise burst. Position affects spectral content: 0.5 = center (warm), near 0/1 = bridge (bright).
Definition at line 226 of file WaveguideNetwork.cpp.
227{
228 position = std::clamp(position, 0.01, 0.99);
229
231 return;
232
235 const auto pluck_sample = static_cast<size_t>(position * static_cast<double>(len));
237 ? std::max(strength, 1.0)
238 : strength;
239
240 seg.p_plus = Memory::HistoryBuffer<double>(seg.p_plus.capacity());
241 seg.p_minus = Memory::HistoryBuffer<double>(seg.p_minus.capacity());
242
243 for (size_t s = 0; s < len; ++s) {
245 if (s <= pluck_sample) {
246 value = effective_strength *
static_cast<double>(s)
247 / static_cast<double>(pluck_sample);
248 } else {
249 value = effective_strength *
static_cast<double>(len - s)
250 / static_cast<double>(len - pluck_sample);
251 }
252 seg.p_plus.push(
value);
253 }
254
258 }
259}
size_t m_exciter_samples_remaining
ExciterType m_exciter_type
size_t m_delay_length_integer
@ CONTINUOUS
External node as continuous exciter (bowing)
std::vector< WaveguideSegment > m_segments
References CONTINUOUS, m_delay_length_integer, m_exciter_active, m_exciter_samples_remaining, m_exciter_type, m_segments, and value.