# Noise attack weirdness while filtered

**URL:** https://in-thread.sonic-pi.net/t/noise-attack-weirdness-while-filtered/9578
**Category:** Support, Help & Resources
**Created:** [March 12, 2025, 9:47pm UTC](https://in-thread.sonic-pi.net/t/noise-attack-weirdness-while-filtered/9578 "2025-03-12T21:47:35Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![HarryLeBlanc](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/harryleblanc/32/2813_2.png) [@HarryLeBlanc](https://in-thread.sonic-pi.net/u/HarryLeBlanc)
#### Post date: [March 12, 2025, 9:47pm UTC](https://in-thread.sonic-pi.net/t/noise-attack-weirdness-while-filtered/9578/1 "2025-03-12T21:47:35Z")

</div>

Okay, I’m fiddling around with trying to make a whistle sound, using resonant filters.  
What I want is to have the noise have an attack, and the resonance for the filter also have an attack. But when I wrap the play command inside the fx command for the filter, the noise attack seems to go away:

```ruby
with_synth :noise do
  handle = play :c3, attack: 0.25, decay: 0, sustain: 1.0, release: 0.25
end

sleep 2

with_fx :nrlpf, cutoff: :c6, res: 0 do |lh|
  with_fx :nhpf, cutoff: :c6 do
    with_synth :noise do
      handle = play :c3, attack: 0.25, decay: 0, sustain: 1.0, release: 0.25
    end
    sleep 0.125
    control lh, res: 0.99, res_slide: 0.25
    sleep 1.25
    control lh, res: 0.0, res_slide: 0.01
    
  end
end

```

Any idea what’s going on here? How do I hack around it? I’m trying to emulate a human whistle, which has a short attack at the beginning. The fadeout seems to be working, but the fade in is still problematic.  
Any insights would be most appreciated.

---

<div class="post-metadata">

### Author: ![HarryLeBlanc](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/harryleblanc/32/2813_2.png) [@HarryLeBlanc](https://in-thread.sonic-pi.net/u/HarryLeBlanc)
#### Post date: [March 19, 2025, 11:08pm UTC](https://in-thread.sonic-pi.net/t/noise-attack-weirdness-while-filtered/9578/2 "2025-03-19T23:08:04Z")

</div>

Okay, the problem seems to be with the normalized filters. If I use the non-normalized versions, it works okay.  
Which makes sense – it’s normalizing the quiet part, aka making it loud!

---

<div class="post-metadata">

### Author: ![Tianjh](https://dub1.discourse-cdn.com/flex017/user_avatar/in-thread.sonic-pi.net/tianjh/32/2949_2.png) [@Tianjh](https://in-thread.sonic-pi.net/u/Tianjh)
#### Post date: [March 22, 2025, 12:24pm UTC](https://in-thread.sonic-pi.net/t/noise-attack-weirdness-while-filtered/9578/3 "2025-03-22T12:24:58Z")

</div>

this is the whistle here lol

 ![image](https://europe1.discourse-cdn.com/flex017/uploads/sonic_pi/original/2X/6/6cad2968a5f241392add25bcb85f0cc51bb160e6.jpeg)
