summaryrefslogtreecommitdiffstats
path: root/src/demos/proceduralTexturePhysics
diff options
context:
space:
mode:
Diffstat (limited to 'src/demos/proceduralTexturePhysics')
-rw-r--r--src/demos/proceduralTexturePhysics/ProceduralTexturePhysics.java2
-rw-r--r--src/demos/proceduralTexturePhysics/Water.java7
2 files changed, 4 insertions, 5 deletions
diff --git a/src/demos/proceduralTexturePhysics/ProceduralTexturePhysics.java b/src/demos/proceduralTexturePhysics/ProceduralTexturePhysics.java
index 2076368..7599778 100644
--- a/src/demos/proceduralTexturePhysics/ProceduralTexturePhysics.java
+++ b/src/demos/proceduralTexturePhysics/ProceduralTexturePhysics.java
@@ -38,7 +38,6 @@ import java.awt.event.*;
import javax.swing.*;
import javax.media.opengl.*;
-import javax.media.opengl.glu.*;
import com.sun.opengl.utils.*;
import demos.common.*;
import demos.util.*;
@@ -210,7 +209,6 @@ public class ProceduralTexturePhysics extends Demo {
}
GL gl = drawable.getGL();
- GLU glu = drawable.getGLU();
gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT);
diff --git a/src/demos/proceduralTexturePhysics/Water.java b/src/demos/proceduralTexturePhysics/Water.java
index d0585fc..404d012 100644
--- a/src/demos/proceduralTexturePhysics/Water.java
+++ b/src/demos/proceduralTexturePhysics/Water.java
@@ -63,6 +63,8 @@ public class Water {
// used to render the water geometry (with the parent drawable's GL
// object).
+ private GLU glu = new GLU();
+
// Rendering modes
public static final int CA_FULLSCREEN_REFLECT = 0;
public static final int CA_FULLSCREEN_FORCE = 1;
@@ -424,9 +426,8 @@ public class Water {
class Listener implements GLEventListener {
public void init(GLAutoDrawable drawable) {
GL gl = drawable.getGL();
- GLU glu = drawable.getGLU();
- initOpenGL(gl, glu);
+ initOpenGL(gl);
}
public void display(GLAutoDrawable drawable) {
@@ -488,7 +489,7 @@ public class Water {
initialMapDimensions[1] = initialMap.getHeight();
}
- private void initOpenGL(GL gl, GLU glu) {
+ private void initOpenGL(GL gl) {
loadTextures(gl, tmpSpinFilename, tmpDropletFilename, tmpCubeMapFilenamePattern);
tmpSpinFilename = null;
tmpDropletFilename = null;