MCPcopy Index your code
hub / github.com/processing/processing / setMag

Method setMag

core/src/processing/core/PVector.java:863–867  ·  view source on GitHub ↗

( begin auto-generated from PVector_setMag.xml ) Set the magnitude of this vector to the value used for the len parameter. ( end auto-generated ) @webref pvector:method @usage web_application @param len the new length for this vector @brief Set the magnitude of the vector

(float len)

Source from the content-addressed store, hash-verified

861 * @brief Set the magnitude of the vector
862 */
863 public PVector setMag(float len) {
864 normalize();
865 mult(len);
866 return this;
867 }
868
869
870 /**

Callers

nothing calls this directly

Calls 3

normalizeMethod · 0.95
multMethod · 0.95
multMethod · 0.65

Tested by

no test coverage detected