FOV fixes

# Conflicts:
#	src/r_main.c
This commit is contained in:
colette 2020-03-07 18:24:22 -05:00 committed by Wolfy
parent bf1060f7ac
commit 38cd01b1d3

View file

@ -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;