MCPcopy Index your code
hub / github.com/processing/processing / drawGeometry

Method drawGeometry

core/src/processing/core/PShape.java:1715–1733  ·  view source on GitHub ↗
(PGraphics g)

Source from the content-addressed store, hash-verified

1713
1714
1715 protected void drawGeometry(PGraphics g) {
1716 // get cache object using g.
1717 g.beginShape(kind);
1718 if (style) {
1719 for (int i = 0; i < vertexCount; i++) {
1720 g.vertex(vertices[i]);
1721 }
1722 } else {
1723 for (int i = 0; i < vertexCount; i++) {
1724 float[] vert = vertices[i];
1725 if (vert[Z] == 0) {
1726 g.vertex(vert[X], vert[Y]);
1727 } else {
1728 g.vertex(vert[X], vert[Y], vert[Z]);
1729 }
1730 }
1731 }
1732 g.endShape(close ? CLOSE : OPEN);
1733 }
1734
1735
1736 /*

Callers 1

drawImplMethod · 0.95

Calls 3

vertexMethod · 0.65
beginShapeMethod · 0.45
endShapeMethod · 0.45

Tested by

no test coverage detected