MiniEngine: Frustum::ConstructOrthographicFrustum near/far plane normals point outward, inconsistent with side planes

Open Beginner friendly
#960 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
68/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
cpp

Research direction

Open MiniEngine/Core/Math/Frustum.cpp and inspect Frustum::ConstructOrthographicFrustum, comparing the near and far plane definitions with the side planes. Confirm the plane-normal convention and verify that the near and far z components match the reported correction; done when the definitions are consistent and the relevant MiniEngine sample still builds or runs.

Written by the indexing model from the issue text.

Description

miniengine

https://github.com/microsoft/DirectX-Graphics-Samples/blob/master/MiniEngine/Core/Math/Frustum.cpp
I assume the engine uses a righthanded coordinate system, therefore the definition of the plane normals in function void Frustum::ConstructOrthographicFrustum is inconsistent with this convention. Instead of pointing inward, the normals point outward. m_FrustumPlanes[kNearPlane] = BoundingPlane( 0.0f, 0.0f, 1.0f, -Front );
m_FrustumPlanes[kFarPlane] = BoundingPlane( 0.0f, 0.0f, -1.0f, Back );
The z values of these planes should be -1.0f and 1.0 respectively.

Dominant language
C++
Stars
6.8k
Forks
2.2k
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/DirectX-Graphics-Samples

All issues in microsoft/DirectX-Graphics-Samples

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.