Skip to content

Commit

Permalink
Fix #89: add magic 1.5 offset to navball renderer camera depth
Browse files Browse the repository at this point in the history
  • Loading branch information
JonnyOThan committed May 5, 2023
1 parent 6cbb874 commit fa64664
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion RasterPropMonitor/Handlers/JSIPrimaryFlightDisplay.cs
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ public bool RenderPFD(RenderTexture screen, float aspect)
// I wonder if doing this as a command buffer might be more efficient?

GL.PushMatrix();
GL.LoadProjectionMatrix(Matrix4x4.Ortho(-cameraSpan, cameraSpan, -cameraSpan, cameraSpan, 0, navballRadius * 3));
GL.LoadProjectionMatrix(Matrix4x4.Ortho(-cameraSpan, cameraSpan, -cameraSpan, cameraSpan, 0, 1.5f + navballRadius * 3));

var navballMeshFilter = navBall.GetComponent<MeshFilter>();
var navballRenderer = navBall.GetComponent<MeshRenderer>();
Expand Down

0 comments on commit fa64664

Please sign in to comment.