public void glDrawElements (int mode, int count, int type, int indices) { GL11.glDrawElements(mode, count, type, indices); }
public void glDrawElements (int mode, int count, int type, int indices) { GL11.glDrawElements(mode, count, type, indices); }
public void glDrawElements (int mode, int count, int type, int indices) { GL11.glDrawElements(mode, count, type, indices); }
public void glDrawElements (int mode, int count, int type, int indices) { GL11.glDrawElements(mode, count, type, indices); }
public void glDrawElements (int mode, int count, int type, Buffer indices) { if (indices instanceof ShortBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, (ShortBuffer)indices); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, ((ByteBuffer)indices).asShortBuffer()); // FIXME yay... else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_BYTE) GL11.glDrawElements(mode, (ByteBuffer)indices); else throw new GdxRuntimeException("Can't use " + indices.getClass().getName() + " with this method. Use ShortBuffer or ByteBuffer instead. Blame LWJGL"); }
public void glDrawElements (int mode, int count, int type, Buffer indices) { if (indices instanceof ShortBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, (ShortBuffer)indices); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, ((ByteBuffer)indices).asShortBuffer()); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_BYTE) GL11.glDrawElements(mode, (ByteBuffer)indices); else throw new GdxRuntimeException("Can't use " + indices.getClass().getName() + " with this method. Use ShortBuffer or ByteBuffer instead. Blame LWJGL"); }
public void glDrawElements (int mode, int count, int type, Buffer indices) { if (indices instanceof ShortBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, (ShortBuffer)indices); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, ((ByteBuffer)indices).asShortBuffer()); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_BYTE) GL11.glDrawElements(mode, (ByteBuffer)indices); else throw new GdxRuntimeException("Can't use " + indices.getClass().getName() + " with this method. Use ShortBuffer or ByteBuffer instead. Blame LWJGL"); }
public void glDrawElements (int mode, int count, int type, Buffer indices) { if (indices instanceof ShortBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, (ShortBuffer)indices); else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_SHORT) GL11.glDrawElements(mode, ((ByteBuffer)indices).asShortBuffer()); // FIXME yay... else if (indices instanceof ByteBuffer && type == com.badlogic.gdx.graphics.GL20.GL_UNSIGNED_BYTE) GL11.glDrawElements(mode, (ByteBuffer)indices); else throw new GdxRuntimeException("Can't use " + indices.getClass().getName() + " with this method. Use ShortBuffer or ByteBuffer instead. Blame LWJGL"); }
public void doRender() { if (!isDisposed()) { GL11.glDrawElements(GL11.GL_TRIANGLES, indexCount, GL_UNSIGNED_INT, 0); } else { logger.error("Attempted to render disposed mesh: {}", getUrn()); } }
public void doRender(List<Vector3f> verts, List<Vector3f> normals) { FloatBuffer vertBuffer = BufferUtils.createFloatBuffer(verts.size() * 6); for (int i = 0; i < verts.size(); ++i) { Vector3f vert = verts.get(i); vertBuffer.put(vert.x * scale.x + translate.x); vertBuffer.put(vert.y * scale.y + translate.y); vertBuffer.put(vert.z * scale.z + translate.z); Vector3f norm = normals.get(i); vertBuffer.put(norm.x); vertBuffer.put(norm.y); vertBuffer.put(norm.z); } vertBuffer.flip(); VertexBufferObjectUtil.bufferVboData(disposalAction.vboPosNormBuffer, vertBuffer, GL15.GL_DYNAMIC_DRAW); GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, disposalAction.vboPosNormBuffer); glVertexPointer(VECTOR3_SIZE, GL_FLOAT, STRIDE, 0); glNormalPointer(GL_FLOAT, STRIDE, NORMAL_OFFSET); GL11.glDrawElements(GL11.GL_TRIANGLES, data.getIndices().size(), GL_UNSIGNED_INT, 0); GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, 0); }
GL11.glDrawElements(GL11.GL_TRIANGLES, vertexCount[id], GL11.GL_UNSIGNED_INT, 0);
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void renderList(List<GameItem> gameItems, Consumer<GameItem> consumer) { initRender(); for (GameItem gameItem : gameItems) { // Set up data requiered by gameItem consumer.accept(gameItem); // Render this game item glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); } endRender(); }
public void render() { initRender(); glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); endRender(); }
public void render() { initRender(); glDrawElements(GL_TRIANGLES, getVertexCount(), GL_UNSIGNED_INT, 0); endRender(); }