Open JosephHinz opened 2 years ago
@JosephHinz great catch on a relatively untested part of the code, I will look into this. If possible, you can make a merge request on this file and we can incorporate your changes directly into the main code to give you proper attribution on any fix. Let me know if you have any questions about this.
NB it seems like in your example with the old version of the code the envelope was shooting past zero at 1.3s, so you get a signal with an inverted phase, but approaching an absolute volume level of ~ 0.1, explaining why the sound was not dying off
Hi James,
While working with the ADSR envelope code, I was getting no release at the end. Plotting the envelope generated the plot: (For a sound length of 1 second)
I've applied a fix and extension to the envelope code in mine to overcome this problem, but thought you would like to know the fix applied:
`nlen=params['note_length'] edict=params[f'{etype}_envelope']
This new code gives the following plot: