OrcaSlicer latest
OrcaSlicer
Loading...
Searching...
No Matches
Slic3r::TriangleMeshStats Struct Reference

#include </home/runner/work/OrcaSlicer/OrcaSlicer/src/libslic3r/TriangleMesh.hpp>

Collaboration diagram for Slic3r::TriangleMeshStats:

Public Member Functions

void clear ()
TriangleMeshStats merge (const TriangleMeshStats &rhs) const
bool manifold () const
bool repaired () const

Public Attributes

uint32_t number_of_facets = 0
stl_vertex max = stl_vertex::Zero()
stl_vertex min = stl_vertex::Zero()
stl_vertex size = stl_vertex::Zero()
float volume = -1.f
int number_of_parts = 0
int open_edges = 0
RepairedMeshErrors repaired_errors

Detailed Description

Member Function Documentation

◆ clear()

void Slic3r::TriangleMeshStats::clear ( )
inline
68{ *this = TriangleMeshStats(); }

◆ manifold()

bool Slic3r::TriangleMeshStats::manifold ( ) const
inline
89{ return open_edges == 0; }
int open_edges
Definition TriangleMesh.hpp:63

References open_edges.

Referenced by Slic3r::GUI::ObjectList::get_mesh_errors_info(), and Slic3r::GUI::get_warning_icon_name().

Here is the caller graph for this function:

◆ merge()

TriangleMeshStats Slic3r::TriangleMeshStats::merge ( const TriangleMeshStats & rhs) const
inline
70 {
71 if (this->number_of_facets == 0)
72 return rhs;
73 else if (rhs.number_of_facets == 0)
74 return *this;
75 else {
76 TriangleMeshStats out;
77 out.number_of_facets = this->number_of_facets + rhs.number_of_facets;
78 out.min = this->min.cwiseMin(rhs.min);
79 out.max = this->max.cwiseMax(rhs.max);
80 out.size = out.max - out.min;
81 out.number_of_parts = this->number_of_parts + rhs.number_of_parts;
82 out.open_edges = this->open_edges + rhs.open_edges;
83 out.volume = this->volume + rhs.volume;
84 out.repaired_errors.merge(rhs.repaired_errors);
85 return out;
86 }
87 }
stl_vertex max
Definition TriangleMesh.hpp:56
int number_of_parts
Definition TriangleMesh.hpp:60
stl_vertex min
Definition TriangleMesh.hpp:57
uint32_t number_of_facets
Definition TriangleMesh.hpp:55
float volume
Definition TriangleMesh.hpp:59

References max, Slic3r::RepairedMeshErrors::merge(), min, number_of_facets, number_of_parts, open_edges, repaired_errors, size, and volume.

Here is the call graph for this function:

◆ repaired()

bool Slic3r::TriangleMeshStats::repaired ( ) const
inline
90{ return repaired_errors.repaired(); }
RepairedMeshErrors repaired_errors
Definition TriangleMesh.hpp:66

References repaired_errors.

Referenced by Slic3r::GUI::ObjectList::get_mesh_errors_info(), and Slic3r::GUI::get_warning_icon_name().

Here is the caller graph for this function:

Member Data Documentation

◆ max

stl_vertex Slic3r::TriangleMeshStats::max = stl_vertex::Zero()

◆ min

stl_vertex Slic3r::TriangleMeshStats::min = stl_vertex::Zero()

◆ number_of_facets

◆ number_of_parts

int Slic3r::TriangleMeshStats::number_of_parts = 0

◆ open_edges

◆ repaired_errors

◆ size

stl_vertex Slic3r::TriangleMeshStats::size = stl_vertex::Zero()

◆ volume


The documentation for this struct was generated from the following file: