1
0
mirror of https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git synced 2026-07-11 08:04:25 +00:00

Small optimization on an incredibly hot codepath.

This commit is contained in:
Jesse Vincent
2013-04-07 18:01:15 -04:00
parent 7e51cbcf69
commit 060d2da7fe
+1 -2
View File
@@ -116,8 +116,7 @@ sub distance_between_points {
}
sub comparable_distance_between_points {
my ($p1, $p2) = @_;
return (($p1->[X] - $p2->[X])**2) + (($p1->[Y] - $p2->[Y])**2);
return (($_[0]->[X] - $_[1]->[X])**2) + (($_[0]->[Y] - $_[1]->[Y])**2);
}
sub point_line_distance {