diff options
Diffstat (limited to 'src/demos/es2/perftst/Perftst.java')
-rwxr-xr-x | src/demos/es2/perftst/Perftst.java | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/demos/es2/perftst/Perftst.java b/src/demos/es2/perftst/Perftst.java index d67f827..d27ba9e 100755 --- a/src/demos/es2/perftst/Perftst.java +++ b/src/demos/es2/perftst/Perftst.java @@ -72,7 +72,7 @@ public class Perftst implements MouseListener, GLEventListener { window.display(); // Shut things down cooperatively - window.close(); + window.destroy(); window.getFactory().shutdown(); System.out.println("Perftst shut down cleanly."); } catch (Throwable t) { @@ -139,6 +139,17 @@ public class Perftst implements MouseListener, GLEventListener { st.glUseProgram(gl, false); } + public void dispose(GLAutoDrawable drawable) { + GL2ES2 gl = drawable.getGL().getGL2ES2(); + + st.destroy(gl); + st=null; + pmvMatrix.destroy(); + pmvMatrix=null; + quit=true; + } + + public void display(GLAutoDrawable drawable) { pmod.run(drawable, 10); } |