MCPcopy Create free account
hub / github.com/benfry/processing4 / div

Method div

core/src/processing/core/PVector.java:613–618  ·  view source on GitHub ↗

Divides a vector by a scalar. The version of the method that uses a float acts directly on the vector upon which it is called (as in the first example above). The version that receives both a PVector and a float as arguments is a static methods, and returns a new PVector that is

(float n)

Source from the content-addressed store, hash-verified

611 * @param n the number by which to divide the vector
612 */
613 public PVector div(float n) {
614 x /= n;
615 y /= n;
616 z /= n;
617 return this;
618 }
619
620
621 /**

Callers 1

normalizeMethod · 0.95

Calls 1

setMethod · 0.65

Tested by

no test coverage detected