Prusa Slicer 2.6.0
Loading...
Searching...
No Matches
Slic3r::SLAPrintObject Class Reference

#include <src/libslic3r/SLAPrint.hpp>

+ Inheritance diagram for Slic3r::SLAPrintObject:
+ Collaboration diagram for Slic3r::SLAPrintObject:

Classes

class  HollowingData
 
struct  Instance
 
class  SliceRecord
 
struct  SupportData
 

Public Types

using PrintObjectStepEnum = PrintObjectStepEnumType
 
typedef PrintState< PrintObjectStepEnum, COUNT > PrintObjectState
 
using Timestamp = uint64_t
 

Public Member Functions

 SLAPrintObject (const SLAPrintObject &)=delete
 
SLAPrintObjectoperator= (const SLAPrintObject &)=delete
 
const SLAPrintObjectConfigconfig () const
 
const Transform3dtrafo () const
 
bool is_left_handed () const
 
const std::vector< Instance > & instances () const
 
const TriangleMeshsupport_mesh () const
 
const TriangleMeshpad_mesh () const
 
const std::shared_ptr< const indexed_triangle_set > & get_mesh_to_print () const
 
std::vector< csg::CSGPartget_parts_to_slice () const
 
std::vector< csg::CSGPartget_parts_to_slice (SLAPrintObjectStep step) const
 
sla::SupportPoints transformed_support_points () const
 
sla::DrainHoles transformed_drainhole_points () const
 
double get_elevation () const
 
double get_current_elevation () const
 
const std::vector< sla::SupportPoint > & get_support_points () const
 
const std::vector< SliceRecord > & get_slice_index () const
 
const SliceRecordclosest_slice_to_print_level (coord_t print_level, coord_t max_epsilon=std::numeric_limits< coord_t >::max()) const
 
const SliceRecordclosest_slice_to_slice_level (float slice_level, float max_epsilon=std::numeric_limits< float >::max()) const
 
PrintTypeprint ()
 
const PrintTypeprint () const
 
bool is_step_done (PrintObjectStepEnum step) const
 
PrintStateBase::StateWithTimeStamp step_state_with_timestamp (PrintObjectStepEnum step) const
 
PrintStateBase::StateWithWarnings step_state_with_warnings (PrintObjectStepEnum step) const
 
auto last_completed_step () const
 
const ModelObjectmodel_object () const
 
ModelObjectmodel_object ()
 
ObjectID id () const
 
virtual Timestamp timestamp () const
 

Static Public Attributes

static constexpr const size_t PrintObjectStepEnumSize = COUNT
 

Protected Member Functions

 SLAPrintObject (SLAPrint *print, ModelObject *model_object)
 
 ~SLAPrintObject ()
 
void config_apply (const ConfigBase &other, bool ignore_nonexistent=false)
 
void config_apply_only (const ConfigBase &other, const t_config_option_keys &keys, bool ignore_nonexistent=false)
 
void set_trafo (const Transform3d &trafo, bool left_handed)
 
template<class InstVec >
void set_instances (InstVec &&instances)
 
bool invalidate_step (SLAPrintObjectStep step)
 
bool invalidate_all_steps ()
 
bool invalidate_state_by_config_options (const std::vector< t_config_option_key > &opt_keys)
 
bool set_started (PrintObjectStepEnum step)
 
PrintStateBase::TimeStamp set_done (PrintObjectStepEnum step)
 
bool invalidate_step (PrintObjectStepEnum step)
 
template<typename StepTypeIterator >
bool invalidate_steps (StepTypeIterator step_begin, StepTypeIterator step_end)
 
bool invalidate_steps (std::initializer_list< PrintObjectStepEnum > il)
 
bool is_step_started_unguarded (PrintObjectStepEnum step) const
 
bool is_step_done_unguarded (PrintObjectStepEnum step) const
 
bool is_step_enabled_unguarded (PrintObjectStepEnum step) const
 
void enable_step_unguarded (PrintObjectStepEnum step, bool enable)
 
void enable_all_steps_unguarded (bool enable)
 
void finalize_impl ()
 
bool query_reset_dirty_step_unguarded (PrintObjectStepEnum step)
 
void active_step_add_warning (PrintStateBase::WarningLevel warning_level, const std::string &message, int message_id=0)
 
void throw_if_canceled ()
 
void status_update_warnings (PrintBase *print, int step, PrintStateBase::WarningLevel warning_level, const std::string &message)
 
void set_new_unique_id ()
 
void set_invalid_id ()
 
void copy_id (const ObjectBase &rhs)
 
virtual void assign_new_unique_ids_recursive ()
 

Static Protected Member Functions

static std::mutex & state_mutex (PrintBase *print)
 
static std::function< void()> cancel_callback (PrintBase *print)
 

Protected Attributes

friend PrintType
 
PrintTypem_print
 
ModelObjectm_model_object
 

Private Types

using Inherited = _SLAPrintObjectBase
 
using CSGContainer = std::multiset< CSGPartForStep >
 

Private Member Functions

const std::vector< ExPolygons > & get_model_slices () const
 
const std::vector< ExPolygons > & get_support_slices () const
 
auto mesh_to_slice (SLAPrintObjectStep s) const
 
auto mesh_to_slice () const
 
template<class Archive >
void serialize (Archive &ar)
 

Static Private Member Functions

template<class T >
static T level (const SliceRecord &sr)
 
template<class T >
static SliceRecord create_slice_record (T val)
 
template<class Container , class T >
static auto closest_slice_record (Container &cont, T lvl, T eps=std::numeric_limits< T >::max()) -> decltype(cont.begin())
 
static ObjectID generate_new_id ()
 
template<class Archive >
static void load_and_construct (Archive &ar, cereal::construct< ObjectBase > &construct)
 

Private Attributes

SLAPrintObjectConfig m_config
 
Transform3d m_trafo = Transform3d::Identity()
 
bool m_left_handed = false
 
std::vector< Instancem_instances
 
std::vector< ExPolygonsm_model_slices
 
std::vector< SliceRecordm_slice_index
 
std::vector< float > m_model_height_levels
 
std::unique_ptr< SupportDatam_supportdata
 
CSGContainer m_mesh_to_slice
 
std::array< std::shared_ptr< const indexed_triangle_set >, SLAPrintObjectStep::slaposCount+1 > m_preview_meshes
 
std::unique_ptr< HollowingDatam_hollowing_data
 
PrintState< PrintObjectStepEnum, COUNT > m_state
 
ObjectID m_id
 

Static Private Attributes

static size_t s_last_id = 0
 

Friends

class SLAPrint
 
class PrintBaseWithState< SLAPrintStep, slapsCount >
 

Detailed Description


Class Documentation

◆ Slic3r::SLAPrintObject::HollowingData

class Slic3r::SLAPrintObject::HollowingData
+ Collaboration diagram for Slic3r::SLAPrintObject::HollowingData:
Class Members
InteriorPtr interior

Member Typedef Documentation

◆ CSGContainer

using Slic3r::SLAPrintObject::CSGContainer = std::multiset<CSGPartForStep>
private

◆ Inherited

◆ PrintObjectState

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
typedef PrintState<PrintObjectStepEnum, COUNT> Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::PrintObjectState
inherited

◆ PrintObjectStepEnum

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
using Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::PrintObjectStepEnum = PrintObjectStepEnumType
inherited

◆ Timestamp

Constructor & Destructor Documentation

◆ SLAPrintObject() [1/2]

Slic3r::SLAPrintObject::SLAPrintObject ( const SLAPrintObject )
delete

◆ SLAPrintObject() [2/2]

Slic3r::SLAPrintObject::SLAPrintObject ( SLAPrint print,
ModelObject model_object 
)
protected
835{}
const ModelObject * model_object() const
Definition PrintBase.hpp:362
PrintType * print()
Definition PrintBase.hpp:735
_SLAPrintObjectBase Inherited
Definition SLAPrint.hpp:90

◆ ~SLAPrintObject()

Slic3r::SLAPrintObject::~SLAPrintObject ( )
protected
837{}

Member Function Documentation

◆ active_step_add_warning()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
void Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::active_step_add_warning ( PrintStateBase::WarningLevel  warning_level,
const std::string &  message,
int  message_id = 0 
)
inlineprotectedinherited
794 {
795 std::pair<PrintObjectStepEnum, bool> active_step = m_state.active_step_add_warning(warning_level, message, message_id, PrintObjectBase::state_mutex(m_print));
796 if (active_step.second)
797 this->status_update_warnings(m_print, static_cast<int>(active_step.first), warning_level, message);
798 }
static std::mutex & state_mutex(PrintBase *print)
Definition PrintBase.cpp:110
void status_update_warnings(PrintBase *print, int step, PrintStateBase::WarningLevel warning_level, const std::string &message)
Definition PrintBase.cpp:120
PrintState< PrintObjectStepEnum, COUNT > m_state
Definition PrintBase.hpp:809
PrintType * m_print
Definition PrintBase.hpp:806
std::pair< StepType, bool > active_step_add_warning(PrintStateBase::WarningLevel warning_level, const std::string &message, int message_id, std::mutex &mtx)
Definition PrintBase.hpp:321

References Slic3r::PrintState< StepType, COUNT >::active_step_add_warning(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, Slic3r::PrintObjectBase::state_mutex(), and Slic3r::PrintObjectBase::status_update_warnings().

Referenced by Slic3r::SLAPrint::Steps::generate_preview().

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

◆ assign_new_unique_ids_recursive()

virtual void Slic3r::ObjectBase::assign_new_unique_ids_recursive ( )
inlineprotectedvirtualinherited

Reimplemented in Slic3r::Model, Slic3r::ModelObject, and Slic3r::ModelVolume.

79{ this->set_new_unique_id(); }
void set_new_unique_id()
Definition ObjectID.hpp:73

References Slic3r::ObjectBase::set_new_unique_id().

+ Here is the call graph for this function:

◆ cancel_callback()

std::function< void()> Slic3r::PrintObjectBase::cancel_callback ( PrintBase print)
staticprotectedinherited
116{
117 return print->cancel_callback();
118}

References Slic3r::PrintBase::cancel_callback().

Referenced by Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_all_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_step(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps().

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

◆ closest_slice_record()

template<class Container , class T >
static auto Slic3r::SLAPrintObject::closest_slice_record ( Container &  cont,
lvl,
eps = std::numeric_limits<T>::max() 
) -> decltype (cont.begin())
inlinestaticprivate
224 {
225 if(cont.empty()) return cont.end();
226 if(cont.size() == 1 && std::abs(level<T>(cont.front()) - lvl) > eps)
227 return cont.end();
228
229 SliceRecord query = create_slice_record(lvl);
230
231 auto it = std::lower_bound(cont.begin(), cont.end(), query,
232 [](const SliceRecord& r1,
233 const SliceRecord& r2)
234 {
235 return level<T>(r1) < level<T>(r2);
236 });
237
238 if(it == cont.end()) return it;
239
240 T diff = std::abs(level<T>(*it) - lvl);
241
242 if(it != cont.begin()) {
243 auto it_prev = std::prev(it);
244 T diff_prev = std::abs(level<T>(*it_prev) - lvl);
245 if(diff_prev < diff) { diff = diff_prev; it = it_prev; }
246 }
247
248 if(diff > eps) it = cont.end();
249
250 return it;
251 }
static SliceRecord create_slice_record(T val)
Definition SLAPrint.hpp:206
SLAPrintObject::SliceRecord SliceRecord
Definition SLAPrint.hpp:396
Slic3r::Polygons diff(const Slic3r::Polygon &subject, const Slic3r::Polygon &clip, ApplySafetyOffset do_safety_offset)
Definition ClipperUtils.cpp:672

References create_slice_record(), and Slic3r::diff().

Referenced by closest_slice_to_print_level(), closest_slice_to_slice_level(), and Slic3r::SLAPrint::Steps::slice_model().

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

◆ closest_slice_to_print_level()

const SliceRecord & Slic3r::SLAPrintObject::closest_slice_to_print_level ( coord_t  print_level,
coord_t  max_epsilon = std::numeric_limits<coord_t>::max() 
) const
inline
278 {
279 auto it = closest_slice_record(m_slice_index, print_level, max_epsilon);
280 return it == m_slice_index.end() ? SliceRecord::EMPTY : *it;
281 }
static const SliceRecord EMPTY
Definition SLAPrint.hpp:153
std::vector< SliceRecord > m_slice_index
Definition SLAPrint.hpp:335
static auto closest_slice_record(Container &cont, T lvl, T eps=std::numeric_limits< T >::max()) -> decltype(cont.begin())
Definition SLAPrint.hpp:220

References closest_slice_record(), Slic3r::SLAPrintObject::SliceRecord::EMPTY, and m_slice_index.

Referenced by Slic3r::GUI::GLCanvas3D::_render_sla_slices().

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

◆ closest_slice_to_slice_level()

const SliceRecord & Slic3r::SLAPrintObject::closest_slice_to_slice_level ( float  slice_level,
float  max_epsilon = std::numeric_limits<float>::max() 
) const
inline
289 {
290 auto it = closest_slice_record(m_slice_index, slice_level, max_epsilon);
291 return it == m_slice_index.end() ? SliceRecord::EMPTY : *it;
292 }

References closest_slice_record(), Slic3r::SLAPrintObject::SliceRecord::EMPTY, and m_slice_index.

+ Here is the call graph for this function:

◆ config()

const SLAPrintObjectConfig & Slic3r::SLAPrintObject::config ( ) const
inline
99{ return m_config; }
SLAPrintObjectConfig m_config
Definition SLAPrint.hpp:321

References m_config.

Referenced by Slic3r::SLAPrintStatistics::config(), Slic3r::SLAPrintStatistics::finalize_output_path(), Slic3r::SLAPrintStatistics::placeholders(), Slic3r::SLAPrint::Steps::slice_model(), Slic3r::SLAPrint::Steps::slice_supports(), Slic3r::SLAPrint::Steps::support_points(), Slic3r::SLAPrint::Steps::support_tree(), and Slic3r::GUI::update_arrangepoly_slaprint().

+ Here is the caller graph for this function:

◆ config_apply()

void Slic3r::SLAPrintObject::config_apply ( const ConfigBase other,
bool  ignore_nonexistent = false 
)
inlineprotected
302{ m_config.apply(other, ignore_nonexistent); }

References m_config.

◆ config_apply_only()

void Slic3r::SLAPrintObject::config_apply_only ( const ConfigBase other,
const t_config_option_keys keys,
bool  ignore_nonexistent = false 
)
inlineprotected
304 { m_config.apply_only(other, keys, ignore_nonexistent); }

References m_config.

◆ copy_id()

void Slic3r::ObjectBase::copy_id ( const ObjectBase rhs)
inlineprotectedinherited
76{ m_id = rhs.id(); }
ObjectID m_id
Definition ObjectID.hpp:82
size_t id
Definition ObjectID.hpp:37

References Slic3r::ObjectBase::id(), and Slic3r::ObjectBase::m_id.

Referenced by Slic3r::CutObjectBase::copy().

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

◆ create_slice_record()

template<class T >
static SliceRecord Slic3r::SLAPrintObject::create_slice_record ( val)
inlinestaticprivate
207 {
208 static_assert(std::is_arithmetic<T>::value, "Arithmetic only!");
209 return std::is_integral<T>::value
210 ? SliceRecord{coord_t(val), 0.f, 0.f}
211 : SliceRecord{0, float(val), 0.f};
212 }
int32_t coord_t
Definition libslic3r.h:39

Referenced by closest_slice_record().

+ Here is the caller graph for this function:

◆ enable_all_steps_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
void Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::enable_all_steps_unguarded ( bool  enable)
inlineprotectedinherited
785{ m_state.enable_all_unguarded(enable); }
void enable_all_unguarded(bool enable)
Definition PrintBase.hpp:154

References Slic3r::PrintState< StepType, COUNT >::enable_all_unguarded(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

+ Here is the call graph for this function:

◆ enable_step_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
void Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::enable_step_unguarded ( PrintObjectStepEnum  step,
bool  enable 
)
inlineprotectedinherited
784{ m_state.enable_unguarded(step, enable); }
void enable_unguarded(StepType step, bool enable)
Definition PrintBase.hpp:150

References Slic3r::PrintState< StepType, COUNT >::enable_unguarded(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by Slic3r::PrintBaseWithState< PrintStepEnumType, COUNT >::set_task_impl().

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

◆ finalize_impl()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
void Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::finalize_impl ( )
inlineprotectedinherited
void mark_canceled_unguarded()
Definition PrintBase.hpp:308

References Slic3r::PrintState< StepType, COUNT >::enable_all_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, and Slic3r::PrintState< StepType, COUNT >::mark_canceled_unguarded().

+ Here is the call graph for this function:

◆ generate_new_id()

static ObjectID Slic3r::ObjectBase::generate_new_id ( )
inlinestaticprivateinherited
84{ return ObjectID(++ s_last_id); }
static size_t s_last_id
Definition ObjectID.hpp:85

References Slic3r::ObjectBase::s_last_id.

Referenced by Slic3r::ObjectBase::set_new_unique_id().

+ Here is the caller graph for this function:

◆ get_current_elevation()

double Slic3r::SLAPrintObject::get_current_elevation ( ) const
989{
990 if (is_zero_elevation(m_config)) return 0.;
991
992 bool has_supports = is_step_done(slaposSupportTree);
993 bool has_pad = is_step_done(slaposPad);
994
995 if(!has_supports && !has_pad)
996 return 0;
997 else if(has_supports && !has_pad) {
998 return m_config.support_object_elevation.getFloat();
999 }
1000
1001 return get_elevation();
1002}
bool is_step_done(PrintObjectStepEnum step) const
Definition PrintBase.hpp:739
double get_elevation() const
Definition SLAPrint.cpp:969
@ slaposPad
Definition SLAPrint.hpp:34
@ slaposSupportTree
Definition SLAPrint.hpp:33
bool is_zero_elevation(const SLAPrintObjectConfig &c)
Definition SLAPrint.cpp:34

References get_elevation(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done(), Slic3r::is_zero_elevation(), m_config, Slic3r::slaposPad, and Slic3r::slaposSupportTree.

Referenced by Slic3r::GUI::CommonGizmosDataObjects::SelectionInfo::on_update(), Slic3r::GUI::GLCanvas3D::reload_scene(), Slic3r::GUI::GLGizmoHollow::render_points(), Slic3r::GUI::GLGizmoSlaSupports::render_points(), Slic3r::GUI::GLGizmoSlaBase::unproject_on_mesh(), Slic3r::GUI::GLGizmoHollow::update_hole_raycasters_for_picking_transform(), Slic3r::GUI::GLGizmoSlaSupports::update_point_raycasters_for_picking_transform(), and Slic3r::GUI::GLGizmoSlaBase::update_volumes().

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

◆ get_elevation()

double Slic3r::SLAPrintObject::get_elevation ( ) const
969 {
970 if (is_zero_elevation(m_config)) return 0.;
971
972 bool en = m_config.supports_enable.getBool();
973
974 double ret = en ? m_config.support_object_elevation.getFloat() : 0.;
975
976 if(m_config.pad_enable.getBool()) {
977 // Normally the elevation for the pad itself would be the thickness of
978 // its walls but currently it is half of its thickness. Whatever it
979 // will be in the future, we provide the config to the get_pad_elevation
980 // method and we will have the correct value
981 sla::PadConfig pcfg = make_pad_cfg(m_config);
982 if(!pcfg.embed_object) ret += pcfg.required_elevation();
983 }
984
985 return ret;
986}
sla::PadConfig make_pad_cfg(const SLAPrintObjectConfig &c)
Definition SLAPrint.cpp:125

References Slic3r::sla::PadConfig::embed_object, Slic3r::is_zero_elevation(), m_config, Slic3r::make_pad_cfg(), and Slic3r::sla::PadConfig::required_elevation().

Referenced by get_current_elevation(), Slic3r::SLAPrint::Steps::slice_model(), and Slic3r::GUI::update_arrangepoly_slaprint().

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

◆ get_mesh_to_print()

const std::shared_ptr< const indexed_triangle_set > & Slic3r::SLAPrintObject::get_mesh_to_print ( ) const
1077{
1078 int s = last_completed_step();
1079
1080 while (s > 0 && ! m_preview_meshes[s])
1081 --s;
1082
1083 return m_preview_meshes[s];
1084}
auto last_completed_step() const
Definition PrintBase.hpp:743
std::array< std::shared_ptr< const indexed_triangle_set >, SLAPrintObjectStep::slaposCount+1 > m_preview_meshes
Definition SLAPrint.hpp:382

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::last_completed_step(), and m_preview_meshes.

Referenced by Slic3r::GUI::GLGizmoHollow::data_changed(), Slic3r::GUI::Plater::export_stl_obj(), Slic3r::SLAPrint::Steps::generate_pad(), Slic3r::SLAPrint::Steps::generate_preview(), Slic3r::GLVolumeCollection::load_object_auxiliary(), Slic3r::GUI::CommonGizmosDataObjects::Raycaster::on_update(), Slic3r::GUI::CommonGizmosDataObjects::SupportsClipper::on_update(), Slic3r::SLAPrint::Steps::support_points(), Slic3r::GUI::update_arrangepoly_slaprint(), and Slic3r::GUI::GLGizmoSlaBase::update_volumes().

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

◆ get_model_slices()

const std::vector< ExPolygons > & Slic3r::SLAPrintObject::get_model_slices ( ) const
inlineprivate
253{ return m_model_slices; }
std::vector< ExPolygons > m_model_slices
Definition SLAPrint.hpp:331

References m_model_slices.

Referenced by Slic3r::SLAPrintObject::SliceRecord::get_slice(), and Slic3r::SLAPrint::Steps::support_points().

+ Here is the caller graph for this function:

◆ get_parts_to_slice() [1/2]

std::vector< csg::CSGPart > Slic3r::SLAPrintObject::get_parts_to_slice ( ) const
1087{
1089}
std::vector< csg::CSGPart > get_parts_to_slice() const
Definition SLAPrint.cpp:1086
@ slaposCount
Definition SLAPrint.hpp:36

References get_parts_to_slice(), and Slic3r::slaposCount.

Referenced by get_parts_to_slice(), Slic3r::GLVolumeCollection::load_object_auxiliary(), Slic3r::GUI::CommonGizmosDataObjects::ObjectClipper::on_update(), and Slic3r::GUI::processed_objects_idxs().

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

◆ get_parts_to_slice() [2/2]

std::vector< csg::CSGPart > Slic3r::SLAPrintObject::get_parts_to_slice ( SLAPrintObjectStep  step) const
1093{
1094 auto laststep = last_completed_step();
1095 SLAPrintObjectStep s = std::min(untilstep, laststep);
1096
1097 if (s == slaposCount)
1098 return {};
1099
1100 std::vector<csg::CSGPart> ret;
1101
1102 for (unsigned int step = 0; step < s; ++step) {
1103 auto r = m_mesh_to_slice.equal_range(SLAPrintObjectStep(step));
1104 csg::copy_csgrange_shallow(Range{r.first, r.second}, std::back_inserter(ret));
1105 }
1106
1107 return ret;
1108}
CSGContainer m_mesh_to_slice
Definition SLAPrint.hpp:367
void copy_csgrange_shallow(const Range< It > &csgrange, OutIt out)
Definition CSGMeshCopy.hpp:12
SLAPrintObjectStep
Definition SLAPrint.hpp:27
Coord step(const Coord &crd, Dir d)
Definition MarchingSquares.hpp:137

References Slic3r::csg::copy_csgrange_shallow(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::last_completed_step(), m_mesh_to_slice, and Slic3r::slaposCount.

+ Here is the call graph for this function:

◆ get_slice_index()

const std::vector< SliceRecord > & Slic3r::SLAPrintObject::get_slice_index ( ) const
inline
268 {
269 return m_slice_index;
270 }

References m_slice_index.

Referenced by Slic3r::GUI::GLCanvas3D::_render_sla_slices().

+ Here is the caller graph for this function:

◆ get_support_points()

const std::vector< sla::SupportPoint > & Slic3r::SLAPrintObject::get_support_points ( ) const
1034{
1036}
std::unique_ptr< SupportData > m_supportdata
Definition SLAPrint.hpp:364
const std::vector< sla::SupportPoint > EMPTY_SUPPORT_POINTS
Definition SLAPrint.cpp:1028

References m_supportdata.

◆ get_support_slices()

const std::vector< ExPolygons > & Slic3r::SLAPrintObject::get_support_slices ( ) const
private
1039{
1040 // assert(is_step_done(slaposSliceSupports));
1041 if (!m_supportdata) return EMPTY_SLICES;
1042 return m_supportdata->support_slices;
1043}
const std::vector< ExPolygons > EMPTY_SLICES
Definition SLAPrint.cpp:1024

References m_supportdata.

Referenced by Slic3r::SLAPrintObject::SliceRecord::get_slice().

+ Here is the caller graph for this function:

◆ id()

ObjectID Slic3r::ObjectBase::id ( ) const
inlineinherited
55{ return m_id; }

References Slic3r::ObjectBase::m_id.

Referenced by Slic3r::Model::Model(), Slic3r::ModelInstance::ModelInstance(), Slic3r::ModelMaterial::ModelMaterial(), Slic3r::ModelObject::ModelObject(), Slic3r::ModelObject::ModelObject(), Slic3r::ModelObject::ModelObject(), Slic3r::ModelObject::ModelObject(), Slic3r::ModelObject::ModelObject(), Slic3r::ModelVolume::ModelVolume(), Slic3r::ModelVolume::ModelVolume(), Slic3r::ModelVolume::ModelVolume(), Slic3r::_3MF_Importer::_load_model_from_file(), Slic3r::GUI::Plater::priv::actualize_slicing_warnings(), Slic3r::ModelObjectStatusDB::add(), Slic3r::ModelObjectStatusDB::add_if_new(), Slic3r::Print::apply(), Slic3r::SLAPrint::apply(), Slic3r::GUI::GLGizmoFdmSupports::apply_data_from_backend(), Slic3r::ModelVolume::check(), Slic3r::check_model_ids_equal(), Slic3r::ModelObject::convert_units(), Slic3r::ObjectBase::copy_id(), Slic3r::PrintObjectStatusDB::count(), anonymous_namespace{RaycastManager.cpp}::create_key(), priv::create_volume(), Slic3r::GUI::Emboss::create_volume_sources(), Slic3r::GUI::GLGizmoHollow::data_changed(), Slic3r::GUI::GLGizmoPainterBase::data_changed(), Slic3r::GUI::GLGizmoSlaSupports::data_changed(), Slic3r::Model::delete_object(), Slic3r::GUI::Plater::export_stl_obj(), Slic3r::ModelObjectStatusDB::get(), Slic3r::GUI::get_arrange_poly(), Slic3r::GUI::GLGizmoSlaSupports::get_data_from_backend(), Slic3r::PrintObjectStatusDB::get_range(), Slic3r::GUI::GLGizmoFdmSupports::has_backend_supports(), Slic3r::GUI::GLGizmoSlaSupports::has_backend_supports(), Slic3r::CutObjectBase::has_same_id(), Slic3r::UndoRedo::StackImpl::immutable_object_id_impl(), Slic3r::GUI::GLGizmoSimplify::init_model(), Slic3r::inner_brim_area(), Slic3r::ModelObject::is_cut(), Slic3r::CutObjectBase::is_equal(), Slic3r::ObjectBase::load_and_construct(), Slic3r::UndoRedo::StackImpl::load_snapshot(), Slic3r::GUI::ObjectList::merge(), Slic3r::model_property_changed(), Slic3r::model_volume_list_changed(), Slic3r::model_volume_list_copy_configs(), Slic3r::ModelConfigObject::object_id_and_timestamp_match(), Slic3r::ObjectWithTimestamp::object_id_and_timestamp_match(), Slic3r::GUI::GLGizmoEmboss::on_mouse_change_selection(), Slic3r::GUI::CommonGizmosDataObjects::SelectionInfo::on_update(), Slic3r::CutObjectBase::operator<(), Slic3r::Model::operator=(), Slic3r::ModelObject::operator=(), Slic3r::ModelObject::operator=(), Slic3r::CutObjectBase::operator==(), Slic3r::GUI::GLGizmoCut3D::perform_cut(), Slic3r::GUI::GLGizmoEmboss::process(), Slic3r::GUI::processed_objects_idxs(), Slic3r::GUI::GLCanvas3D::reload_scene(), Slic3r::GUI::GLCanvas3D::LayersEditing::select_object(), Slic3r::ModelMaterial::serialize(), Slic3r::SLAPrintObject::SliceRecord::set_model_slice_idx(), Slic3r::SLAPrintObject::SliceRecord::set_support_slice_idx(), Slic3r::slices_to_regions(), Slic3r::ModelObject::split(), Slic3r::UndoRedo::StackImpl::take_snapshot(), Slic3r::top_level_outer_brim_area(), Slic3r::GUI::update_object_cut_id(), and anonymous_namespace{EmbossJob.cpp}::update_volume_name().

◆ instances()

const std::vector< Instance > & Slic3r::SLAPrintObject::instances ( ) const
inline
113{ return m_instances; }
std::vector< Instance > m_instances
Definition SLAPrint.hpp:328

References m_instances.

Referenced by Slic3r::GUI::GLCanvas3D::_render_sla_slices(), Slic3r::get_all_polygons(), and set_instances().

+ Here is the caller graph for this function:

◆ invalidate_all_steps()

bool Slic3r::SLAPrintObject::invalidate_all_steps ( )
protected
965{
966 return Inherited::invalidate_all_steps() || m_print->invalidate_all_steps();
967}
bool invalidate_all_steps()
Definition PrintBase.hpp:777

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_all_steps(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print.

Referenced by invalidate_step().

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

◆ invalidate_state_by_config_options()

bool Slic3r::SLAPrintObject::invalidate_state_by_config_options ( const std::vector< t_config_option_key > &  opt_keys)
protected
842{
843 if (opt_keys.empty())
844 return false;
845
846 std::vector<SLAPrintObjectStep> steps;
847 bool invalidated = false;
848 for (const t_config_option_key &opt_key : opt_keys) {
849 if ( opt_key == "hollowing_enable"
850 || opt_key == "hollowing_min_thickness"
851 || opt_key == "hollowing_quality"
852 || opt_key == "hollowing_closing_distance"
853 ) {
854 steps.emplace_back(slaposHollowing);
855 } else if (
856 opt_key == "layer_height"
857 || opt_key == "faded_layers"
858 || opt_key == "pad_enable"
859 || opt_key == "pad_wall_thickness"
860 || opt_key == "supports_enable"
861 || opt_key == "support_tree_type"
862 || opt_key == "support_object_elevation"
863 || opt_key == "branchingsupport_object_elevation"
864 || opt_key == "pad_around_object"
865 || opt_key == "pad_around_object_everywhere"
866 || opt_key == "slice_closing_radius"
867 || opt_key == "slicing_mode") {
868 steps.emplace_back(slaposObjectSlice);
869 } else if (
870 opt_key == "support_points_density_relative"
871 || opt_key == "support_enforcers_only"
872 || opt_key == "support_points_minimal_distance") {
873 steps.emplace_back(slaposSupportPoints);
874 } else if (
875 opt_key == "support_head_front_diameter"
876 || opt_key == "support_head_penetration"
877 || opt_key == "support_head_width"
878 || opt_key == "support_pillar_diameter"
879 || opt_key == "support_pillar_widening_factor"
880 || opt_key == "support_small_pillar_diameter_percent"
881 || opt_key == "support_max_weight_on_model"
882 || opt_key == "support_max_bridges_on_pillar"
883 || opt_key == "support_pillar_connection_mode"
884 || opt_key == "support_buildplate_only"
885 || opt_key == "support_base_diameter"
886 || opt_key == "support_base_height"
887 || opt_key == "support_critical_angle"
888 || opt_key == "support_max_bridge_length"
889 || opt_key == "support_max_pillar_link_distance"
890 || opt_key == "support_base_safety_distance"
891
892 || opt_key == "branchingsupport_head_front_diameter"
893 || opt_key == "branchingsupport_head_penetration"
894 || opt_key == "branchingsupport_head_width"
895 || opt_key == "branchingsupport_pillar_diameter"
896 || opt_key == "branchingsupport_pillar_widening_factor"
897 || opt_key == "branchingsupport_small_pillar_diameter_percent"
898 || opt_key == "branchingsupport_max_weight_on_model"
899 || opt_key == "branchingsupport_max_bridges_on_pillar"
900 || opt_key == "branchingsupport_pillar_connection_mode"
901 || opt_key == "branchingsupport_buildplate_only"
902 || opt_key == "branchingsupport_base_diameter"
903 || opt_key == "branchingsupport_base_height"
904 || opt_key == "branchingsupport_critical_angle"
905 || opt_key == "branchingsupport_max_bridge_length"
906 || opt_key == "branchingsupport_max_pillar_link_distance"
907 || opt_key == "branchingsupport_base_safety_distance"
908
909 || opt_key == "pad_object_gap"
910 ) {
911 steps.emplace_back(slaposSupportTree);
912 } else if (
913 opt_key == "pad_wall_height"
914 || opt_key == "pad_brim_size"
915 || opt_key == "pad_max_merge_distance"
916 || opt_key == "pad_wall_slope"
917 || opt_key == "pad_edge_radius"
918 || opt_key == "pad_object_connector_stride"
919 || opt_key == "pad_object_connector_width"
920 || opt_key == "pad_object_connector_penetration"
921 ) {
922 steps.emplace_back(slaposPad);
923 } else {
924 // All keys should be covered.
925 assert(false);
926 }
927 }
928
930 for (SLAPrintObjectStep step : steps)
931 invalidated |= this->invalidate_step(step);
932 return invalidated;
933}
bool invalidate_step(SLAPrintObjectStep step)
Definition SLAPrint.cpp:935
std::string t_config_option_key
Definition Config.hpp:76
@ slaposObjectSlice
Definition SLAPrint.hpp:31
@ slaposHollowing
Definition SLAPrint.hpp:29
@ slaposSupportPoints
Definition SLAPrint.hpp:32
void sort_remove_duplicates(std::vector< T > &vec)
Definition libslic3r.h:188

References invalidate_step(), Slic3r::slaposHollowing, Slic3r::slaposObjectSlice, Slic3r::slaposPad, Slic3r::slaposSupportPoints, Slic3r::slaposSupportTree, and Slic3r::sort_remove_duplicates().

+ Here is the call graph for this function:

◆ invalidate_step() [1/2]

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_step ( PrintObjectStepEnum  step)
inlineprotectedinherited
static std::function< void()> cancel_callback(PrintBase *print)
Definition PrintBase.cpp:115
bool invalidate(StepType step, CancelationCallback cancel)
Definition PrintBase.hpp:227

References Slic3r::PrintObjectBase::cancel_callback(), Slic3r::PrintState< StepType, COUNT >::invalidate(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by invalidate_step().

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

◆ invalidate_step() [2/2]

bool Slic3r::SLAPrintObject::invalidate_step ( SLAPrintObjectStep  step)
protected
936{
937 bool invalidated = Inherited::invalidate_step(step);
938 // propagate to dependent steps
939 if (step == slaposAssembly) {
940 invalidated |= this->invalidate_all_steps();
941 } else if (step == slaposHollowing) {
943 } else if (step == slaposDrillHoles) {
945 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
946 } else if (step == slaposObjectSlice) {
948 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
949 } else if (step == slaposSupportPoints) {
951 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
952 } else if (step == slaposSupportTree) {
953 invalidated |= this->invalidate_steps({ slaposPad, slaposSliceSupports });
954 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
955 } else if (step == slaposPad) {
956 invalidated |= this->invalidate_steps({slaposSliceSupports});
957 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
958 } else if (step == slaposSliceSupports) {
959 invalidated |= m_print->invalidate_step(slapsMergeSlicesAndEval);
960 }
961 return invalidated;
962}
bool invalidate_step(PrintObjectStepEnum step)
Definition PrintBase.hpp:770
bool invalidate_steps(StepTypeIterator step_begin, StepTypeIterator step_end)
Definition PrintBase.hpp:773
bool invalidate_all_steps()
Definition SLAPrint.cpp:964
@ slaposAssembly
Definition SLAPrint.hpp:28
@ slaposDrillHoles
Definition SLAPrint.hpp:30
@ slaposSliceSupports
Definition SLAPrint.hpp:35
@ slapsMergeSlicesAndEval
Definition SLAPrint.hpp:22

References invalidate_all_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_step(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::slaposAssembly, Slic3r::slaposDrillHoles, Slic3r::slaposHollowing, Slic3r::slaposObjectSlice, Slic3r::slaposPad, Slic3r::slaposSliceSupports, Slic3r::slaposSupportPoints, Slic3r::slaposSupportTree, and Slic3r::slapsMergeSlicesAndEval.

Referenced by invalidate_state_by_config_options().

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

◆ invalidate_steps() [1/2]

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps ( std::initializer_list< PrintObjectStepEnum il)
inlineprotectedinherited
776 { return m_state.invalidate_multiple(il.begin(), il.end(), PrintObjectBase::cancel_callback(m_print)); }
bool invalidate_multiple(StepTypeIterator step_begin, StepTypeIterator step_end, CancelationCallback cancel)
Definition PrintBase.hpp:249

References Slic3r::PrintObjectBase::cancel_callback(), Slic3r::PrintState< StepType, COUNT >::invalidate_multiple(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

+ Here is the call graph for this function:

◆ invalidate_steps() [2/2]

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
template<typename StepTypeIterator >
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps ( StepTypeIterator  step_begin,
StepTypeIterator  step_end 
)
inlineprotectedinherited
774 { return m_state.invalidate_multiple(step_begin, step_end, PrintObjectBase::cancel_callback(m_print)); }

References Slic3r::PrintObjectBase::cancel_callback(), Slic3r::PrintState< StepType, COUNT >::invalidate_multiple(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by invalidate_step().

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

◆ is_left_handed()

bool Slic3r::SLAPrintObject::is_left_handed ( ) const
inline
101{ return m_left_handed; }
bool m_left_handed
Definition SLAPrint.hpp:326

References m_left_handed.

Referenced by Slic3r::GUI::GLCanvas3D::_render_sla_slices(), and Slic3r::get_all_polygons().

+ Here is the caller graph for this function:

◆ is_step_done()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done ( PrintObjectStepEnum  step) const
inlineinherited
bool is_done(StepType step, std::mutex &mtx) const
Definition PrintBase.hpp:134

References Slic3r::PrintState< StepType, COUNT >::is_done(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, and Slic3r::PrintObjectBase::state_mutex().

Referenced by Slic3r::GUI::GLCanvas3D::_load_print_object_toolpaths(), Slic3r::GUI::GLCanvas3D::_render_sla_slices(), get_current_elevation(), pad_mesh(), and support_mesh().

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

◆ is_step_done_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done_unguarded ( PrintObjectStepEnum  step) const
inlineprotectedinherited
781{ return m_state.is_done_unguarded(step); }
bool is_done_unguarded(StepType step) const
Definition PrintBase.hpp:146

References Slic3r::PrintState< StepType, COUNT >::is_done_unguarded(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::last_completed_step().

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

◆ is_step_enabled_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_enabled_unguarded ( PrintObjectStepEnum  step) const
inlineprotectedinherited
783{ return m_state.is_enabled_unguarded(step); }
bool is_enabled_unguarded(StepType step) const
Definition PrintBase.hpp:159

References Slic3r::PrintState< StepType, COUNT >::is_enabled_unguarded(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by Slic3r::PrintBaseWithState< PrintStepEnumType, COUNT >::set_task_impl().

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

◆ is_step_started_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_started_unguarded ( PrintObjectStepEnum  step) const
inlineprotectedinherited
780{ return m_state.is_started_unguarded(step); }
bool is_started_unguarded(StepType step) const
Definition PrintBase.hpp:142

References Slic3r::PrintState< StepType, COUNT >::is_started_unguarded(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state.

Referenced by Slic3r::PrintBaseWithState< PrintStepEnumType, COUNT >::set_task_impl().

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

◆ last_completed_step()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
auto Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::last_completed_step ( ) const
inlineinherited
744 {
745 static_assert(COUNT > 0, "Step count should be > 0");
746 auto s = int(COUNT) - 1;
747
748 std::lock_guard lk(state_mutex(m_print));
749 while (s >= 0 && ! is_step_done_unguarded(PrintObjectStepEnum(s)))
750 --s;
751
752 if (s < 0)
753 s = COUNT;
754
755 return PrintObjectStepEnum(s);
756 }
bool is_step_done_unguarded(PrintObjectStepEnum step) const
Definition PrintBase.hpp:781
PrintObjectStepEnumType PrintObjectStepEnum
Definition PrintBase.hpp:732

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, and Slic3r::PrintObjectBase::state_mutex().

Referenced by Slic3r::GUI::GLGizmoSlaSupports::data_changed(), get_mesh_to_print(), get_parts_to_slice(), Slic3r::GUI::update_arrangepoly_slaprint(), and Slic3r::GUI::GLGizmoSlaBase::update_volumes().

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

◆ level()

template<class T >
static T Slic3r::SLAPrintObject::level ( const SliceRecord sr)
inlinestaticprivate
200 {
201 static_assert(std::is_arithmetic<T>::value, "Arithmetic only!");
202 return std::is_integral<T>::value ? T(sr.print_level())
203 : T(sr.slice_level());
204 }

References Slic3r::SLAPrintObject::SliceRecord::print_level(), and Slic3r::SLAPrintObject::SliceRecord::slice_level().

+ Here is the call graph for this function:

◆ load_and_construct()

template<class Archive >
static void Slic3r::ObjectBase::load_and_construct ( Archive &  ar,
cereal::construct< ObjectBase > &  construct 
)
inlinestaticprivateinherited
96{ ObjectID id; ar(id); construct(id); }
ObjectID id() const
Definition ObjectID.hpp:55

References Slic3r::ObjectBase::id().

+ Here is the call graph for this function:

◆ mesh_to_slice() [1/2]

auto Slic3r::SLAPrintObject::mesh_to_slice ( ) const
inlineprivate
376{ return range(m_mesh_to_slice); }
auto range(Cont &&cont)
Definition libslic3r.h:356

References Slic3r::range().

+ Here is the call graph for this function:

◆ mesh_to_slice() [2/2]

auto Slic3r::SLAPrintObject::mesh_to_slice ( SLAPrintObjectStep  s) const
inlineprivate
370 {
371 auto r = m_mesh_to_slice.equal_range(s);
372
373 return Range{r.first, r.second};
374 }

Referenced by Slic3r::SLAPrint::Steps::generate_preview(), Slic3r::SLAPrint::Steps::hollow_model(), and Slic3r::SLAPrint::Steps::slice_model().

+ Here is the caller graph for this function:

◆ model_object() [1/2]

ModelObject * Slic3r::PrintObjectBase::model_object ( )
inlineinherited
363{ return m_model_object; }
ModelObject * m_model_object
Definition PrintBase.hpp:376

References Slic3r::PrintObjectBase::m_model_object.

◆ model_object() [2/2]

◆ operator=()

SLAPrintObject & Slic3r::SLAPrintObject::operator= ( const SLAPrintObject )
delete

◆ pad_mesh()

const TriangleMesh & Slic3r::SLAPrintObject::pad_mesh ( ) const
1068{
1069 if(m_config.pad_enable.getBool() && is_step_done(slaposPad) && m_supportdata)
1070 return m_supportdata->pad_mesh;
1071
1072 return EMPTY_MESH;
1073}
const TriangleMesh EMPTY_MESH
Definition SLAPrint.cpp:1025

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done(), m_config, m_supportdata, and Slic3r::slaposPad.

Referenced by Slic3r::GLVolumeCollection::load_object_auxiliary(), Slic3r::GUI::CommonGizmosDataObjects::SupportsClipper::on_update(), and Slic3r::GUI::GLGizmoSlaBase::update_volumes().

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

◆ print() [1/2]

◆ print() [2/2]

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
const PrintType * Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::print ( ) const
inlineinherited

◆ query_reset_dirty_step_unguarded()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::query_reset_dirty_step_unguarded ( PrintObjectStepEnum  step)
inlineprotectedinherited
790{ return m_state.query_reset_dirty_unguarded(step); }
bool query_reset_dirty_unguarded(StepType step)
Definition PrintBase.hpp:297

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, and Slic3r::PrintState< StepType, COUNT >::query_reset_dirty_unguarded().

+ Here is the call graph for this function:

◆ serialize()

template<class Archive >
void Slic3r::ObjectBase::serialize ( Archive &  ar)
inlineprivateinherited
92{ ar(m_id); }

References Slic3r::ObjectBase::m_id.

◆ set_done()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
PrintStateBase::TimeStamp Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_done ( PrintObjectStepEnum  step)
inlineprotectedinherited
763 {
764 std::pair<PrintStateBase::TimeStamp, bool> status = m_state.set_done(step, PrintObjectBase::state_mutex(m_print), [this](){ this->throw_if_canceled(); });
765 if (status.second)
766 this->status_update_warnings(m_print, static_cast<int>(step), PrintStateBase::WarningLevel::NON_CRITICAL, std::string());
767 return status.first;
768 }
void throw_if_canceled()
Definition PrintBase.hpp:803
std::pair< TimeStamp, bool > set_done(StepType step, std::mutex &mtx, ThrowIfCanceled throw_if_canceled)
Definition PrintBase.hpp:202

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, Slic3r::PrintStateBase::NON_CRITICAL, Slic3r::PrintState< StepType, COUNT >::set_done(), Slic3r::PrintObjectBase::state_mutex(), Slic3r::PrintObjectBase::status_update_warnings(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::throw_if_canceled().

+ Here is the call graph for this function:

◆ set_instances()

template<class InstVec >
void Slic3r::SLAPrintObject::set_instances ( InstVec &&  instances)
inlineprotected
311{ m_instances = std::forward<InstVec>(instances); }
const std::vector< Instance > & instances() const
Definition SLAPrint.hpp:113

References instances(), and m_instances.

+ Here is the call graph for this function:

◆ set_invalid_id()

void Slic3r::ObjectBase::set_invalid_id ( )
inlineprotectedinherited
74{ m_id = 0; }

References Slic3r::ObjectBase::m_id.

Referenced by Slic3r::CutObjectBase::invalidate().

+ Here is the caller graph for this function:

◆ set_new_unique_id()

void Slic3r::ObjectBase::set_new_unique_id ( )
inlineprotectedinherited
73{ m_id = generate_new_id(); }
static ObjectID generate_new_id()
Definition ObjectID.hpp:84

References Slic3r::ObjectBase::generate_new_id(), and Slic3r::ObjectBase::m_id.

Referenced by Slic3r::ModelVolume::ModelVolume(), Slic3r::Model::assign_new_unique_ids_recursive(), Slic3r::ObjectBase::assign_new_unique_ids_recursive(), Slic3r::ModelObject::assign_new_unique_ids_recursive(), Slic3r::CutObjectBase::init(), Slic3r::ModelMaterial::set_new_unique_id(), Slic3r::ModelObject::set_new_unique_id(), and Slic3r::ModelVolume::set_new_unique_id().

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

◆ set_started()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
bool Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_started ( PrintObjectStepEnum  step)
inlineprotectedinherited
762 { return m_state.set_started(step, PrintObjectBase::state_mutex(m_print), [this](){ this->throw_if_canceled(); }); }
bool set_started(StepType step, std::mutex &mtx, ThrowIfCanceled throw_if_canceled)
Definition PrintBase.hpp:169

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, Slic3r::PrintState< StepType, COUNT >::set_started(), Slic3r::PrintObjectBase::state_mutex(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::throw_if_canceled().

+ Here is the call graph for this function:

◆ set_trafo()

void Slic3r::SLAPrintObject::set_trafo ( const Transform3d trafo,
bool  left_handed 
)
inlineprotected
306 {
307 m_trafo = trafo;
308 m_left_handed = left_handed;
309 }
const Transform3d & trafo() const
Definition SLAPrint.hpp:100
Transform3d m_trafo
Definition SLAPrint.hpp:324

References m_left_handed, m_trafo, and trafo().

+ Here is the call graph for this function:

◆ state_mutex()

◆ status_update_warnings()

void Slic3r::PrintObjectBase::status_update_warnings ( PrintBase print,
int  step,
PrintStateBase::WarningLevel  warning_level,
const std::string &  message 
)
protectedinherited
121{
122 print->status_update_warnings(step, warning_level, message, this);
123}

References Slic3r::PrintBase::status_update_warnings().

Referenced by Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::active_step_add_warning(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_done().

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

◆ step_state_with_timestamp()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
PrintStateBase::StateWithTimeStamp Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::step_state_with_timestamp ( PrintObjectStepEnum  step) const
inlineinherited
StateWithTimeStamp state_with_timestamp(StepType step, std::mutex &mtx) const
Definition PrintBase.hpp:118

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, Slic3r::PrintObjectBase::state_mutex(), and Slic3r::PrintState< StepType, COUNT >::state_with_timestamp().

+ Here is the call graph for this function:

◆ step_state_with_warnings()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
PrintStateBase::StateWithWarnings Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::step_state_with_warnings ( PrintObjectStepEnum  step) const
inlineinherited
StateWithWarnings state_with_warnings(StepType step, std::mutex &mtx) const
Definition PrintBase.hpp:124

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print, Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state, Slic3r::PrintObjectBase::state_mutex(), and Slic3r::PrintState< StepType, COUNT >::state_with_warnings().

Referenced by Slic3r::GUI::Plater::priv::on_slicing_update().

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

◆ support_mesh()

const TriangleMesh & Slic3r::SLAPrintObject::support_mesh ( ) const
1058{
1059 if (m_config.supports_enable.getBool() &&
1062 return m_supportdata->tree_mesh;
1063
1064 return EMPTY_MESH;
1065}

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done(), m_config, m_supportdata, and Slic3r::slaposSupportTree.

Referenced by Slic3r::GLVolumeCollection::load_object_auxiliary(), Slic3r::GUI::CommonGizmosDataObjects::SupportsClipper::on_update(), Slic3r::SLAPrint::Steps::support_tree(), Slic3r::GUI::update_arrangepoly_slaprint(), and Slic3r::GUI::GLGizmoSlaBase::update_volumes().

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

◆ throw_if_canceled()

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
void Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::throw_if_canceled ( )
inlineprotectedinherited
803{ if (m_print->canceled()) throw CanceledException(); }

References Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print.

Referenced by Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_done(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_started().

+ Here is the caller graph for this function:

◆ timestamp()

virtual Timestamp Slic3r::ObjectBase::timestamp ( ) const
inlinevirtualinherited

Reimplemented in Slic3r::ModelConfigObject, and Slic3r::ObjectWithTimestamp.

60{ return 0; }

Referenced by Slic3r::GUI::Plater::priv::undo_redo_to().

+ Here is the caller graph for this function:

◆ trafo()

◆ transformed_drainhole_points()

sla::DrainHoles Slic3r::SLAPrintObject::transformed_drainhole_points ( ) const
1118{
1119 assert(model_object());
1120
1122}
DrainHoles transformed_drainhole_points(const ModelObject &mo, const Transform3d &trafo)
Definition Hollowing.cpp:717

References Slic3r::PrintObjectBase::model_object(), trafo(), and Slic3r::sla::transformed_drainhole_points().

Referenced by Slic3r::SLAPrint::Steps::generate_preview().

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

◆ transformed_support_points()

sla::SupportPoints Slic3r::SLAPrintObject::transformed_support_points ( ) const
1111{
1112 assert(model_object());
1113
1115}
SupportPoints transformed_support_points(const ModelObject &mo, const Transform3d &trafo)
Definition SupportPointGenerator.cpp:664

References Slic3r::PrintObjectBase::model_object(), trafo(), and Slic3r::sla::transformed_support_points().

Referenced by Slic3r::SLAPrint::Steps::support_points().

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

Friends And Related Symbol Documentation

◆ PrintBaseWithState< SLAPrintStep, slapsCount >

friend class PrintBaseWithState< SLAPrintStep, slapsCount >
friend

◆ SLAPrint

friend class SLAPrint
friend

Member Data Documentation

◆ m_config

◆ m_hollowing_data

◆ m_id

◆ m_instances

std::vector<Instance> Slic3r::SLAPrintObject::m_instances
private

Referenced by instances(), and set_instances().

◆ m_left_handed

bool Slic3r::SLAPrintObject::m_left_handed = false
private

Referenced by is_left_handed(), and set_trafo().

◆ m_mesh_to_slice

◆ m_model_height_levels

std::vector<float> Slic3r::SLAPrintObject::m_model_height_levels
private

◆ m_model_object

◆ m_model_slices

std::vector<ExPolygons> Slic3r::SLAPrintObject::m_model_slices
private

◆ m_preview_meshes

std::array<std::shared_ptr<const indexed_triangle_set>, SLAPrintObjectStep::slaposCount + 1> Slic3r::SLAPrintObject::m_preview_meshes
private

◆ m_print

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
PrintType* Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_print
protectedinherited

◆ m_slice_index

◆ m_state

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
PrintState<PrintObjectStepEnum, COUNT> Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::m_state
privateinherited

Referenced by Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::active_step_add_warning(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::enable_all_steps_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::enable_step_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::finalize_impl(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_all_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_step(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::invalidate_steps(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_done_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_enabled_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::is_step_started_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::query_reset_dirty_step_unguarded(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_done(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::set_started(), Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::step_state_with_timestamp(), and Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::step_state_with_warnings().

◆ m_supportdata

◆ m_trafo

Transform3d Slic3r::SLAPrintObject::m_trafo = Transform3d::Identity()
private

Referenced by set_trafo(), and trafo().

◆ PrintObjectStepEnumSize

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
constexpr const size_t Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::PrintObjectStepEnumSize = COUNT
staticconstexprinherited

◆ PrintType

template<typename PrintType , typename PrintObjectStepEnumType , const size_t COUNT>
friend Slic3r::PrintObjectBaseWithState< PrintType, PrintObjectStepEnumType, COUNT >::PrintType
protectedinherited

◆ s_last_id

size_t Slic3r::ObjectBase::s_last_id = 0
staticprivateinherited

The documentation for this class was generated from the following files: