Skip to content

Commit a8584b4

Browse files
committed
Radians please.
1 parent e6357c7 commit a8584b4

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

Kore

Sources/kha/math/FastMatrix4.hx

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ class FastMatrix4 {
124124
}
125125

126126
public static function perspectiveProjection(fovY: FastFloat, aspect: FastFloat, zn: FastFloat, zf: FastFloat): FastMatrix4 {
127-
var uh = 1.0 / Math.tan((fovY / 2) * (Math.PI / 180));
127+
var uh = 1.0 / Math.tan(fovY / 2);
128128
var uw = uh / aspect;
129129
return new FastMatrix4(
130130
uw, 0, 0, 0,

Sources/kha/math/Matrix4.hx

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ class Matrix4 {
117117
}
118118

119119
public static function perspectiveProjection(fovY: Float, aspect: Float, zn: Float, zf: Float): Matrix4 {
120-
var uh = 1.0 / Math.tan((fovY / 2) * (Math.PI / 180));
120+
var uh = 1.0 / Math.tan(fovY / 2);
121121
var uw = uh / aspect;
122122
return new Matrix4(
123123
uw, 0, 0, 0,

0 commit comments

Comments
 (0)