mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-08 07:27:41 -06:00
ENH: [Tree Support] smooth_nodes and draw ellipse works
1. smooth nodes' positions 2. draw ellipse along movement direction 3. fix a bug of radius not smooth 4. fix a bug of Tree Strong having too large radius 5. fix a bug in plan_layer_heights: when wipe tower is enabled, independent_support_layer_height is false, and all support layers should be exactly the same as the object. Jira: STUDIO-1785 6. move support style popup message to on_value_change, so only show the popup when the user changes support type or style. Change-Id: Ibced7a28f436d96000ee35a7194b68bb5a20a32d (cherry picked from commit 0d814b07e433533c8de1b7a04bf52b577de0778d)
This commit is contained in:
parent
629e68f4a0
commit
3e7b5e7657
3 changed files with 75 additions and 61 deletions
|
@ -1416,6 +1416,28 @@ void Tab::on_value_change(const std::string& opt_key, const boost::any& value)
|
|||
}
|
||||
}
|
||||
|
||||
// BBS popup a message to ask the user to set optimum parameters for tree support
|
||||
if (opt_key == "support_type" || opt_key == "support_style") {
|
||||
// BBS
|
||||
if (is_tree_slim(m_config->opt_enum<SupportType>("support_type"), m_config->opt_enum<SupportMaterialStyle>("support_style")) &&
|
||||
!(m_config->opt_float("support_top_z_distance") == 0 && m_config->opt_int("support_interface_top_layers") == 0 && m_config->opt_int("tree_support_wall_count") == 2)) {
|
||||
wxString msg_text = _L("We have added an experimental style \"Tree Slim\" that features smaller support volume but weaker strength.\n"
|
||||
"We recommand using it with: 0 interface layers, 0 top distance, 2 walls.");
|
||||
msg_text += "\n\n" + _L("Change these settings automatically? \n"
|
||||
"Yes - Change these settings automatically\n"
|
||||
"No - Do not change these settings for me");
|
||||
MessageDialog dialog(wxGetApp().plater(), msg_text, "Suggestion", wxICON_WARNING | wxYES | wxNO);
|
||||
DynamicPrintConfig new_conf = *m_config;
|
||||
if (dialog.ShowModal() == wxID_YES) {
|
||||
new_conf.set_key_value("support_top_z_distance", new ConfigOptionFloat(0));
|
||||
new_conf.set_key_value("support_interface_top_layers", new ConfigOptionInt(0));
|
||||
new_conf.set_key_value("tree_support_wall_count", new ConfigOptionInt(2));
|
||||
m_config_manipulation.apply(m_config, &new_conf);
|
||||
}
|
||||
wxGetApp().plater()->update();
|
||||
}
|
||||
}
|
||||
|
||||
// BBS
|
||||
#if 0
|
||||
if (opt_key == "extruders_count")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue