Writing Docs Gigedit SFZ Instrument Scripts NKSP Language NKSP Reference


This function can be used to fade out the volume of all voices of the given note within the requsted amount of time. The volume will be faded from the note's current volume to total silence. If desired, the respective voices will automatically be stopped as soon as they were completely faded out.

Function Prototype

fade_out(note, duration-us, [stop])


Argument Name Data Type Description
note Note ID Number or Note ID Array All voices of this note will be faded out.
duration-us Integer Number Fade-out time in microseconds.
stop Integer Number or
Real Number
Whether the voice(s) shall be stopped after fade-out completed.
0: Keep the voices alive, to allow fading them back in for example.
1: Stop the voices automatically after fade-out.
[optional, default: 1]

Return Value



This functions optionally accepts s as standard unit for its argument duration-us.


None yet.

See also

fade_in(), change_vol()


Since LinuxSampler 2.0.0.svn45.

The third argument of this function stop is only optional with NKSP. If you want to keep compatibility with KSP, then you should always pass a value for that third argument of this function.

Document Updated:  2019-09-16  |  Author:  Christian Schoenebeck