WIP: Consolidation of shortest path calculations,

various chaining algorithms are replaced with the improved TSP
algorithm.
This commit is contained in:
bubnikv 2019-09-26 17:30:03 +02:00
parent 10eecb2cab
commit d06831076d
8 changed files with 43 additions and 78 deletions

View file

@ -1,8 +1,8 @@
#include "Layer.hpp"
#include "ClipperUtils.hpp"
#include "Geometry.hpp"
#include "Print.hpp"
#include "Fill/Fill.hpp"
#include "ShortestPath.hpp"
#include "SVG.hpp"
#include <boost/log/trivial.hpp>
@ -57,8 +57,7 @@ void Layer::make_slices()
ordering_points.push_back(ex.contour.first_point());
// sort slices
std::vector<Points::size_type> order;
Slic3r::Geometry::chained_path(ordering_points, order);
std::vector<Points::size_type> order = chain_points(ordering_points);
// populate slices vector
for (size_t i : order)