From 182c230c103981bb5ebcb6ee7d3bbd3377dcb028 Mon Sep 17 00:00:00 2001 From: ikpil Date: Wed, 25 Oct 2023 00:17:20 +0900 Subject: [PATCH] refactor: Math.Tan -> MatF.Tan --- src/DotRecast.Recast.Demo/Draw/GLU.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DotRecast.Recast.Demo/Draw/GLU.cs b/src/DotRecast.Recast.Demo/Draw/GLU.cs index 8ea91d8..e1d5b5d 100644 --- a/src/DotRecast.Recast.Demo/Draw/GLU.cs +++ b/src/DotRecast.Recast.Demo/Draw/GLU.cs @@ -35,7 +35,7 @@ public static class GLU public static void GlhPerspectivef2(ref RcMatrix4x4f matrix, float fovyInDegrees, float aspectRatio, float znear, float zfar) { float ymax, xmax; - ymax = (float)(znear * Math.Tan(fovyInDegrees * MathF.PI / 360.0)); + ymax = znear * MathF.Tan(fovyInDegrees * MathF.PI / 360); xmax = ymax * aspectRatio; GlhFrustumf2(ref matrix, -xmax, xmax, -ymax, ymax, znear, zfar); }