mirror of
https://github.com/processing/processing4.git
synced 2026-02-02 21:29:17 +01:00
Added static dot(PVector v1, PVector v2) to PVector
This commit is contained in:
@@ -428,6 +428,10 @@ public class PVector {
|
||||
return this.x*x + this.y*y + this.z*z;
|
||||
}
|
||||
|
||||
|
||||
static public float dot(PVector v1, PVector v2) {
|
||||
return v1.x*v2.x + v1.y*v2.y + v1.z*v2.z;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a vector composed of the cross product between this and another.
|
||||
|
||||
Reference in New Issue
Block a user