1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00

Remove unnecessary line from Projection::get_z_far

Removes a line from Projection::get_z_far that flips the normal of a plane.
While this may be required for similar code elsewhere in the file, this is
unnecessary here, as only the length of the normal is used and not the
direction. Flipping the normal does not change its magnitude and therefore is
unnecessary in this case.
This commit is contained in:
Matthew
2023-09-20 10:48:37 -04:00
committed by GitHub
parent 0ba19c3e4a
commit 9f21dfbafd

View File

@@ -408,7 +408,6 @@ real_t Projection::get_z_far() const {
matrix[11] - matrix[10],
matrix[15] - matrix[14]);
new_plane.normal = -new_plane.normal;
new_plane.normalize();
return new_plane.d;