#include <math.h>
Go to the source code of this file.
Functions | |
bool | good (REAL f) |
static bool | clamp (REAL &c, REAL min, REAL max) |
Definition at line 49 of file tMath.h.
References tASSERT.
Referenced by gCycleMovement::ApplyAcceleration(), gCycleMovement::Timestep(), gCycleMovement::TimestepCore(), gCycle::TimestepCore(), and gFloatCompressor::Write().
00049 { 00050 tASSERT(min <= max); 00051 00052 if (!finite(c)) 00053 { 00054 c = 0; 00055 return true; 00056 } 00057 00058 if (c<min) 00059 { 00060 c = min; 00061 return true; 00062 } 00063 00064 if (c>max) 00065 { 00066 c = max; 00067 return true; 00068 } 00069 00070 return false; 00071 }
bool good | ( | REAL | f | ) | [inline] |
Definition at line 44 of file tMath.h.
Referenced by gCycleMovement::ApplyAcceleration(), gCycleMovement::CalculateAcceleration(), eGrid::DrawLine(), gPlayerWall::GlobalToLocal(), gPlayerWall::LocalToGlobal(), main(), eGameObject::Move(), gNetPlayerWall::Pos(), gPlayerWall::Pos(), gNetPlayerWall::Time(), and gPlayerWall::Time().