mirror of
https://github.com/ZDoom/fluidsynth.git
synced 2025-04-22 15:42:54 +00:00
rename fluid_linked_mod_test_identity => fluid_mod_test_linked_identity
This commit is contained in:
parent
819f1ee966
commit
93fc624998
5 changed files with 20 additions and 20 deletions
|
@ -824,7 +824,7 @@ fluid_defpreset_noteon_add_linked_mod_to_voice(fluid_voice_t *voice,
|
|||
|
||||
for(i = 0; i < identity_limit_count; i++)
|
||||
{
|
||||
if(fluid_linked_mod_test_identity(global_mod, mod_list[i],
|
||||
if(fluid_mod_test_linked_identity(global_mod, mod_list[i],
|
||||
FLUID_LINKED_MOD_TEST_ONLY))
|
||||
{
|
||||
break;
|
||||
|
|
|
@ -1004,7 +1004,7 @@ static int fluid_linked_branch_test_identity(fluid_mod_t *cm0_mod,
|
|||
*
|
||||
* @return TRUE if complex modulators are identical, FALSE otherwise.
|
||||
*/
|
||||
int fluid_linked_mod_test_identity(fluid_mod_t *cm0,
|
||||
int fluid_mod_test_linked_identity(fluid_mod_t *cm0,
|
||||
fluid_mod_t *cm1,
|
||||
unsigned char test_mode)
|
||||
{
|
||||
|
|
|
@ -58,12 +58,12 @@ int fluid_mod_has_linked_src1 (const fluid_mod_t * mod);
|
|||
int fluid_mod_is_linked (const fluid_mod_t * mod);
|
||||
|
||||
/* this enum is used for test_mode parameter when calling
|
||||
fluid_linked_mod_test_identity()
|
||||
fluid_mod_test_linked_identity()
|
||||
Note, for efficiency:
|
||||
FLUID_LINKED_MOD_TEST_OVERWRITE must be equal to FLUID_VOICE_OVERWRITE.
|
||||
FLUID_LINKED_MOD_TEST_ADD must be equal to FLUID_VOICE_ADD.
|
||||
*/
|
||||
enum fluid_linked_mod_test_identity
|
||||
enum fluid_mod_test_linked_identity
|
||||
{
|
||||
/**< test identity and overwrite modulator amounts */
|
||||
FLUID_LINKED_MOD_TEST_OVERWRITE = FLUID_VOICE_OVERWRITE,
|
||||
|
@ -75,7 +75,7 @@ enum fluid_linked_mod_test_identity
|
|||
FLUID_LINKED_MOD_TEST_ONLY
|
||||
};
|
||||
|
||||
int fluid_linked_mod_test_identity(fluid_mod_t *cm0, fluid_mod_t *cm1,
|
||||
int fluid_mod_test_linked_identity(fluid_mod_t *cm0, fluid_mod_t *cm1,
|
||||
unsigned char test_mode);
|
||||
|
||||
fluid_real_t fluid_mod_get_value(fluid_mod_t *mod, fluid_voice_t *voice);
|
||||
|
|
|
@ -1620,11 +1620,11 @@ fluid_voice_add_mod_local(fluid_voice_t *voice, fluid_mod_t *mod, int mode, int
|
|||
{
|
||||
/* test identity with mod if mod is a complex modulator */
|
||||
if( is_mod_complex
|
||||
&& fluid_linked_mod_test_identity(&voice->mod[i], mod,
|
||||
&& fluid_mod_test_linked_identity(&voice->mod[i], mod,
|
||||
FLUID_LINKED_MOD_TEST_ONLY))
|
||||
{
|
||||
/* overwrite/add amount */
|
||||
fluid_linked_mod_test_identity(&voice->mod[i], mod, mode);
|
||||
fluid_mod_test_linked_identity(&voice->mod[i], mod, mode);
|
||||
return;
|
||||
}
|
||||
/* Moves i to last member index of complex modulator */
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*----------------------------------------------------------------------------
|
||||
Test of fluid_zone_check_mod() , fluid_linked_mod_test_identity() functions.
|
||||
Test of fluid_zone_check_mod() , fluid_mod_test_linked_identity() functions.
|
||||
|
||||
Usage:
|
||||
test_fluid_zone_check_mod execute all tests
|
||||
|
@ -794,7 +794,7 @@ const char *usage ="\n\
|
|||
test_fluid_zone_check_mod 1_2 execute only one test number(i.e \"test 1_2: unlinked, sources src1 none\")\n\
|
||||
\n";
|
||||
/*
|
||||
Test of fluid_zone_check_mod() , fluid_linked_mod_test_identity() functions
|
||||
Test of fluid_zone_check_mod() , fluid_mod_test_linked_identity() functions
|
||||
|
||||
test_fluid_zone_check_mod [argument]
|
||||
*/
|
||||
|
@ -836,7 +836,7 @@ static int is_arg_num_test(char *arg, char *num_test)
|
|||
/*
|
||||
Does all test:
|
||||
- test of fluid_zone_check_mod() and
|
||||
- test of fluid_linked_mod_test_identity().
|
||||
- test of fluid_mod_test_linked_identity().
|
||||
|
||||
Note: These tests display results on the console and are intended to be
|
||||
interpreted by a human reading the result.
|
||||
|
@ -1044,7 +1044,7 @@ static int all_test_fluid_zone_check_mod(char *arg)
|
|||
@param mod_table0, pointer on modulator table.
|
||||
@param count_mod0, count of modulators in mod_table0.
|
||||
|
||||
2) Test the function fluid_linked_mod_test_identity() (if mod_table1
|
||||
2) Test the function fluid_mod_test_linked_identity() (if mod_table1
|
||||
is not null).
|
||||
The test does test identity between the first complex modulator
|
||||
found in mod_table0 and the first complex modulator found in mod_table1.
|
||||
|
@ -1103,9 +1103,9 @@ test_fluid_zone_check_mod(char * name_test,
|
|||
FLUID_LOG(FLUID_INFO, "End test of fluid_zone_check_mod() ----------------");
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/* Check if fluid_linked_mod_test_identity() test is requested ? */
|
||||
/* Check if fluid_mod_test_linked_identity() test is requested ? */
|
||||
FLUID_LOG(FLUID_INFO, "---------------------------------------------------");
|
||||
FLUID_LOG(FLUID_INFO, "Test fluid_linked_mod_test_identity() ? -----------");
|
||||
FLUID_LOG(FLUID_INFO, "Test fluid_mod_test_linked_identity() ? -----------");
|
||||
if((mod_table1) && (count_mod1))
|
||||
{
|
||||
list_mod1 = fluid_build_list(mod_table1, count_mod1);
|
||||
|
@ -1114,7 +1114,7 @@ test_fluid_zone_check_mod(char * name_test,
|
|||
return FLUID_FAILED;
|
||||
}
|
||||
|
||||
FLUID_LOG(FLUID_INFO, "Start test fluid_linked_mod_test_identity() -------");
|
||||
FLUID_LOG(FLUID_INFO, "Start test fluid_mod_test_linked_identity() -------");
|
||||
/* print list_mod */
|
||||
FLUID_LOG(FLUID_INFO, "- lists list_mod1, linked_mod1 before calling fluid_zone_check_mod():");
|
||||
print_lists(list_mod1, linked_mod1);
|
||||
|
@ -1134,11 +1134,11 @@ test_fluid_zone_check_mod(char * name_test,
|
|||
/* The test does test identity between the first complex modulator
|
||||
in linked_mod0 and the first complex modulator in linked_mod1. */
|
||||
fluid_linked_mod_dump_test_identity(linked_mod0,linked_mod1);
|
||||
FLUID_LOG(FLUID_INFO, "End test fluid_linked_mod_test_identity() ---------");
|
||||
FLUID_LOG(FLUID_INFO, "End test fluid_mod_test_linked_identity() ---------");
|
||||
}
|
||||
else
|
||||
{
|
||||
FLUID_LOG(FLUID_INFO, "- no, mod_table 1 is empty, no test of fluid_linked_mod_test_identity()");
|
||||
FLUID_LOG(FLUID_INFO, "- no, mod_table 1 is empty, no test of fluid_mod_test_linked_identity()");
|
||||
}
|
||||
|
||||
|
||||
|
@ -1229,8 +1229,8 @@ static void fluid_linked_mod_dump_test_identity(fluid_mod_t *mod0, fluid_mod_t *
|
|||
FLUID_LOG(FLUID_INFO, "-- complex modulator cm1:");
|
||||
fluid_dump_linked_mod(cm1, 0, 0);
|
||||
|
||||
/* Calling fluid_linked_mod_test_identity() */
|
||||
r = fluid_linked_mod_test_identity(cm0, cm1,
|
||||
/* Calling fluid_mod_test_linked_identity() */
|
||||
r = fluid_mod_test_linked_identity(cm0, cm1,
|
||||
FLUID_LINKED_MOD_TEST_ONLY);
|
||||
|
||||
/* display identity result */
|
||||
|
@ -1245,12 +1245,12 @@ static void fluid_linked_mod_dump_test_identity(fluid_mod_t *mod0, fluid_mod_t *
|
|||
if(r)
|
||||
{
|
||||
/* add amount to cm0 */
|
||||
fluid_linked_mod_test_identity(cm0, cm1, FLUID_LINKED_MOD_TEST_ADD);
|
||||
fluid_mod_test_linked_identity(cm0, cm1, FLUID_LINKED_MOD_TEST_ADD);
|
||||
FLUID_LOG(FLUID_INFO, "-- complex modulator added cm1 amount to cm0 amount");
|
||||
fluid_dump_linked_mod(cm0, 0, 0);
|
||||
|
||||
/* overwrite cm0 amount by cm1 amount */
|
||||
fluid_linked_mod_test_identity(cm0, cm1, FLUID_LINKED_MOD_TEST_OVERWRITE);
|
||||
fluid_mod_test_linked_identity(cm0, cm1, FLUID_LINKED_MOD_TEST_OVERWRITE);
|
||||
FLUID_LOG(FLUID_INFO, "-- complex modulator overwrite cm0 amount by cm1 amount");
|
||||
fluid_dump_linked_mod(cm0, 0, 0);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue