Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 3 of 3

Thread: triggering an envelope from another audio object

  1. #1

    triggering an envelope from another audio object

    I’ve got a Teensy Audio Library question. I often find that I want to trigger an envelope using the output of another audio object (a square wave oscillator, for example), rather than using noteOn() in my sketch. What would be the best way to go about this?

    I’ve tried using peak / rms to read the output of the square wave and then calling noteOn() that way, but wondering if there’s a better way. Thanks!

  2. #2
    I don't know of a better way but I'm no expert. You could write a new envelope object based on the old one that takes an additional trigger input, which probably wouldn't be too hard, but the audio code can be pretty confusing.

  3. #3
    Thanks for the reply! Iíve actually been busy doing just that.

    I think I have it working pretty well. Iíll post the code when Iíve tested it a bit more in case anyone else is interested.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts