◆ LayerRanges() [1/2]
| Slic3r::LayerRanges::LayerRanges |
( |
| ) |
|
|
default |
◆ LayerRanges() [2/2]
void assign(const t_layer_config_ranges &in)
Definition PrintApply.cpp:432
References assign().
◆ assign()
432 {
435
437 for (
const std::pair<const t_layer_height_range, ModelConfig> &
range : in)
438 if (
range.first.second > last_z) {
440 if (min_z > last_z +
EPSILON) {
442 last_z = min_z;
443 }
445 const DynamicPrintConfig *cfg = &
range.second.get();
447 last_z =
range.first.second;
448 }
449 }
452 else if (
m_ranges.back().config ==
nullptr)
453 m_ranges.back().layer_height_range.second = DBL_MAX;
454 else
456 }
#define EPSILON
Definition ColorUtils.cpp:64
std::vector< LayerRange > m_ranges
Definition PrintApply.cpp:477
double coordf_t
Definition GUI_ObjectList.hpp:46
auto range(Cont &&cont)
Definition libslic3r.h:405
std::pair< coordf_t, coordf_t > t_layer_height_range
Definition Slicing.hpp:159
References EPSILON, m_ranges, and Slic3r::range().
Referenced by LayerRanges().
◆ begin()
| std::vector< LayerRange >::const_iterator Slic3r::LayerRanges::begin |
( |
| ) |
const |
|
inline |
◆ config()
458 {
459 auto it = std::lower_bound(
m_ranges.begin(),
m_ranges.end(),
LayerRange{ { range.first - EPSILON, range.second - EPSILON } });
460
461
462
463
465 std::abs(it->layer_height_range.first -
range.first) >
EPSILON ||
466 std::abs(it->layer_height_range.second -
range.second) >
EPSILON )
467 return nullptr;
468 return it ==
m_ranges.end() ? nullptr : it->config;
469 }
Definition PrintApply.cpp:420
References m_ranges, and Slic3r::range().
◆ end()
| std::vector< LayerRange >::const_iterator Slic3r::LayerRanges::end |
( |
| ) |
const |
|
inline |
◆ size()
| size_t Slic3r::LayerRanges::size |
( |
| ) |
const |
|
inline |
◆ m_ranges
| std::vector<LayerRange> Slic3r::LayerRanges::m_ranges |
|
private |
The documentation for this class was generated from the following file: