[quake3-commits] r1570 - trunk/code/renderer

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Wed Jun 10 05:00:31 EDT 2009


Author: thilo
Date: 2009-06-10 05:00:31 -0400 (Wed, 10 Jun 2009)
New Revision: 1570

Modified:
   trunk/code/renderer/tr_main.c
Log:
minor code cleanup


Modified: trunk/code/renderer/tr_main.c
===================================================================
--- trunk/code/renderer/tr_main.c	2009-06-10 08:25:01 UTC (rev 1569)
+++ trunk/code/renderer/tr_main.c	2009-06-10 09:00:31 UTC (rev 1570)
@@ -513,22 +513,19 @@
 void R_SetupProjection(viewParms_t *dest, float zProj, qboolean computeFrustum)
 {
 	float	xmin, xmax, ymin, ymax;
-	float	width, height, stereoSep = r_stereoSeparation->value;
+	float	width, height, stereoSep;
 
 	/*
 	 * offset the view origin of the viewer for stereo rendering 
 	 * by setting the projection matrix appropriately.
 	 */
 
-	if(stereoSep != 0)
-	{
-		if(dest->stereoFrame == STEREO_LEFT)
-			stereoSep = zProj / r_stereoSeparation->value;
-		else if(dest->stereoFrame == STEREO_RIGHT)
-			stereoSep = zProj / -r_stereoSeparation->value;
-		else
-			stereoSep = 0;
-	}
+	if(dest->stereoFrame == STEREO_LEFT)
+		stereoSep = zProj / r_stereoSeparation->value;
+	else if(dest->stereoFrame == STEREO_RIGHT)
+		stereoSep = zProj / -r_stereoSeparation->value;
+	else
+		stereoSep = 0;
 
 	ymax = zProj * tan(dest->fovY * M_PI / 360.0f);
 	ymin = -ymax;



More information about the quake3-commits mailing list