List of usage examples for org.lwjgl.opengl GL11 glDeleteTextures
public static void glDeleteTextures(@NativeType("GLuint const *") int[] textures)
From source file:kuake2.render.lwjgl.Image.java
License:Open Source License
void GL_FreeUnusedImages() { // never free r_notexture or particle texture r_notexture.registration_sequence = registration_sequence; r_particletexture.registration_sequence = registration_sequence; image_t image = null;//from w ww . j av a2 s . com for (int i = 0; i < numgltextures; i++) { image = gltextures[i]; // used this sequence if (image.registration_sequence == registration_sequence) continue; // free image_t slot if (image.registration_sequence == 0) continue; // don't free pics if (image.type == it_pic) continue; // free it // TODO jogl bug texnumBuffer.clear(); texnumBuffer.put(0, image.texnum); GL11.glDeleteTextures(texnumBuffer); image.clear(); } }
From source file:kuake2.render.lwjgl.Image.java
License:Open Source License
void GL_ShutdownImages() { image_t image;/*from w w w .j a v a 2s . c om*/ for (int i = 0; i < numgltextures; i++) { image = gltextures[i]; if (image.registration_sequence == 0) continue; // free image_t slot // free it // TODO jogl bug texnumBuffer.clear(); texnumBuffer.put(0, image.texnum); GL11.glDeleteTextures(texnumBuffer); image.clear(); } }
From source file:main.java.com.YeAJG.game.Game.java
License:Open Source License
/** * Destroys OpenGL//from w w w.j a v a 2 s. c om */ private void destroyGL() { //Deletes Textures for (Iterator<Entry<String, Integer>> it = TextureHandler.Textures.entrySet().iterator(); it.hasNext();) { Entry<String, Integer> set = it.next(); GL11.glDeleteTextures(set.getValue()); } Display.destroy(); }
From source file:main.Loader.java
public void cleanUp() { for (int vao : vaos) { GL30.glDeleteVertexArrays(vao);//from w w w . j ava2 s .co m } for (int vbo : vbos) { GL15.glDeleteBuffers(vbo); } for (int texture : textures) { GL11.glDeleteTextures(texture); } }
From source file:me.thehutch.fusion.engine.render.opengl.gl20.OpenGL20Texture.java
License:Open Source License
@Override public void dispose() { ensureCreated("Texture must be created to dispose."); // Delete the texture GL11.glDeleteTextures(id); // Set the texture as not created super.dispose(); }
From source file:me.ukl.api.gl.TextureGLGCObject.java
License:MIT License
@Override public void delete() { GL11.glDeleteTextures(getID()); }
From source file:me.ukl.api.util.TextureUtil.java
License:MIT License
public static void delete(int tex) { GL11.glDeleteTextures(tex); }
From source file:model.ModelMD2.java
@Override public void destroy() { //Delete VAO//from www.j a v a 2 s . c o m GL30.glBindVertexArray(vao_id); { for (int i = 0; i < 6; i++) { GL20.glDisableVertexAttribArray(i); } //Delete VBOs GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, 0); for (int i = 0; i < frame_ids.length; i++) { GL15.glDeleteBuffers(frame_ids[i]); } } GL30.glBindVertexArray(0); GL30.glDeleteVertexArrays(vao_id); GL11.glDeleteTextures(tex_id); }
From source file:mwisbest.openbase.opengl.TextureLoader.java
License:Open Source License
/** * Used internally; call TextureImpl.release. * /*w w w . ja va2 s. c o m*/ * @param id the id of the OpenGL texture */ public static void deleteTextureID(int id) { IntBuffer texBuf = createIntBuffer(1); texBuf.put(id); texBuf.flip(); GL11.glDeleteTextures(texBuf); textureCount--; }
From source file:net.neilcsmith.praxis.video.opengl.internal.Texture.java
License:Apache License
/** Disposes all resources associated with the texture */ public void dispose() { if (frameBuffer != null) { frameBuffer.dispose();/*from www .j a va2 s . c o m*/ } buffer.put(0, glHandle); GL11.glDeleteTextures(buffer); glHandle = 0; }