The zero amp voltage is more of a hypothetical figure, if you were to draw the Vf/A curve as a straight line. For example, using djozz’s 219C test it would be about 3V. It has an effect on the shape of the ramp after V_FULL_PWM.
And this works the other way around: it reduces PWM value when Vcc is above V_FULL_PWM. So you should be able to leave the modes mostly as they are now, pick V_FULL_PWM where you think the light is as bright as it should be and the code will try to prevent it getting brighter. For example, if you pick V_FULL_PWM of 3.8V, then a PWM value of 255 will remain 255 below 3.8V, might turn into 235 at 3.9V, 220 at 4.0V, 205 at 4.1V and 195 at 4.2V (these are just guesses but it does look something like that).
And yes, you just call the function on whatever channels you want to, right where the PWM value is set. In bistro, that means changing something like “PWM_LVL = pwm1;” to something closer to “PWM_LVL = regulate_fet( get_voltage(), pwm1 );”. Although the diode drop probably needs to be added to get_voltage() too.
Edit: I was tired when I wrote that code so the constants are pretty badly named. V_FULL_PWM would probably be better understood as V_REGULATION_CUTOFF or something similar. And perhaps V_ZERO_AMP as V_CURVE_ORIGIN or something else which doesn’t give any wrong ideas.