]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - cl_screen.c
i'm sure there are plenty of bugs here for you guys to fix
[xonotic/darkplaces.git] / cl_screen.c
index 7f53840b751c51e2dad92edf988b9758d3cc8bfa..2a83ee0c681ccf61718fee685443ba3483865942 100644 (file)
@@ -112,10 +112,9 @@ void SCR_DrawCenterString (void)
        int             remaining;
        int             color;
 
-       if(gamemode == GAME_NEXUIZ)
-               if(cl.intermission == 2) // in Nexuiz finale (voting screen),
-                       if(sb_showscores) // make TAB hide vote messages
-                               return;
+       if(cl.intermission == 2) // in finale,
+               if(sb_showscores) // make TAB hide the finale message (sb_showscores overrides finale in sbar.c)
+                       return;
 
 // the finale prints the characters one at a time, except if printspeed is an absurdly high value
        if (cl.intermission && scr_printspeed.value > 0 && scr_printspeed.value < 1000000)
@@ -601,7 +600,6 @@ void SCR_BeginLoadingPlaque (void)
        Log_Start();
 
        Host_StartVideo();
-       S_StopAllSounds();
        SCR_UpdateLoadingScreen(false);
 }
 
@@ -1173,7 +1171,7 @@ Cr = R *  .500 + G * -.419 + B * -.0813 + 128.;
                SCR_CaptureVideo_RIFF_Push("vprp", NULL);
                SCR_CaptureVideo_RIFF_Write32(0); // VideoFormatToken
                SCR_CaptureVideo_RIFF_Write32(0); // VideoStandard
-               SCR_CaptureVideo_RIFF_Write32(cls.capturevideo.framerate); // dwVerticalRefreshRate (bogus)
+               SCR_CaptureVideo_RIFF_Write32((int)cls.capturevideo.framerate); // dwVerticalRefreshRate (bogus)
                SCR_CaptureVideo_RIFF_Write32(width); // dwHTotalInT
                SCR_CaptureVideo_RIFF_Write32(height); // dwVTotalInLines
                FindFraction(aspect, &n, &d, 1000);
@@ -1581,6 +1579,7 @@ static void R_Envmap_f (void)
        r_view.width = size;
        r_view.height = size;
        r_view.depth = 1;
+       r_view.useperspective = true;
 
        r_view.frustum_x = tan(90 * M_PI / 360.0);
        r_view.frustum_y = tan(90 * M_PI / 360.0);
@@ -1781,6 +1780,10 @@ void SCR_DrawScreen (void)
 
        R_UpdateVariables();
 
+       // Quake uses clockwise winding, so these are swapped
+       r_view.cullface_front = GL_BACK;
+       r_view.cullface_back = GL_FRONT;
+
        if (cls.signon == SIGNONS)
        {
                float size;
@@ -1815,6 +1818,7 @@ void SCR_DrawScreen (void)
                // this it simply assumes the requested fov is the vertical fov
                // for a 4x3 display, if the ratio is not 4x3 this makes the fov
                // higher/lower according to the ratio
+               r_view.useperspective = true;
                r_view.frustum_y = tan(scr_fov.value * M_PI / 360.0) * (3.0/4.0) * cl.viewzoom;
                r_view.frustum_x = r_view.frustum_y * (float)r_view.width / (float)r_view.height / vid_pixelheight.value;
 
@@ -1835,6 +1839,7 @@ void SCR_DrawScreen (void)
                        r_view.y = 0;
                        r_view.z = 0;
 
+                       r_view.useperspective = true;
                        r_view.frustum_y = tan(scr_zoomwindow_fov.value * M_PI / 360.0) * (3.0/4.0) * cl.viewzoom;
                        r_view.frustum_x = r_view.frustum_y * vid_pixelheight.value * (float)r_view.width / (float)r_view.height;
 
@@ -1854,6 +1859,7 @@ void SCR_DrawScreen (void)
                r_view.x = 0;
                r_view.y = 0;
                r_view.z = 0;
+               r_view.useperspective = false;
        }
 
        // draw 2D stuff
@@ -1928,6 +1934,7 @@ void SCR_UpdateLoadingScreen (qboolean clear)
        GL_Color(1,1,1,1);
        GL_BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
        GL_DepthRange(0, 1);
+       GL_PolygonOffset(0, 0);
        GL_DepthTest(false);
        R_Mesh_VertexPointer(vertex3f, 0, 0);
        R_Mesh_ColorPointer(NULL, 0, 0);