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

Thread: how can I use AudioEffectEnvelope::isActive ??

  1. #1

    how can I use AudioEffectEnvelope::isActive ??

    I have an array of envelopes, and I want to look through them to find one that is not active. Below is the snippet.
    The error I am getting is
    "cannot convert 'AudioEffectEnvelope::isActive' from type 'bool (AudioEffectEnvelope:()' to type 'bool'"

    How do I use the isActive value in a conditional? Actually the opposite of isActive?

    AudioEffectEnvelope      envelope[7];
      int i_return; 
      for (int i = 0; i <= 6; i++) {  // look at each envelope
        if ( ! envelope[i].isActive  ) {  // see if it is active
         i_return = i;
        break; // no reason to keep looping
      } // for loop

  2. #2
    figured it out, I was missing the parenthesis
     if ( ! envelope[i].isActive()  )

Posting Permissions

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