First naive prototype of seam painter

This commit is contained in:
Lukas Matena 2020-09-02 00:26:13 +02:00
parent 60cf002e94
commit 7844ca12fa
2 changed files with 77 additions and 0 deletions

View file

@ -70,6 +70,15 @@ private:
};
struct CustomSeam {
std::vector<ExPolygons> enforcers;
std::vector<ExPolygons> blockers;
// Finds whether the point is inside an enforcer/blockers.
// Returns +1, 0 or -1.
int get_point_status(const Point& pt, size_t layer_id) const;
};
class OozePrevention {
public:
bool enable;
@ -339,6 +348,9 @@ private:
std::string unretract() { return m_writer.unlift() + m_writer.unretract(); }
std::string set_extruder(unsigned int extruder_id, double print_z);
// Cache for custom seam enforcers/blockers for each layer.
CustomSeam m_custom_seam;
/* Origin of print coordinates expressed in unscaled G-code coordinates.
This affects the input arguments supplied to the extrude*() and travel_to()
methods. */