[][src]Function fluidlite_sys::fluid_voice_optimize_sample

pub unsafe extern "C" fn fluid_voice_optimize_sample(
    s: *mut fluid_sample_t
) -> c_int

If the peak volume during the loop is known, then the voice can be released earlier during the release phase. Otherwise, the voice will operate (inaudibly), until the envelope is at the nominal turnoff point. In many cases the loop volume is many dB below the maximum volume. For example, the loop volume for a typical acoustic piano is 20 dB below max. Taking that into account in the turn-off algorithm we can save 20 dB / 100 dB => 1/5 of the total release time. So it's a good idea to call fluid_voice_optimize_sample on each sample once.