summaryrefslogtreecommitdiffstats
path: root/AutoVisual/IGPFamily.pde
diff options
context:
space:
mode:
authorDavid Runge <dave@sleepmap.de>2016-01-02 20:42:12 +0100
committerDavid Runge <dave@sleepmap.de>2016-01-02 20:42:12 +0100
commit39aa624cb42e916f96c785b1a44a6e5fcc7ec590 (patch)
tree89cb7fc929f45f9018b3fb71fc0af96f6ec74094 /AutoVisual/IGPFamily.pde
parentd03513b9b223864c89916dd5edff3c97e571472e (diff)
downloadprocessing-sketchbook-39aa624cb42e916f96c785b1a44a6e5fcc7ec590.tar.gz
processing-sketchbook-39aa624cb42e916f96c785b1a44a6e5fcc7ec590.tar.bz2
processing-sketchbook-39aa624cb42e916f96c785b1a44a6e5fcc7ec590.tar.xz
processing-sketchbook-39aa624cb42e916f96c785b1a44a6e5fcc7ec590.zip
AutoVisual/IGP{Family,Square}.pde: Changing to more reasonable
get-methods (getLineIntersection(), getAngleBetweenTwoVectors(), getVectorsOnExtendedLine()).
Diffstat (limited to 'AutoVisual/IGPFamily.pde')
-rw-r--r--AutoVisual/IGPFamily.pde6
1 files changed, 3 insertions, 3 deletions
diff --git a/AutoVisual/IGPFamily.pde b/AutoVisual/IGPFamily.pde
index ac7d4cc..0651ceb 100644
--- a/AutoVisual/IGPFamily.pde
+++ b/AutoVisual/IGPFamily.pde
@@ -213,7 +213,7 @@ class IGPFamily {
translate(mid.x*(-1), mid.y*(-1));
}
- PVector lineIntersection(PVector p1, PVector p2, PVector p3, PVector p4) {
+ PVector getLineIntersection(PVector p1, PVector p2, PVector p3, PVector p4) {
PVector b = PVector.sub(p2, p1);
PVector d = PVector.sub(p4, p3);
@@ -231,7 +231,7 @@ class IGPFamily {
return new PVector(p1.x+t*b.x, p1.y+t*b.y);
}
- float angleBetweenTwoVectors (PVector p1, PVector p2) {
+ float getAngleBetweenTwoVectors (PVector p1, PVector p2) {
float angle = atan2(p1.y-p2.y, p1.x-p2.x);
if (angle < 0) {
angle+=TWO_PI;
@@ -239,7 +239,7 @@ class IGPFamily {
return degrees(angle);
}
- PVector extendLine(PVector startPoint, PVector endPoint, float boundary, boolean vertical){
+ PVector getVectorOnExtendedLine(PVector startPoint, PVector endPoint, float boundary, boolean vertical){
float m,n;
m = (endPoint.y-startPoint.y)/(endPoint.x-startPoint.x);
n = endPoint.y-m*endPoint.x;