fork download
  1. gl.glGenTextures(1, textureBuffer);
  2. FloatBuffer testBufer = FloatBuffer.allocate(slice.getDataMaxValue());
  3. for (int i = 0; i < slice.getDataMaxValue(); i++) {
  4. testBufer.put(1);
  5. }
  6. testBufer.rewind();
  7. gl.glBindTexture(GL3.GL_TEXTURE_1D, textureBuffer.get(0));
  8. gl.glTexImage1D(GL3.GL_TEXTURE_1D, 0, GL3.GL_RED, slice.getDataMaxValue(), 0, GL3.GL_RED, GL3.GL_FLOAT, testBufer);
  9. gl.glTexParameteri(GL3.GL_TEXTURE_1D, GL3.GL_TEXTURE_MAG_FILTER, GL3.GL_NEAREST);
  10. gl.glTexParameteri(GL3.GL_TEXTURE_1D, GL3.GL_TEXTURE_MIN_FILTER, GL3.GL_NEAREST);
  11. texture = TextureIO.newTexture(textureBuffer.get(0));
  12. textureMap.put(RenderMode.HISTOGRAM, texture);
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.d:1: error: unexpected ( in declarator
prog.d:1: error: basic type expected, not 1
prog.d:1: error: found '1' when expecting ')'
prog.d:1: error: no identifier for declarator gl.glGenTextures(int)
prog.d:1: error: semicolon expected following function declaration
prog.d:1: error: Declaration expected, not ','
prog.d:3: error: Declaration expected, not 'for'
prog.d:3: error: no identifier for declarator i
prog.d:3: error: Declaration expected, not '<'
prog.d:3: error: no identifier for declarator i
prog.d:3: error: Declaration expected, not '++'
prog.d:5: error: unrecognized declaration
stdout
Standard output is empty