This repository has been archived by the owner on Apr 18, 2022. It is now read-only.
remove far plane from perspective projection #2118
Merged
Merged
Commits on Jun 14, 2020
-
remove far plane from perspective projection
I switched to near to 1 and far to 0, which should make depth much more accurate. 3d doesn't have a far plane anymore, as it should be much more accurate than before even with infinite Z. Infinite-z does not make sense for orthographic projections, because error must be small regardless of distance there.
-
-
-
switch debug_lines to GreaterEqual
This matches the LessEqual it previously had. It makes debug_lines_ortho render like it did before these changes. I believe that rendering later lines on top of earlier ones is the expected behaviour.
-
remove projection, put it directly into Camera
The setters and getters for parts of a projection have been removed. They were broken, as the setters did not update the inverse matrix. If updating is desired, a new Camera can be build, which should be about as fast. This commit breaks auto_fov. I'll rewrite that utility in the next commit.
-
-
near clipping plane from 0.1 to 0.125
One eighth is a good value because it can be represented accurately unlike one tenth. The small change hopefully doesn't break people's code.
-
It turns out the calculations needed for auto_fov are already done when constructing a perspective matrix.
-
-
update camera when AutoFov changes
Previously it was only updated when the screen dimensions changed, making it not work if the screen is never resized or if parameters are changed.
-
make tests use actual bottom right
They used to use a version that was off by one pixel for some reason.
-
-
-
-
May have been broken when rebasing onto newest master.
-
remove unnecessary Projection imports in book
This may not fix the book but I was unable to build it locally
-
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.