aboutsummaryrefslogtreecommitdiffstats
path: root/src/jake2/render/jogl/Warp.java
diff options
context:
space:
mode:
authorHolger Zickner <[email protected]>2004-07-08 15:58:48 +0000
committerHolger Zickner <[email protected]>2004-07-08 15:58:48 +0000
commit4f13ea26c4f47e54e66926f0700cf631e7bb3352 (patch)
treea9d434fc462417bb981b1565fd64cea5e7c82c15 /src/jake2/render/jogl/Warp.java
parent76839da3568e20f51220584d1fc92841b216505a (diff)
import of Jake2 version hannover
Diffstat (limited to 'src/jake2/render/jogl/Warp.java')
-rw-r--r--src/jake2/render/jogl/Warp.java20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/jake2/render/jogl/Warp.java b/src/jake2/render/jogl/Warp.java
index 770d50b..f02acbb 100644
--- a/src/jake2/render/jogl/Warp.java
+++ b/src/jake2/render/jogl/Warp.java
@@ -2,7 +2,7 @@
* Warp.java
* Copyright (C) 2003
*
- * $Id: Warp.java,v 1.1 2004-07-07 19:59:44 hzi Exp $
+ * $Id: Warp.java,v 1.2 2004-07-08 15:58:45 hzi Exp $
*/
/*
Copyright (C) 1997-2001 Id Software, Inc.
@@ -446,7 +446,7 @@ public abstract class Warp extends Model {
float[] dists = new float[MAX_CLIP_VERTS];
int[] sides = new int[MAX_CLIP_VERTS];
- float[][][] newv = new float[2][MAX_CLIP_VERTS][3];
+ float[][][][] newv = new float[6][2][MAX_CLIP_VERTS][3];
void ClipSkyPolygon(int nump, float[][] vecs, int stage)
{
@@ -503,17 +503,17 @@ public abstract class Warp extends Model {
switch (sides[i])
{
case SIDE_FRONT:
- Math3D.VectorCopy(v, newv[0][newc[0]]);
+ Math3D.VectorCopy(v, newv[stage][0][newc[0]]);
newc[0]++;
break;
case SIDE_BACK:
- Math3D.VectorCopy(v, newv[1][newc[1]]);
+ Math3D.VectorCopy(v, newv[stage][1][newc[1]]);
newc[1]++;
break;
case SIDE_ON:
- Math3D.VectorCopy(v, newv[0][newc[0]]);
+ Math3D.VectorCopy(v, newv[stage][0][newc[0]]);
newc[0]++;
- Math3D.VectorCopy (v, newv[1][newc[1]]);
+ Math3D.VectorCopy (v, newv[stage][1][newc[1]]);
newc[1]++;
break;
}
@@ -525,16 +525,16 @@ public abstract class Warp extends Model {
for (j=0 ; j<3 ; j++)
{
e = v[j] + d * (vecs[i + 1][j] - v[j]);
- newv[0][newc[0]][j] = e;
- newv[1][newc[1]][j] = e;
+ newv[stage][0][newc[0]][j] = e;
+ newv[stage][1][newc[1]][j] = e;
}
newc[0]++;
newc[1]++;
}
// continue
- ClipSkyPolygon(newc[0], newv[0], stage+1);
- ClipSkyPolygon(newc[1], newv[1], stage+1);
+ ClipSkyPolygon(newc[0], newv[stage][0], stage+1);
+ ClipSkyPolygon(newc[1], newv[stage][1], stage+1);
}
float[][] verts = new float[MAX_CLIP_VERTS][3];