Added ADSR envelope
modified note iteration to check if amplitude > 0.0