Prusa Slicer 2.6.0
Loading...
Searching...
No Matches
Slic3r::trianglulate_wall_detail Namespace Reference

Classes

class  Ring
 
class  Triangulator
 

Functions

template<class Sc >
static Sc sq_dst (const Vec< 3, Sc > &v1, const Vec< 3, Sc > &v2)
 
template<class Sc >
static Sc trscore (const Ring &onring, const Ring &offring, const std::vector< Vec< 3, Sc > > &pts)
 

Function Documentation

◆ sq_dst()

template<class Sc >
static Sc Slic3r::trianglulate_wall_detail::sq_dst ( const Vec< 3, Sc > &  v1,
const Vec< 3, Sc > &  v2 
)
static
40{
41 Vec<3, Sc> v = v1 - v2;
42 return v.x() * v.x() + v.y() * v.y() /*+ v.z() * v.z()*/;
43}
The matrix class, also used for vectors and row-vectors.
Definition Matrix.h:180

Referenced by trscore().

+ Here is the caller graph for this function:

◆ trscore()

template<class Sc >
static Sc Slic3r::trianglulate_wall_detail::trscore ( const Ring onring,
const Ring offring,
const std::vector< Vec< 3, Sc > > &  pts 
)
static
49{
50 Sc a = sq_dst(pts[onring.pos().first], pts[offring.pos().first]);
51 Sc b = sq_dst(pts[onring.pos().second], pts[offring.pos().first]);
52 return (std::abs(a) + std::abs(b)) / 2.;
53}
Sc
Definition Singular_Value_Decomposition_Kernel_Declarations.hpp:129
std::pair< size_t, size_t > pos() const
Definition TriangulateWall.hpp:17
static Sc sq_dst(const Vec< 3, Sc > &v1, const Vec< 3, Sc > &v2)
Definition TriangulateWall.hpp:39

References Slic3r::trianglulate_wall_detail::Ring::pos(), Sc, and sq_dst().

Referenced by Slic3r::trianglulate_wall_detail::Triangulator< Sc >::calc_score(), and Slic3r::trianglulate_wall_detail::Triangulator< Sc >::synchronize_rings().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: