From 38cd01b1d337be716a972ca122598e7032c7cbb9 Mon Sep 17 00:00:00 2001 From: colette Date: Sat, 7 Mar 2020 18:24:22 -0500 Subject: [PATCH] FOV fixes # Conflicts: # src/r_main.c --- src/r_main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/r_main.c b/src/r_main.c index d19f2575..5ef40179 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -137,7 +137,7 @@ static CV_PossibleValue_t drawdist_precip_cons_t[] = { {1024, "1024"}, {1536, "1536"}, {2048, "2048"}, {0, "None"}, {0, NULL}}; -static CV_PossibleValue_t fov_cons_t[] = {{45*FRACUNIT, "MIN"}, {120*FRACUNIT, "MAX"}, {0, NULL}}; +static CV_PossibleValue_t fov_cons_t[] = {{5*FRACUNIT, "MIN"}, {178*FRACUNIT, "MAX"}, {0, NULL}}; //static CV_PossibleValue_t precipdensity_cons_t[] = {{0, "None"}, {1, "Light"}, {2, "Moderate"}, {4, "Heavy"}, {6, "Thick"}, {8, "V.Thick"}, {0, NULL}}; static CV_PossibleValue_t translucenthud_cons_t[] = {{0, "MIN"}, {10, "MAX"}, {0, NULL}}; @@ -542,9 +542,9 @@ static void R_InitTextureMapping(void) for (i = 0; i < FINEANGLES/2; i++) { - if (FINETANGENT(i) > FRACUNIT*2) + if (FINETANGENT(i) > fovtan*2) t = -1; - else if (FINETANGENT(i) < -FRACUNIT*2) + else if (FINETANGENT(i) < -fovtan*2) t = viewwidth+1; else { @@ -835,7 +835,7 @@ static void R_SetupFreelook(void) if (rendermode == render_soft) { - dy = (AIMINGTODY(aimingangle)>>FRACBITS) * viewwidth/BASEVIDWIDTH; + dy = (AIMINGTODY(aimingangle)/fovtan) * viewwidth/BASEVIDWIDTH; yslope = &yslopetab[viewheight*8 - (viewheight/2 + dy)]; } centery = (viewheight/2) + dy;