getCenter method

Vector2 getCenter(
  1. Vector2 target
)

Implementation

Vector2 getCenter(Vector2 target) {
  return isEmpty() ? target.set(0, 0) : target.addVectors(min, max).multiplyScalar(0.5);
}