* @param col1 color of the point defined by x1 and y1
* @param col2 color of the point defined by x2 and y2
* @param col3 color of the point defined by x3 and y3 */
public void triangle (float x1, float y1, float x2, float y2, float x3, float y3, Color col1, Color col2, Color col3) {
if (currType != ShapeType.Filled && currType != ShapeType.Line)
throw new GdxRuntimeException("Must call begin(ShapeType.Filled) or begin(ShapeType.Line)");
checkDirty();
checkFlush(6);
if (currType == ShapeType.Line) {
renderer.color(col1.r, col1.g, col1.b, col1.a);
renderer.vertex(x1, y1, 0);