All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.saintandreas.gl.buffers.VertexArray Maven / Gradle / Ivy

The newest version!
package org.saintandreas.gl.buffers;

import static org.lwjgl.opengl.GL30.*;

public class VertexArray {
  int vao = -1;

  public VertexArray() {
    vao = glGenVertexArrays();
  }

  public void bind() {
    glBindVertexArray(vao);
  }

  public static void unbind() {
    glBindVertexArray(0);
  }

  public void destroy() {
    glDeleteVertexArrays(vao);
    vao = -1;
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy