Answers for "processing PVector in PVector"

1

processing pvector

PVector v1, v2;

void setup() {
  noLoop();
  v1 = new PVector(40, 20);
  v2 = new PVector(25, 50); 
}

void draw() {
  ellipse(v1.x, v1.y, 12, 12);
  ellipse(v2.x, v2.y, 12, 12);
  v2.add(v1);
  ellipse(v2.x, v2.y, 24, 24);
}
Posted by: Guest on September-23-2020

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language