コード例 #1
0
  @Override
  protected boolean end(GL gl) {

    GL4 gl4 = (GL4) gl;

    gl4.glDeleteBuffers(Buffer.MAX.ordinal(), bufferName, 0);
    gl4.glDeleteVertexArrays(1, vertexArrayName, 0);
    gl4.glDeleteProgram(programName[Program.VERT.ordinal()]);
    gl4.glDeleteProgram(programName[Program.FRAG.ordinal()]);
    gl4.glBindProgramPipeline(0);
    gl4.glDeleteProgramPipelines(1, pipelineName, 0);

    return true;
  }
コード例 #2
0
  @Override
  protected boolean end(GL gl) {

    GL4 gl4 = (GL4) gl;

    gl4.glDeleteProgramPipelines(1, pipelineName);
    BufferUtils.destroyDirectBuffer(pipelineName);
    gl4.glDeleteProgram(programName[Program.FRAGMENT]);
    gl4.glDeleteProgram(programName[Program.VERTEX]);
    gl4.glDeleteBuffers(Buffer.MAX, bufferName);
    BufferUtils.destroyDirectBuffer(bufferName);
    gl4.glDeleteTextures(1, textureName);
    BufferUtils.destroyDirectBuffer(textureName);
    gl4.glDeleteVertexArrays(1, vertexArrayName);
    BufferUtils.destroyDirectBuffer(vertexArrayName);

    return true;
  }