Fix bug where distance would be too close to 0 to register
the furthest_distance now starts at -1 instead of 0 - if there's a point with a distance of 0, that's fine. This caused issues in the circle previously.
This commit is contained in:
parent
1e9511a3ac
commit
b9fd11ca0d
@ -63,7 +63,7 @@ private:
|
|||||||
|
|
||||||
// Find the point which is furthest away from the line, add it to the output
|
// Find the point which is furthest away from the line, add it to the output
|
||||||
Point furthest_point;
|
Point furthest_point;
|
||||||
float furthest_distance = 0.0;
|
float furthest_distance = -1.0;
|
||||||
|
|
||||||
for (const Point &point : input)
|
for (const Point &point : input)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user