OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::SeamPlacerImpl::PaintedContour Struct Reference
Collaboration diagram for Slic3r::SeamPlacerImpl::PaintedContour:

Public Member Functions

std::vector< std::pair< Vec2d, Vec2d > > crossings (double z, const Vec2d &min, const Vec2d &max) const

Public Attributes

std::vector< Linef3 > edges
std::vector< Vec3d > inward
AABBTreeIndirect::Tree< 3, double > tree

Detailed Description

Member Function Documentation

◆ crossings()

std::vector< std::pair< Vec2d, Vec2d > > Slic3r::SeamPlacerImpl::PaintedContour::crossings ( double z,
const Vec2d & min,
const Vec2d & max ) const
inline
330 {
331 std::vector<std::pair<Vec2d, Vec2d>> result;
332 const Eigen::AlignedBox<double, 3> box(Vec3d(min.x(), min.y(), z), Vec3d(max.x(), max.y(), z));
334 const Linef3 &edge = edges[node.idx];
335 // Half-open in z counts a contour vertex on the plane once.
336 if ((edge.a.z() < z) != (edge.b.z() < z)) {
337 const Vec3d p = edge.intersect_plane(z);
338 result.emplace_back(p.head<2>(), inward[node.idx].template head<2>());
339 }
340 return true;
341 });
342 return result;
343 }
auto intersecting(const G &g)
Definition AABBTreeIndirect.hpp:925
void traverse(const Tree< Dims, T > &tree, Predicate &&pred, Fn &&callback)
Definition AABBTreeIndirect.hpp:986
Eigen::Matrix< double, 3, 1, Eigen::DontAlign > Vec3d
Definition Point.hpp:68
std::vector< Linef3 > edges
Definition SeamPlacer.cpp:326
std::vector< Vec3d > inward
Definition SeamPlacer.cpp:327
AABBTreeIndirect::Tree< 3, double > tree
Definition SeamPlacer.cpp:328

References Slic3r::Linef3::a, Slic3r::Linef3::b, edges, Slic3r::Linef3::intersect_plane(), Slic3r::AABBTreeIndirect::intersecting(), inward, Slic3r::AABBTreeIndirect::traverse(), and tree.

Here is the call graph for this function:

Member Data Documentation

◆ edges

std::vector<Linef3> Slic3r::SeamPlacerImpl::PaintedContour::edges

◆ inward

std::vector<Vec3d> Slic3r::SeamPlacerImpl::PaintedContour::inward

◆ tree

AABBTreeIndirect::Tree<3, double> Slic3r::SeamPlacerImpl::PaintedContour::tree

The documentation for this struct was generated from the following file:
  • /home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/GCode/SeamPlacer.cpp