Seam: use scarf joint to minimize seam visiblity (#3839)

* Remember z of previous layer

* Support travel to middle of the layer z

* Support sloped extrusion

* Implement sloped seam

* Reduce extra movements

* Don't clip loop if sloped seam is enabled

* Fix wipe

* Ensure `slope_max_segment_length`

* Add options

* Limit slope length to perimeter length

* Fix slope segmentation

* Rename the option to scarf joint seam

* Don't modify the slope option when turning on spiral vase

* Add a few suggestions when turnning on scarf joint

* Add option to add scarf joint to inner walls

* Apply seam gap at the end of the slope

* Add option to explicitly use the entire loop as scarf length

* Fix layer number

* Increase default scarf length to 20mm

* Better way of storing the global scarf state

* Better vase mode layer height recognition

* Move id should exclude seams

* Fix slope height with independent support layer height

* Fix linux build

* Allow controlling the scarf with modifier

* Scarf start height default to 0

* Allow enable scarf seam on contour only

* Fix type error

* Move the creation of sloped loop into ExtrusionEntity.cpp

* Fix error "vector too long"

* Detect seams properly

* The correct way of calculating the rate limit

* The correct way of calculating the rate limit

(cherry picked from commit 05961f7c98)

* Add pressure equalizer in print by object mode

* Remove the settings recommendation as it varies a lot depends on printer & filament

* Add a beta suffix

---------

Co-authored-by: SoftFever <softfeverever@gmail.com>
This commit is contained in:
Noisyfox 2024-03-02 23:25:02 +08:00 committed by GitHub
parent ab1b0e0ebc
commit 924a2b4551
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 533 additions and 54 deletions

View file

@ -700,7 +700,8 @@ namespace Slic3r {
SeamsDetector m_seams_detector;
OptionsZCorrector m_options_z_corrector;
size_t m_last_default_color_id;
bool m_spiral_vase_active;
bool m_detect_layer_based_on_tag {false};
int m_seams_count;
#if ENABLE_GCODE_VIEWER_STATISTICS
std::chrono::time_point<std::chrono::high_resolution_clock> m_start_time;
#endif // ENABLE_GCODE_VIEWER_STATISTICS
@ -770,6 +771,10 @@ namespace Slic3r {
//BBS: set offset for gcode writer
void set_xy_offset(double x, double y) { m_x_offset = x; m_y_offset = y; }
// Orca: if true, only change new layer if ETags::Layer_Change occurs
// otherwise when we got a lift of z during extrusion, a new layer will be added
void detect_layer_based_on_tag(bool enabled) { m_detect_layer_based_on_tag = enabled; }
private:
void apply_config(const DynamicPrintConfig& config);
void apply_config_simplify3d(const std::string& filename);