Godtone (talk | contribs)
add option to disable direct mapping; this changes the order of only the last parameter which i suspect wasnt used by anyone in argument order; also makes the omission of et2 make more sense later on and also makes more sense in general as specifying the et2 suggests using a mapping may not be desirable
Godtone (talk | contribs)
m finish path?
Line 1,373: Line 1,373:
# alternatively, feed the real number of divisions of the octave that generates your val for each val you want to compare.   
# alternatively, feed the real number of divisions of the octave that generates your val for each val you want to compare.   
global patent_vals
global patent_vals
if type(v)==int:
if type(v)==int and v:
if v in patent_vals:
if v in patent_vals:
v = patent_vals[v]
v = patent_vals[v]
Line 1,381: Line 1,381:
elif type(v)==float:
elif type(v)==float:
v = val(lim(255),ed(v))
v = val(lim(255),ed(v))
elif not mapping and not v:
pass # not using a val
elif mapping and not v:
raise(Exception('mapping=True but no val v is given'))
# deduce the number of arguments in the badness function to allow only using the first n arguments as needed
# deduce the number of arguments in the badness function to allow only using the first n arguments as needed
num_args = badness.__code__.co_argcount
num_args = badness.__code__.co_argcount