MCPcopy Create free account
hub / github.com/ZDoom/Raze / V_Init2

Function V_Init2

source/common/rendering/v_video.cpp:388–415  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

386}
387
388void V_Init2()
389{
390 {
391 DFrameBuffer *s = screen;
392 screen = NULL;
393 delete s;
394 }
395
396 UCVarValue val;
397
398 val.Bool = !!Args->CheckParm("-devparm");
399 ticker->SetGenericRepDefault(val, CVAR_Bool);
400
401
402 I_InitGraphics();
403
404 Video->SetResolution(); // this only fails via exceptions.
405 Printf ("Resolution: %d x %d\n", SCREENWIDTH, SCREENHEIGHT);
406
407 // init these for the scaling menu
408 menu_resolution_custom_width = SCREENWIDTH;
409 menu_resolution_custom_height = SCREENHEIGHT;
410
411 screen->SetVSync(vid_vsync);
412 FBaseCVar::ResetColors ();
413 C_NewModeAdjust();
414 setsizeneeded = true;
415}
416
417CUSTOM_CVAR (Int, vid_aspect, 0, CVAR_GLOBALCONFIG|CVAR_ARCHIVE)
418{

Callers 1

RunGameFunction · 0.85

Calls 7

PrintfFunction · 0.85
C_NewModeAdjustFunction · 0.85
CheckParmMethod · 0.80
SetGenericRepDefaultMethod · 0.80
SetResolutionMethod · 0.80
I_InitGraphicsFunction · 0.50
SetVSyncMethod · 0.45

Tested by

no test coverage detected