bevy/crates/bevy_render/src/camera
Aevyrie 38c7d5eb9e Check for NaN in Camera::world_to_screen() (#3268)
# Objective

- Checks for NaN in computed NDC space coordinates, fixing unexpected NaN in a fallible (`Option<T>`) function.

## Solution

- Adds a NaN check, in addition to the existing NDC bounds checks.
- This is a helper function, and should have no performance impact to the engine itself.
- This will help prevent hard-to-trace NaN propagation in user code, by returning `None` instead of `Some(NaN)`.


Depends on https://github.com/bevyengine/bevy/pull/3269 for CI error fix.
2021-12-08 01:31:31 +00:00
..
active_cameras.rs Implement and require #[derive(Component)] on all component structs (#2254) 2021-10-03 19:23:44 +00:00
camera.rs Check for NaN in Camera::world_to_screen() (#3268) 2021-12-08 01:31:31 +00:00
mod.rs enforce clippy for all target and features 2020-08-16 07:20:06 -07:00
projection.rs Implement and require #[derive(Component)] on all component structs (#2254) 2021-10-03 19:23:44 +00:00
visible_entities.rs Implement and require #[derive(Component)] on all component structs (#2254) 2021-10-03 19:23:44 +00:00