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

Method magSq

core/src/processing/core/PVector.java:414–416  ·  view source on GitHub ↗

Calculates the magnitude (length) of the vector, squared. This method is often used to improve performance since, unlike mag() , it does not require a sqrt() operation. @webref pvector:method @usage web_application @webBrief Calculate the magnitude of the vector, squared @return squar

()

Source from the content-addressed store, hash-verified

412 * @see PVector#mag()
413 */
414 public float magSq() {
415 return (x*x + y*y + z*z);
416 }
417
418
419 /**

Callers 1

limitMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected