docs: void computeWeights(Cache cache, float v_x, float v_y) {
  		float[] weights = cache.weights.data;
  		// first compute the weights
  		float totalWeight = 0.0f;
  		for (int i = 0; i < controls.size(); i++) {
  			Control c = controls.get(i);
  
  			float d2 = c.p.distance2(v_x, v_y);
  			// check for the special case
  			if( d2 == 0 ) {
  				for (int j = 0; j < controls.size(); j++) {
  					weights[j] = i==j ? 1.0f : 0.0f;
  				}
  				totalWeight = 1.0f;
  				break;
  			} else {
  				totalWeight += weights[i] = 1.0f/(float)Math.pow(d2,alpha);
  			}
  		}
  		cache.totalWeight = totalWeight;
  	}