MCPcopy Index your code
hub / github.com/benfry/processing4 / drawGeometry

Method drawGeometry

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

Source from the content-addressed store, hash-verified

1770
1771
1772 protected void drawGeometry(PGraphics g) {
1773 // get cache object using g.
1774 g.beginShape(kind);
1775 if (style) {
1776 for (int i = 0; i < vertexCount; i++) {
1777 g.vertex(vertices[i]);
1778 }
1779 } else {
1780 for (int i = 0; i < vertexCount; i++) {
1781 float[] vert = vertices[i];
1782 if (vert.length < 3 || vert[Z] == 0) {
1783 g.vertex(vert[X], vert[Y]);
1784 } else {
1785 g.vertex(vert[X], vert[Y], vert[Z]);
1786 }
1787 }
1788 }
1789 g.endShape(close ? CLOSE : OPEN);
1790 }
1791
1792
1793 /*

Callers 1

drawImplMethod · 0.95

Calls 3

vertexMethod · 0.65
beginShapeMethod · 0.45
endShapeMethod · 0.45

Tested by

no test coverage detected