summaryrefslogtreecommitdiff
path: root/src/refresh/sw/scan.c
diff options
context:
space:
mode:
authorAndrey Nazarov <skuller@skuller.net>2013-03-16 19:26:58 +0400
committerAndrey Nazarov <skuller@skuller.net>2013-03-20 22:04:53 +0400
commit48c4d307ec6c7a3fa75425ffd73bf9eef6bb61fb (patch)
tree80c9c8dd364b04e0bdae3ba92f649a48abe202d2 /src/refresh/sw/scan.c
parent5b90200a5fb8facbb431c789f37495ed7a6e9c10 (diff)
Use TURB_SIZE constant where appropriate.
Also force resampling of all turbulent textures to 64x64.
Diffstat (limited to 'src/refresh/sw/scan.c')
-rw-r--r--src/refresh/sw/scan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/refresh/sw/scan.c b/src/refresh/sw/scan.c
index 5833fe4..b885a20 100644
--- a/src/refresh/sw/scan.c
+++ b/src/refresh/sw/scan.c
@@ -195,9 +195,9 @@ void D_DrawTurbulent16(espan_t *pspan, int *warptable)
t = t & ((CYCLE << 16) - 1);
do {
- turb_s = ((s + turb[(t >> 16) & (CYCLE - 1)]) >> 16) & 63;
- turb_t = ((t + turb[(s >> 16) & (CYCLE - 1)]) >> 16) & 63;
- ptex = pbase + (turb_t * 64 * TEX_BYTES) + turb_s * TEX_BYTES;
+ turb_s = ((s + turb[(t >> 16) & (CYCLE - 1)]) >> 16) & TURB_MASK;
+ turb_t = ((t + turb[(s >> 16) & (CYCLE - 1)]) >> 16) & TURB_MASK;
+ ptex = pbase + (turb_t * TURB_SIZE * TEX_BYTES) + turb_s * TEX_BYTES;
pdest[0] = ptex[2];
pdest[1] = ptex[1];
pdest[2] = ptex[0];