Fixed some more warnings (mostly GLGizmoSlaSupports.cpp)

This commit is contained in:
Lukas Matena 2019-09-04 16:05:32 +02:00
parent 570bec299f
commit 09e4ac42ba
6 changed files with 13 additions and 17 deletions

View file

@ -108,7 +108,6 @@ static inline bool opts_equal(const DynamicConfig &config_old, const DynamicConf
std::vector<std::string> PlaceholderParser::config_diff(const DynamicPrintConfig &rhs)
{
const ConfigDef *def = rhs.def();
std::vector<std::string> diff_keys;
for (const t_config_option_key &opt_key : rhs.keys())
if (! opts_equal(m_config, rhs, opt_key))
@ -124,7 +123,6 @@ std::vector<std::string> PlaceholderParser::config_diff(const DynamicPrintConfig
// a current extruder ID is used.
bool PlaceholderParser::apply_config(const DynamicPrintConfig &rhs)
{
const ConfigDef *def = rhs.def();
bool modified = false;
for (const t_config_option_key &opt_key : rhs.keys()) {
if (! opts_equal(m_config, rhs, opt_key)) {

View file

@ -2049,7 +2049,7 @@ void PrintConfigDef::init_fff_params()
{
int threads = (unsigned int)boost::thread::hardware_concurrency();
def->set_default_value(new ConfigOptionInt(threads > 0 ? threads : 2));
def->cli == ConfigOptionDef::nocli;
def->cli = ConfigOptionDef::nocli;
}
def = this->add("toolchange_gcode", coString);

View file

@ -79,12 +79,14 @@ void PrintRegion::collect_object_printing_extruders(const PrintConfig &print_con
void PrintRegion::collect_object_printing_extruders(std::vector<unsigned int> &object_extruders) const
{
auto num_extruders = (int)print()->config().nozzle_diameter.size();
// PrintRegion, if used by some PrintObject, shall have all the extruders set to an existing printer extruder.
// If not, then there must be something wrong with the Print::apply() function.
#ifndef NDEBUG
auto num_extruders = (int)print()->config().nozzle_diameter.size();
assert(this->config().perimeter_extruder <= num_extruders);
assert(this->config().infill_extruder <= num_extruders);
assert(this->config().solid_infill_extruder <= num_extruders);
#endif
collect_object_printing_extruders(print()->config(), this->config(), object_extruders);
}

View file

@ -185,8 +185,6 @@ private:
SLAAutoSupports::Config m_config;
float m_supports_force_total = 0.f;
void process(const std::vector<ExPolygons>& slices, const std::vector<float>& heights);
void uniformly_cover(const ExPolygons& islands, Structure& structure, PointGrid3D &grid3d, bool is_new_island = false, bool just_one = false);
void project_onto_mesh(std::vector<sla::SupportPoint>& points) const;