|
From: | Ceresa Jean-Jacques |
Subject: | [fluid-dev] A Bit of optimization. |
Date: | Sun, 22 Oct 2017 16:07:33 +0200 (CEST) |
Hi,
List of possible optimization.
1)In fluid_voice.c - fluid_voice_calculate_runtime_synthesis_parameters()
int list_of_generators_to_initialize[35]..., replaced by, static const int list_of_generators_to_initialize[35] = {
2)In fluid_voice.c - fluid_voice_update_param()
case GEN_VOLENVATTACK:
count ? 1.0f / count : 0.0f... replaced by, 1.0f / count
case GEN_VOLENVRELEASE:
count ? 1.0f / count : 0.0f... replaced by, 1.0f / count
case GEN_MODENVATTACK:
count ? 1.0f / count : 0.0f... replaced by, 1.0f / count
case GEN_MODENVRELEASE:
count ? 1.0f / count : 0.0f... replaced by, 1.0f / count
2)In fluid_rvoice-fluid_rvoice_noteoff()
fluid_real_t amp = fluid_adsr_env_get_val(&voice->envlfo.volenv) * pow (10.0, lfo / -200);
replaced by fluid_real_t amp = fluid_adsr_env_get_val(&voice->envlfo.volenv) * fluid_cb2amp(lfo);
Regards
jjc
[Prev in Thread] | Current Thread | [Next in Thread] |