Back to all rules
What this rule checks
Uses beginShape()/endShape()/vertex() for custom shapes
Configuration
When off, this rule is excluded from pipeline runs. Changes apply immediately.
Code Examples
PASS — this code satisfies the rule
void setup() {
  size(400, 400);
}

void draw() {
  background(255);
  fill(0, 150, 0);
  triangle(200, 80, 120, 300, 280, 300);  // the tree as one built-in shape
}
FAIL — this code triggers the rule
void setup() {
  size(400, 400);
}

void draw() {
  background(255);
  fill(0, 150, 0);
  beginShape();
  vertex(200, 80);
  vertex(120, 300);
  vertex(280, 300);
  endShape(CLOSE);
}
Overview
Category Out of Scope
Type Custom Zita
Priority 3 (1 = highest, 5 = lowest)
Status Active
PMD Configuration
Java class nl.utwente.processing.pmd.rules.HasBeginEndShapeRule
Message template beginShape()/endShape() usage found.