diff options
author | Carsten Weisse <[email protected]> | 2007-02-27 14:42:45 +0000 |
---|---|---|
committer | Carsten Weisse <[email protected]> | 2007-02-27 14:42:45 +0000 |
commit | 9de8df15d2a518468e26481c8380dbb3bdda98be (patch) | |
tree | 5ec7ae2fc3cbd03b2949776e7882d5ee40dac597 /src/jake2/render | |
parent | 63dee8b5dc571906032dd54485cf8d479f22c8c9 (diff) |
clean up
Diffstat (limited to 'src/jake2/render')
-rw-r--r-- | src/jake2/render/basic/Surf.java | 25 | ||||
-rw-r--r-- | src/jake2/render/basic/Warp.java | 5 |
2 files changed, 11 insertions, 19 deletions
diff --git a/src/jake2/render/basic/Surf.java b/src/jake2/render/basic/Surf.java index 31ecf24..3d88373 100644 --- a/src/jake2/render/basic/Surf.java +++ b/src/jake2/render/basic/Surf.java @@ -1,8 +1,6 @@ /* * Surf.java * Copyright (C) 2003 - * - * $Id: Surf.java,v 1.2 2006-11-21 00:50:46 cawe Exp $ */ /* Copyright (C) 1997-2001 Id Software, Inc. @@ -681,9 +679,8 @@ public abstract class Surf extends Draw { void GL_RenderLightmappedPoly( msurface_t surf ) { - int i, nv = surf.polys.numverts; - int map = 0; - float[] v; + int nv = surf.polys.numverts; + int map; image_t image = R_TextureAnimation( surf.texinfo ); boolean is_dynamic = false; int lmtex = surf.lightmaptexturenum; @@ -777,7 +774,7 @@ public abstract class Surf extends Draw { for ( p = surf.polys; p != null; p = p.chain ) { gl.glBegin (GL_POLYGON); - for (i=0 ; i< nv; i++) + for (int i=0 ; i< nv; i++) { gl.glMultiTexCoord2f(GL_TEXTURE0, p.s1(i) + scroll, p.t1(i)); gl.glMultiTexCoord2f(GL_TEXTURE1, p.s2(i), p.t2(i)); @@ -793,7 +790,7 @@ public abstract class Surf extends Draw { for ( p = surf.polys; p != null; p = p.chain ) { gl.glBegin (GL_POLYGON); - for (i=0 ; i< nv; i++) + for (int i=0 ; i< nv; i++) { gl.glMultiTexCoord2f(GL_TEXTURE0, p.s1(i), p.t1(i)); gl.glMultiTexCoord2f(GL_TEXTURE1, p.s2(i), p.t2(i)); @@ -827,7 +824,7 @@ public abstract class Surf extends Draw { for ( p = surf.polys; p != null; p = p.chain ) { gl.glBegin(GL_POLYGON); - for (i=0 ; i< nv; i++) + for (int i=0 ; i< nv; i++) { gl.glMultiTexCoord2f(GL_TEXTURE0, p.s1(i) + scroll, p.t1(i)); gl.glMultiTexCoord2f(GL_TEXTURE1, p.s2(i), p.t2(i)); @@ -845,7 +842,7 @@ public abstract class Surf extends Draw { for ( p = surf.polys; p != null; p = p.chain ) { gl.glBegin (GL_POLYGON); - for (i=0 ; i< nv; i++) + for (int i=0 ; i< nv; i++) { gl.glMultiTexCoord2f(GL_TEXTURE0, p.s1(i), p.t1(i)); gl.glMultiTexCoord2f(GL_TEXTURE1, p.s2(i), p.t2(i)); @@ -1387,7 +1384,6 @@ public abstract class Surf extends Draw { boolean LM_AllocBlock (int w, int h, pos_t pos) { int x = pos.x; - int y = pos.y; int i, j; int best, best2; @@ -1407,7 +1403,7 @@ public abstract class Surf extends Draw { if (j == w) { // this is a valid spot pos.x = x = i; - pos.y = y = best = best2; + pos.y = best = best2; } } @@ -1427,10 +1423,9 @@ public abstract class Surf extends Draw { */ void GL_BuildPolygonFromSurface(msurface_t fa) { - int i, lindex, lnumverts; + int lindex, lnumverts; medge_t[] pedges; medge_t r_pedge; - int vertpage; float[] vec; float s, t; glpoly_t poly; @@ -1439,8 +1434,6 @@ public abstract class Surf extends Draw { // reconstruct the polygon pedges = currentmodel.edges; lnumverts = fa.numedges; - vertpage = 0; - Math3D.VectorClear(total); // // draw texture @@ -1452,7 +1445,7 @@ public abstract class Surf extends Draw { poly.flags = fa.flags; fa.polys = poly; - for (i=0 ; i<lnumverts ; i++) + for (int i=0 ; i<lnumverts ; i++) { lindex = currentmodel.surfedges[fa.firstedge + i]; diff --git a/src/jake2/render/basic/Warp.java b/src/jake2/render/basic/Warp.java index 16a1a0e..cd4ec59 100644 --- a/src/jake2/render/basic/Warp.java +++ b/src/jake2/render/basic/Warp.java @@ -2,7 +2,7 @@ * Warp.java * Copyright (C) 2003 * - * $Id: Warp.java,v 1.2 2006-11-21 00:50:46 cawe Exp $ + * $Id: Warp.java,v 1.3 2007-02-27 14:37:25 cawe Exp $ */ /* Copyright (C) 1997-2001 Id Software, Inc. @@ -350,8 +350,7 @@ public abstract class Warp extends Model { float[] av = { 0, 0, 0 }; float s, t, dv; int axis; - float[] vp; - + c_sky++; // decide which face it maps to Math3D.VectorCopy(Globals.vec3_origin, v); |