public void fillTriangle(float x1, float y1, float x2, float y2, float x3, float y3) {
startPrimitive(Primitive.TRIANGLE, null);
GL2 gl = drawable.getGL().getGL2();
gl.glVertex2f(x1, y1);
gl.glVertex2f(x3, y3);
gl.glVertex2f(x2, y2);
}
private Triangle[] triangleArray = new Triangle[1];
public void drawTriangle(Triangle triangle, boolean useColors) {
if (triangle == null) throw new IllegalArgumentException("triangle must not be null");