diff --git a/glm/gtc/matrix_transform.inl b/glm/gtc/matrix_transform.inl index df9b7ae9..556fd190 100644 --- a/glm/gtc/matrix_transform.inl +++ b/glm/gtc/matrix_transform.inl @@ -238,6 +238,9 @@ namespace glm valType const & zFar ) { + assert(aspect != valType(0)); + assert(zFar != zNear); + #ifdef GLM_FORCE_RADIANS valType const rad = fovy; #else @@ -284,8 +287,8 @@ namespace glm template GLM_FUNC_QUALIFIER detail::tmat4x4 infinitePerspective ( - T fovy, - T aspect, + T fovy, + T aspect, T zNear ) {