]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - gl_draw.c
fix a logic bug in EntLight handling (should have been checking r_shadow_realtime_wor...
[xonotic/darkplaces.git] / gl_draw.c
index f0905e98d787051e07beeef4f25cb349902b1a04..7ba2282e38eb8bc0eff765055c6a3e6abd87ff38 100644 (file)
--- a/gl_draw.c
+++ b/gl_draw.c
@@ -511,11 +511,11 @@ void R_DrawQueue(void)
                        {
                                // We have to convert the con coords into real coords
                                int x , y, width, height;
-                               x = dq->x * (vid.realwidth / vid.conwidth) + vid.realx;
+                               x = dq->x * ((float)vid.realwidth / vid.conwidth);
                                // OGL uses top to bottom 
-                               y = (dq->y + dq->scaley) * (vid.realheight / vid.conheight) + vid.realy;
-                               width = dq->scalex * (vid.realwidth / vid.conwidth);
-                               height = dq->scaley * (vid.realheight / vid.conheight);
+                               y = dq->y * ((float) vid.realheight / vid.conheight);
+                               width = dq->scalex * ((float)vid.realwidth / vid.conwidth);
+                               height = dq->scaley * ((float)vid.realheight / vid.conheight);
 
                                GL_Scissor(x, y, width, height);