Getting absolute vector position
in
Programming Questions
•
1 year ago
Hello,
I'm still learning how to draw in processing, so this may be a very basic question.
I want to draw a line between two points.
The first point is relative to another randome point which which is generated inside a rotate/translate.
e.g.
- pushMatrix();
- translate(randomX, randomY);
- rotate(randomAngle);
- ...
- PVector point1 = new PVector(randomX+200, randomY+200);
- popMatrix();
The second known point is absolute to my applet frame.
How can I get the absolute position of point1 to draw a line between the two??
Thanks!!
1