Fixes of G-code multi-tool ordering.

This commit is contained in:
bubnikv 2017-05-16 15:30:03 +02:00
parent c22b6edeeb
commit 21be680ac2
3 changed files with 106 additions and 45 deletions

View file

@ -26,11 +26,17 @@ struct LayerTools
// For the use case when each object is printed separately
// (print.config.complete_objects is true).
extern std::vector<LayerTools> tool_ordering(PrintObject &object);
extern std::vector<LayerTools> tool_ordering(const PrintObject &object, unsigned int first_extruder = (unsigned int)-1);
// For the use case when all objects are printed at once.
// (print.config.complete_objects is false).
extern std::vector<LayerTools> tool_ordering(const Print &print);
extern std::vector<LayerTools> tool_ordering(const Print &print, unsigned int first_extruder = (unsigned int)-1);
// Get the first extruder printing the layer_tools, returns -1 if there is no layer printed.
extern unsigned int first_extruder(const std::vector<LayerTools> &layer_tools);
// Get the first extruder printing the layer_tools, returns -1 if there is no layer printed.
extern unsigned int last_extruder(const std::vector<LayerTools> &layer_tools);
} // namespace ToolOrdering
} // namespace SLic3r