ref: ad13f9f26caa0d03fd71750bd20e834803693887
parent: 9f994d9c980cf5fb64246b2cc1572e043dff6752
author: Simon Howard <fraggle@gmail.com>
date: Fri Mar 3 14:18:48 EST 2006
Fix loss of precision when turning with mouse. Subversion-branch: /trunk/chocolate-doom Subversion-revision: 407
--- a/src/i_video.c
+++ b/src/i_video.c
@@ -1,7 +1,7 @@
// Emacs style mode select -*- C++ -*-
//-----------------------------------------------------------------------------
//
-// $Id: i_video.c 283 2006-01-12 01:34:48Z fraggle $
+// $Id: i_video.c 407 2006-03-03 19:18:48Z fraggle $
//
// Copyright(C) 1993-1996 Id Software, Inc.
// Copyright(C) 2005 Simon Howard
@@ -175,7 +175,7 @@
//-----------------------------------------------------------------------------
static const char
-rcsid[] = "$Id: i_video.c 283 2006-01-12 01:34:48Z fraggle $";
+rcsid[] = "$Id: i_video.c 407 2006-03-03 19:18:48Z fraggle $";
#include <SDL.h>
#include <ctype.h>
@@ -454,7 +454,7 @@
if (val < 0)
return -AccelerateMouse(-val);
- return (int) pow(val, mouse_acceleration) / 5;
+ return (int) pow(((float) val) / mouse_acceleration, mouse_acceleration);
}
void I_GetEvent(void)