From 40458be41bac44424dd0dc0d9f7fca58decb7cbd Mon Sep 17 00:00:00 2001 From: Recep Aslantas Date: Sat, 13 Jan 2018 17:27:06 +0300 Subject: [PATCH] frustum: fix array index --- include/cglm/frustum.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/cglm/frustum.h b/include/cglm/frustum.h index 74a1769..7ab761b 100644 --- a/include/cglm/frustum.h +++ b/include/cglm/frustum.h @@ -110,7 +110,7 @@ glm_frustum_corners(mat4 invMat, vec4 dest[8]) { glm_mat4_mulv(invMat, csCoords[6], c[6]); glm_mat4_mulv(invMat, csCoords[7], c[7]); - glm_vec4_scale(c[0], 1.0f / c[1][3], dest[0]); + glm_vec4_scale(c[0], 1.0f / c[0][3], dest[0]); glm_vec4_scale(c[1], 1.0f / c[1][3], dest[1]); glm_vec4_scale(c[2], 1.0f / c[2][3], dest[2]); glm_vec4_scale(c[3], 1.0f / c[3][3], dest[3]);