OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector > Class Template Reference
Inheritance diagram for Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >:
Collaboration diagram for Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >:

Public Member Functions

 _AroundPadSkeleton (const ExPolygons &support_blueprint, const ExPolygons &model_blueprint, const PadConfig &cfg, ThrowOnCancel thr)

Public Attributes

ExPolygons inner
ExPolygons outer

Private Member Functions

void add_supports_to_index (const ExPolygons &supp_bp)
ExPolygons wafflized_concave_hull (const ExPolygons &supp_bp, const ExPolygons &model_bp, const PadConfig &cfg, ThrowOnCancel thr)
void remove_redundant_parts (ExPolygons &parts)

Private Attributes

_Intersector m_intersector

Detailed Description

template<class _Intersector>
class Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >

Constructor & Destructor Documentation

◆ _AroundPadSkeleton()

template<class _Intersector>
Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >::_AroundPadSkeleton ( const ExPolygons & support_blueprint,
const ExPolygons & model_blueprint,
const PadConfig & cfg,
ThrowOnCancel thr )
inline
241 {
242 // We need to merge the support and the model contours in a special
243 // way in which the model contours have to be substracted from the
244 // support contours. The pad has to have a hole in which the model can
245 // fit perfectly (thus the substraction -- diff_ex). Also, the pad has
246 // to be eliminated from areas where there is no need for a pad, due
247 // to missing supports.
248
250
251 auto model_bp_offs =
253 scaled<float>(cfg.embed_object.object_gap_mm),
254 jtMiter, 1);
255
258
259 auto model_bp_sticks =
260 breakstick_holes(model_bp_offs, cfg.embed_object.object_gap_mm,
261 cfg.embed_object.stick_stride_mm,
262 cfg.embed_object.stick_width_mm,
263 cfg.embed_object.stick_penetration_mm);
264
266
268
271
274 }
void add_supports_to_index(const ExPolygons &supp_bp)
Definition Pad.cpp:279
ExPolygons wafflized_concave_hull(const ExPolygons &supp_bp, const ExPolygons &model_bp, const PadConfig &cfg, ThrowOnCancel thr)
Definition Pad.cpp:286
void remove_redundant_parts(ExPolygons &parts)
Definition Pad.cpp:301
PadSkeleton divide_blueprint(const ExPolygons &bp)
Definition Pad.cpp:182
void breakstick_holes(Points &pts, double padding, double stride, double stick_width, double penetration)
Definition Pad.cpp:68
Slic3r::ExPolygons diff_ex(const Slic3r::Polygons &subject, const Slic3r::Polygons &clip, ApplySafetyOffset do_safety_offset)
Definition ClipperUtils.cpp:831
Slic3r::ExPolygons offset_ex(const Slic3r::Polygons &polygons, const float delta, JoinType joinType, double miterLimit)
Definition ClipperUtils.cpp:605

Member Function Documentation

◆ add_supports_to_index()

template<class _Intersector>
void Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >::add_supports_to_index ( const ExPolygons & supp_bp)
inlineprivate
280 {
281 for (auto &ep : supp_bp) m_intersector.add(ep);
282 }

◆ remove_redundant_parts()

template<class _Intersector>
void Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >::remove_redundant_parts ( ExPolygons & parts)
inlineprivate
302 {
303 auto endit = std::remove_if(parts.begin(), parts.end(),
304 [this](const ExPolygon &p) {
305 return !m_intersector.intersects(p);
306 });
307
308 parts.erase(endit, parts.end());
309 }

◆ wafflized_concave_hull()

template<class _Intersector>
ExPolygons Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >::wafflized_concave_hull ( const ExPolygons & supp_bp,
const ExPolygons & model_bp,
const PadConfig & cfg,
ThrowOnCancel thr )
inlineprivate
290 {
291 auto allin = reserve_vector<ExPolygon>(supp_bp.size() + model_bp.size());
292
293 for (auto &ep : supp_bp) allin.emplace_back(ep.contour);
294 for (auto &ep : model_bp) allin.emplace_back(ep.contour);
295
298 }
static coord_t get_waffle_offset(const PadConfig &c)
Definition Pad.cpp:149
static double get_merge_distance(const PadConfig &c)
Definition Pad.cpp:154
ExPolygons offset_waffle_style_ex(const ConcaveHull &hull, coord_t delta)
Definition ConcaveHull.cpp:139
IntegerOnly< I, std::vector< T, Args... > > reserve_vector(I capacity)
Definition libslic3r.h:370

Member Data Documentation

◆ inner

◆ m_intersector

template<class _Intersector>
_Intersector Slic3r::sla::anonymous_namespace{Pad.cpp}::_AroundPadSkeleton< _Intersector >::m_intersector
private

◆ outer


The documentation for this class was generated from the following file:
  • /home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/SLA/Pad.cpp