summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/r_main.c2
-rw-r--r--src/tables.c6
-rw-r--r--src/tables.h9
3 files changed, 9 insertions, 8 deletions
diff --git a/src/r_main.c b/src/r_main.c
index eec74ae0..e6a08691 100644
--- a/src/r_main.c
+++ b/src/r_main.c
@@ -113,7 +113,7 @@ angle_t xtoviewangle[SCREENWIDTH+1];
// fixed_t finetangent[FINEANGLES/2];
// fixed_t finesine[5*FINEANGLES/4];
-fixed_t* finecosine = &finesine[FINEANGLES/4];
+const fixed_t* finecosine = &finesine[FINEANGLES/4];
lighttable_t* scalelight[LIGHTLEVELS][MAXLIGHTSCALE];
diff --git a/src/tables.c b/src/tables.c
index 7e2a2647..ffafeb7e 100644
--- a/src/tables.c
+++ b/src/tables.c
@@ -65,7 +65,7 @@ SlopeDiv
-int finetangent[4096] =
+const int finetangent[4096] =
{
-170910304,-56965752,-34178904,-24413316,-18988036,-15535599,-13145455,-11392683,
-10052327,-8994149,-8137527,-7429880,-6835455,-6329090,-5892567,-5512368,
@@ -582,7 +582,7 @@ int finetangent[4096] =
};
-int finesine[10240] =
+const int finesine[10240] =
{
25,75,125,175,226,276,326,376,
427,477,527,578,628,678,728,779,
@@ -1868,7 +1868,7 @@ int finesine[10240] =
-angle_t tantoangle[2049] =
+const angle_t tantoangle[2049] =
{
0,333772,667544,1001315,1335086,1668857,2002626,2336395,
2670163,3003929,3337694,3671457,4005219,4338979,4672736,5006492,
diff --git a/src/tables.h b/src/tables.h
index 54004d79..baf785ca 100644
--- a/src/tables.h
+++ b/src/tables.h
@@ -53,14 +53,14 @@
#define ANGLETOFINESHIFT 19
// Effective size is 10240.
-extern fixed_t finesine[5*FINEANGLES/4];
+extern const fixed_t finesine[5*FINEANGLES/4];
// Re-use data, is just PI/2 pahse shift.
-extern fixed_t* finecosine;
+extern const fixed_t *finecosine;
// Effective size is 4096.
-extern fixed_t finetangent[FINEANGLES/2];
+extern const fixed_t finetangent[FINEANGLES/2];
// Binary Angle Measument, BAM.
#define ANG45 0x20000000
@@ -79,7 +79,7 @@ typedef unsigned angle_t;
// Effective size is 2049;
// The +1 size is to handle the case when x==y
// without additional checking.
-extern angle_t tantoangle[SLOPERANGE+1];
+extern const angle_t tantoangle[SLOPERANGE+1];
// Utility function,
@@ -91,3 +91,4 @@ SlopeDiv
#endif
+