From cdb9e7ef8f27fa929b2d305cf444c4903b50534c Mon Sep 17 00:00:00 2001 From: Simon Date: Fri, 18 Mar 2022 22:41:01 +0000 Subject: [PATCH] Update cg_view.c --- android/app/src/main/cpp/code/cgame/cg_view.c | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/android/app/src/main/cpp/code/cgame/cg_view.c b/android/app/src/main/cpp/code/cgame/cg_view.c index 24937581..358d8014 100644 --- a/android/app/src/main/cpp/code/cgame/cg_view.c +++ b/android/app/src/main/cpp/code/cgame/cg_view.c @@ -513,17 +513,17 @@ Fixed fov at intermissions, otherwise account for fov variable and zooms. #define WAVE_FREQUENCY 0.4 static int CG_CalcFov( void ) { - float x; + int contents; + int inwater; float phase; float v; - int contents; +/* float x; float fov_x, fov_y; float zoomFov; float f; - int inwater; -/* + if ( cg.predictedPlayerState.pm_type == PM_INTERMISSION ) { // if in intermission, use a fixed value fov_x = 90; @@ -574,8 +574,8 @@ static int CG_CalcFov( void ) { if ( contents & ( CONTENTS_WATER | CONTENTS_SLIME | CONTENTS_LAVA ) ){ phase = cg.time / 1000.0 * WAVE_FREQUENCY * M_PI * 2; v = WAVE_AMPLITUDE * sin( phase ); - fov_x += v; - fov_y -= v; +// fov_x += v; +// fov_y -= v; inwater = qtrue; } else { @@ -583,9 +583,8 @@ static int CG_CalcFov( void ) { } - // Seems we can get away with actually using 10 degrees less on the FOV - cg.refdef.fov_x = vr->fov_x - 10; - cg.refdef.fov_y = vr->fov_y - 10; + cg.refdef.fov_x = vr->fov_x; + cg.refdef.fov_y = vr->fov_y; if ( !cg.zoomed ) { cg.zoomSensitivity = 1; @@ -593,7 +592,8 @@ static int CG_CalcFov( void ) { cg.zoomSensitivity = cg.refdef.fov_y / 75.0; } - return inwater; + //We don't do the under-water fov warping in VR + return qfalse; //inwater; }