From 4afed801d0568bcd681a3af6dac757ebe71f2103 Mon Sep 17 00:00:00 2001 From: Emil Lauridsen Date: Fri, 25 Mar 2016 17:35:09 +0100 Subject: [PATCH] Fix up Orthographic --- HandmadeMath.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/HandmadeMath.h b/HandmadeMath.h index fcce0d9..aaddbc9 100644 --- a/HandmadeMath.h +++ b/HandmadeMath.h @@ -701,9 +701,9 @@ Orthographic(float Left, float Right, float Bottom, float Top, float Near, float Result.Elements[1][1] = 2.0f / (Top - Bottom); Result.Elements[2][2] = 2.0f / (Near - Far); - Result.Elements[0][3] = (Left + Right) / (Left - Right); - Result.Elements[1][3] = (Bottom + Top) / (Bottom - Top); - Result.Elements[2][3] = (Far + Near) / (Far - Near); + Result.Elements[3][0] = (Left + Right) / (Left - Right); + Result.Elements[3][1] = (Bottom + Top) / (Bottom - Top); + Result.Elements[3][2] = (Far + Near) / (Near - Far); return(Result); }