diff --git a/nalgebra-glm/src/ext/matrix_clip_space.rs b/nalgebra-glm/src/ext/matrix_clip_space.rs index c0f3f128..813fe8fc 100644 --- a/nalgebra-glm/src/ext/matrix_clip_space.rs +++ b/nalgebra-glm/src/ext/matrix_clip_space.rs @@ -90,9 +90,13 @@ pub fn ortho(left: N, right: N, bottom: N, top: N, znear: N, zfar: N) - // unimplemented!() //} -/// Creates a matrix for a symmetric perspective-view frustum based on the right handedness and OpenGL near and far clip planes definition. -pub fn perspective(fovy: N, aspect: N, near: N, far: N) -> TMat4 { - Perspective3::new(fovy, aspect, near, far).unwrap() + +/// Creates a matrix for a perspective-view frustum based on the right handedness and OpenGL near and far clip planes definition. +/// +/// # Important note +/// The `aspect` and `fovy` argument are interchanged compared to the original GLM API. +pub fn perspective(aspect: N, fovy: N, near: N, far: N) -> TMat4 { + Perspective3::new(aspect, fovy, near, far).unwrap() } //pub fn perspective_fov(fov: N, width: N, height: N, near: N, far: N) -> TMat4 {