Files
test/source
Sean Kim e1d46c1570 BLI: Ensure rcp and safe_rcp are not used with integral types
Since we expect the result of `rcp` and `safe_rcp` to always be in the
range of [0, 1], it doesn't make sense to allow passing in integer types
without casting them, as this has a high possibility of introducing
unwanted behavior by only returning either 0 or 1.

To prevent this, this commit adds a static assert on the type.

Pull Request: https://projects.blender.org/blender/blender/pulls/141567
2025-07-15 19:12:34 +02:00
..