Browse Source

Merge pull request #37601 from BastiaanOlij/fix_hmd_projection

Fix aspect ratio on hmd projection matrix
Rémi Verschelde 5 years ago
parent
commit
4f00a2c645
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core/math/camera_matrix.cpp

+ 1 - 1
core/math/camera_matrix.cpp

@@ -145,7 +145,7 @@ void CameraMatrix::set_for_hmd(int p_eye, real_t p_aspect, real_t p_intraocular_
 	f3 *= p_oversample;
 
 	// always apply KEEP_WIDTH aspect ratio
-	f3 *= p_aspect;
+	f3 /= p_aspect;
 
 	switch (p_eye) {
 		case 1: { // left eye