summaryrefslogtreecommitdiff
path: root/src/tables.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/tables.h')
-rw-r--r--src/tables.h28
1 files changed, 19 insertions, 9 deletions
diff --git a/src/tables.h b/src/tables.h
index baf785ca..f4fd1f55 100644
--- a/src/tables.h
+++ b/src/tables.h
@@ -2,6 +2,7 @@
//-----------------------------------------------------------------------------
//
// Copyright(C) 1993-1996 Id Software, Inc.
+// Copyright(C) 1993-2008 Raven Software
// Copyright(C) 2005 Simon Howard
//
// This program is free software; you can redistribute it and/or
@@ -41,7 +42,7 @@
#ifndef __TABLES__
#define __TABLES__
-
+#include "doomtype.h"
#include "m_fixed.h"
@@ -62,12 +63,24 @@ extern const fixed_t *finecosine;
// Effective size is 4096.
extern const fixed_t finetangent[FINEANGLES/2];
+// Gamma correction tables.
+extern const byte gammatable[5][256];
+
// Binary Angle Measument, BAM.
-#define ANG45 0x20000000
-#define ANG90 0x40000000
-#define ANG180 0x80000000
-#define ANG270 0xc0000000
+#define ANG45 0x20000000
+#define ANG90 0x40000000
+#define ANG180 0x80000000
+#define ANG270 0xc0000000
+#define ANG_MAX 0xffffffff
+
+#define ANG1 (ANG45 / 45)
+#define ANG60 (ANG180 / 3)
+
+// Heretic code uses this definition as though it represents one
+// degree, but it is not! This is actually ~1.40 degrees.
+
+#define ANG1_X 0x01000000
#define SLOPERANGE 2048
#define SLOPEBITS 11
@@ -84,10 +97,7 @@ extern const angle_t tantoangle[SLOPERANGE+1];
// Utility function,
// called by R_PointToAngle.
-int
-SlopeDiv
-( unsigned num,
- unsigned den);
+int SlopeDiv(unsigned int num, unsigned int den);
#endif