[light] Use reciprocal multiply in normalize_color (#15401)

This commit is contained in:
J. Nick Koston
2026-04-03 08:28:41 -10:00
committed by GitHub
parent 95683b7416
commit 4969fd6e99
@@ -104,9 +104,10 @@ class LightColorValues {
this->green_ = 1.0f;
this->blue_ = 1.0f;
} else {
this->red_ /= max_value;
this->green_ /= max_value;
this->blue_ /= max_value;
float inv = 1.0f / max_value;
this->red_ *= inv;
this->green_ *= inv;
this->blue_ *= inv;
}
}
}