934 {
936
937 size_t dtt_roof_tip;
938 for (dtt_roof_tip = 0; dtt_roof_tip < roof_tip_layers && insert_layer_idx - dtt_roof_tip >= 1; ++ dtt_roof_tip) {
939 size_t this_layer_idx = insert_layer_idx - dtt_roof_tip;
940 const size_t roof_recovery_depth = dtt_roof_tip + supports_roof_layers;
941 auto evaluateRoofWillGenerate = [&](const std::pair<Point, LineStatus> &p) {
942
943 #if 0
945 for (Point corner : base_circle)
946 roof_circle.
points.emplace_back(p.first + corner *
config.min_radius);
948 #else
949 return true;
950 #endif
951 };
952
953 {
954 std::pair<LineInformations, LineInformations> split =
955
956 split_lines(lines, [
this, this_layer_idx](
const std::pair<Point, LineStatus> &p)
959
960 split =
split_lines(split.first, evaluateRoofWillGenerate);
961 lines = std::move(split.first);
962 append(points, split.second);
963
965 for (const std::pair<Point, LineStatus> &point_data : line)
967
968 roof_tip_layers - dtt_roof_tip,
969
970 roof_recovery_depth > 0,
971
972 roof_recovery_depth,
973
974 false);
975 }
976
977
980
981 for (const std::pair<Point, LineStatus> &p : line) {
984 roof_circle.translate(p.first);
985 new_roofs.emplace_back(std::move(roof_circle));
986 }
987 this->
add_roof(std::move(new_roofs), this_layer_idx, roof_recovery_depth);
988 }
989
990 const size_t roof_recovery_depth = dtt_roof_tip + supports_roof_layers;
992
993
994 bool disable_ovalistation =
config.min_radius < 3 *
config.support_line_width && roof_tip_layers == 0 && dtt_roof_tip == 0 && line.size() > 5;
995 for (const std::pair<Point, LineStatus> &point_data : line)
997
998 dont_move_until > dtt_roof_tip ? dont_move_until - dtt_roof_tip : 0,
999
1000 roof_recovery_depth > 0,
1001
1002 roof_recovery_depth,
1003 disable_ovalistation);
1004 }
1005 }
Points points
Definition MultiPoint.hpp:22
void scale(double factor)
Definition MultiPoint.cpp:17
void add_roof(Polygons &&new_roof, const size_t insert_layer_idx, const size_t dtt_tip)
Definition TreeSupportCommon.hpp:750
void add_point_as_influence_area(std::pair< Point, LineStatus > p, LayerIndex insert_layer, size_t dont_move_until, bool roof, size_t roof_recovery_dtt, bool skip_ovalisation)
Definition TreeSupport3D.cpp:1009
static Polylines generate_support_infill_lines(const Polygons &polygon, const SupportParameters &support_params, bool roof, LayerIndex layer_idx, coord_t support_infill_distance)
Returns Polylines representing the (infill) lines that will result in slicing the given area.
Definition TreeSupport3D.cpp:703
std::vector< std::pair< Point, LineStatus > > LineInformation
Definition TreeSupport3D.cpp:99
std::vector< LineInformation > LineInformations
Definition TreeSupport3D.cpp:100
static std::pair< LineInformations, LineInformations > split_lines(const LineInformations &lines, EvaluatePointFn evaluatePoint)
Evaluates which points of some lines are not valid one layer below and which are. Assumes all points ...
Definition TreeSupport3D.cpp:517
static void validate_range(const Point &pt)
Definition TreeSupport3D.cpp:103
static bool evaluate_point_for_next_layer_function(const TreeModelVolumes &volumes, const TreeSupportSettings &config, size_t current_layer, const std::pair< Point, LineStatus > &p)
Evaluates if a point has to be added now. Required for a split_lines call in generate_initial_areas()...
Definition TreeSupport3D.cpp:492
void append(std::vector< T, Alloc > &dest, const std::vector< T, Alloc2 > &src)
Definition libslic3r.h:157
bool empty(const BoundingBoxBase< PointType, PointsType > &bb)
Definition BoundingBox.hpp:273