X-Git-Url: http://git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=cl_screen.c;h=44b493e4771d4105abb1e3750fe54951a9f174f3;hp=5b97ccb6c1786cad9d98707ed371aa2ce3155e60;hb=7ea07939bef0cbe85c54d9f68cb924198b0b1f64;hpb=5ad6c0e8577478422c10d7ae79fb61b88ac5ae85 diff --git a/cl_screen.c b/cl_screen.c index 5b97ccb6..44b493e4 100644 --- a/cl_screen.c +++ b/cl_screen.c @@ -285,12 +285,12 @@ static void SCR_DrawNetGraph_DrawGraph (int graphx, int graphy, int graphwidth, b = g[(j+1)%NETGRAPH_PACKETS]; if (a[0] < 0.0f || b[0] > 1.0f || b[0] < a[0]) continue; - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[2], graphx + graphwidth * b[0], graphy + graphheight * b[2], 1.0f, 1.0f, 1.0f, 1.0f, 0, true); - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[1], graphx + graphwidth * b[0], graphy + graphheight * b[1], 1.0f, 0.0f, 0.0f, 1.0f, 0, true); - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[5], graphx + graphwidth * b[0], graphy + graphheight * b[5], 0.0f, 1.0f, 0.0f, 1.0f, 0, true); - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[4], graphx + graphwidth * b[0], graphy + graphheight * b[4], 1.0f, 1.0f, 1.0f, 1.0f, 0, true); - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[3], graphx + graphwidth * b[0], graphy + graphheight * b[3], 1.0f, 0.5f, 0.0f, 1.0f, 0, true); - DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[6], graphx + graphwidth * b[0], graphy + graphheight * b[6], 0.0f, 0.0f, 1.0f, 1.0f, 0, true); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[2], graphx + graphwidth * b[0], graphy + graphheight * b[2], 1.0f, 1.0f, 1.0f, 1.0f, 0); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[1], graphx + graphwidth * b[0], graphy + graphheight * b[1], 1.0f, 0.0f, 0.0f, 1.0f, 0); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[5], graphx + graphwidth * b[0], graphy + graphheight * b[5], 0.0f, 1.0f, 0.0f, 1.0f, 0); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[4], graphx + graphwidth * b[0], graphy + graphheight * b[4], 1.0f, 1.0f, 1.0f, 1.0f, 0); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[3], graphx + graphwidth * b[0], graphy + graphheight * b[3], 1.0f, 0.5f, 0.0f, 1.0f, 0); + DrawQ_Line(1, graphx + graphwidth * a[0], graphy + graphheight * a[6], graphx + graphwidth * b[0], graphy + graphheight * b[6], 0.0f, 0.0f, 1.0f, 1.0f, 0); } x = graphx; y = graphy + graphheight; @@ -835,7 +835,7 @@ void CL_Screen_Init(void) Cvar_RegisterVariable(&scr_stipple); Cvar_RegisterVariable(&scr_refresh); Cvar_RegisterVariable(&net_graph); - Cvar_RegisterAlias(&net_graph, "shownetgraph"); + Cvar_RegisterVirtual(&net_graph, "shownetgraph"); Cvar_RegisterVariable(&cl_demo_mousegrab); Cvar_RegisterVariable(&timedemo_screenshotframelist); Cvar_RegisterVariable(&vid_touchscreen_outlinealpha); @@ -1206,7 +1206,7 @@ static void SCR_CaptureVideo_VideoFrame(int newframestepframenum) double fps1 = (cls.capturevideo.frame - cls.capturevideo.lastfpsframe) / (t - cls.capturevideo.lastfpstime + 0.0000001); double fps = (cls.capturevideo.frame ) / (t - cls.capturevideo.starttime + 0.0000001); dpsnprintf(buf, sizeof(buf), "capturevideo: (%.1fs) last second %.3ffps, total %.3ffps\n", cls.capturevideo.frame / cls.capturevideo.framerate, fps1, fps); - Sys_PrintToTerminal(buf); + Sys_Print(buf); cls.capturevideo.lastfpstime = t; cls.capturevideo.lastfpsframe = cls.capturevideo.frame; } @@ -2309,7 +2309,11 @@ void CL_UpdateScreen(void) memcpy(palette_rgb_shirtscoreboard[15], palette_rgb_shirtcolormap[15], sizeof(*palette_rgb_shirtcolormap)); } +#ifdef CONFIG_VIDEO_CAPTURE + if (vid_hidden && !cls.capturevideo.active && !cl_capturevideo.integer) +#else if (vid_hidden) +#endif { VID_Finish(); return;