diff options
author | Carsten Weisse <[email protected]> | 2007-02-15 14:28:47 +0000 |
---|---|---|
committer | Carsten Weisse <[email protected]> | 2007-02-15 14:28:47 +0000 |
commit | dbd22e000cde6d9b0ccbd1f544e61223286d7bf3 (patch) | |
tree | bc16e1c829d5bde67c277d8f6baf43141fcc253f /src | |
parent | 81bea019a4e821a957fd4a015435660f3c980066 (diff) |
clean up
Diffstat (limited to 'src')
-rw-r--r-- | src/jake2/render/fast/Image.java | 27 |
1 files changed, 11 insertions, 16 deletions
diff --git a/src/jake2/render/fast/Image.java b/src/jake2/render/fast/Image.java index 7848ea2..4561693 100644 --- a/src/jake2/render/fast/Image.java +++ b/src/jake2/render/fast/Image.java @@ -1,8 +1,6 @@ /* * Image.java * Copyright (C) 2003 - * - * $Id: Image.java,v 1.4 2007-01-10 03:01:31 cawe Exp $ */ /* Copyright (C) 1997-2001 Id Software, Inc. @@ -35,11 +33,12 @@ import jake2.util.Lib; import jake2.util.Vargs; import java.awt.Dimension; -import java.awt.geom.AffineTransform; -import java.awt.image.AffineTransformOp; -import java.awt.image.BufferedImage; -import java.nio.*; -import java.util.*; +import java.nio.ByteBuffer; +import java.nio.ByteOrder; +import java.nio.IntBuffer; +import java.util.Arrays; +import java.util.HashMap; +import java.util.Map; /** * Image @@ -119,18 +118,14 @@ public abstract class Image extends Main { } void GL_SelectTexture(int texture /* GLenum */) { - int tmu; + int tmu = (texture == TEXTURE0) ? 0 : 1; - tmu = (texture == TEXTURE0) ? 0 : 1; - - if (tmu == gl_state.currenttmu) { - return; + if (tmu != gl_state.currenttmu) { + gl_state.currenttmu = tmu; + gl.glActiveTextureARB(texture); + gl.glClientActiveTextureARB(texture); } - gl_state.currenttmu = tmu; - - gl.glActiveTextureARB(texture); - gl.glClientActiveTextureARB(texture); } int[] lastmodes = { -1, -1 }; |