mirror of
https://github.com/johndoe6345789/SDL3CPlusPlus.git
synced 2026-04-26 14:44:58 +00:00
10 lines
207 B
Plaintext
Executable File
10 lines
207 B
Plaintext
Executable File
void mx_dodge_float(float fg, float bg, float mix, output float out)
|
|
{
|
|
if (abs(1.0 - fg) < M_FLOAT_EPS)
|
|
{
|
|
out = 0.0;
|
|
return;
|
|
}
|
|
out = mix*(bg / (1.0 - fg)) + ((1.0-mix)*bg);
|
|
}
|