()
| 154 | } |
| 155 | |
| 156 | @Override |
| 157 | protected TextureBuffer.State setup() { |
| 158 | |
| 159 | State s = new State(); |
| 160 | GraphicsContext.checkError(() -> "before genTextures"); |
| 161 | s.textureName = glGenTextures(); |
| 162 | GL11.glBindTexture(GL31.GL_TEXTURE_BUFFER, s.textureName); |
| 163 | GraphicsContext.checkError(() -> "before first clean"); |
| 164 | buffer.clean(specification.elements); |
| 165 | GraphicsContext.checkError(() -> "after clean / before texBuffer"); |
| 166 | GL31.glTexBuffer(GL31.GL_TEXTURE_BUFFER, specification.type, buffer.getOpenGLNameInCurrentContext()); |
| 167 | GraphicsContext.checkError(() -> "after texBuffer"); |
| 168 | |
| 169 | return s; |
| 170 | } |
| 171 | |
| 172 | @Override |
| 173 | protected void deallocate(TextureBuffer.State s) { |
nothing calls this directly
no test coverage detected