แก้ coding style ภาค 6
This commit is contained in:
@@ -38,11 +38,9 @@ export function placeNearToNearestNeighbour (node, nearNeighbour, radius, sample
|
||||
|
||||
// Determine the closest quadrant
|
||||
if (dist0 == dist180) {
|
||||
if (dist90 > dist270) { lowBound = highBound = 270; }
|
||||
else { lowBound = highBound = 90; }
|
||||
if (dist90 > dist270) { lowBound = highBound = 270; } else { lowBound = highBound = 90; }
|
||||
} else if (dist90 == dist270) {
|
||||
if (dist0 > dist180) { lowBound = highBound = 180; }
|
||||
else { lowBound = highBound = 0; }
|
||||
if (dist0 > dist180) { lowBound = highBound = 180; } else { lowBound = highBound = 0; }
|
||||
} else if (dist0 > dist180) {
|
||||
if (dist90 > dist270) {
|
||||
lowBound = 180;
|
||||
@@ -120,8 +118,7 @@ function binarySearchMin (lb, hb, fn) {
|
||||
|
||||
if (valLowerHalf > valHigherHalf) {
|
||||
lb = Math.floor((lb + hb) / 2);
|
||||
}
|
||||
else if (valLowerHalf < valHigherHalf) {
|
||||
} else if (valLowerHalf < valHigherHalf) {
|
||||
hb = Math.ceil((lb + hb) / 2);
|
||||
} else {
|
||||
lb += Math.floor(range / 4);
|
||||
|
||||
Reference in New Issue
Block a user