mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-07-24 03:12:07 +00:00
BBS Port: Mesh Subdivision (#12150)
Ported from BBS You can now right-click a part and choose Subdivide Part to apply Loop subdivision with multiple iterations. This is useful for models with low original mesh resolution. > [!NOTE] > 1. Only meshes without non-manifold edges are supported. > 2. Color attributes will be lost after subdivision. We recommend subdividing first, then painting and applying colors. Not perfect and it can break some features but a nice to have and we can improve it. https://github.com/user-attachments/assets/33f10e49-f6dc-44d3-8c21-9e12e1fe23dc Best case scenario a sphere: Each picture is a Mesh subdivision step over the other <img width="541" height="495" alt="260202_164257_orca-slicer" src="https://github.com/user-attachments/assets/e62b3f4d-ee6b-4451-95a4-40a154d3a405" /> <img width="541" height="495" alt="260202_164302_%pn" src="https://github.com/user-attachments/assets/f7399457-be8d-45e7-b93f-f42064dadd64" /> <img width="541" height="495" alt="260202_164306_%pn" src="https://github.com/user-attachments/assets/55370035-219f-4b7f-94f4-9b31733820d6" /> <img width="541" height="495" alt="260202_164310_%pn" src="https://github.com/user-attachments/assets/3be8c904-cc6f-4efe-b4f8-f390b50d310c" />
This commit is contained in:
@@ -1349,6 +1349,8 @@ void MenuFactory::create_extra_object_menu()
|
||||
append_menu_item_fix_through_netfabb(&m_object_menu);
|
||||
// Object Simplify
|
||||
append_menu_item_simplify(&m_object_menu);
|
||||
// Object Mesh Subdivision
|
||||
append_menu_item_smooth_mesh(&m_object_menu);
|
||||
// merge to single part
|
||||
append_menu_item_merge_parts_to_single_part(&m_object_menu);
|
||||
// Object Center
|
||||
@@ -1400,6 +1402,8 @@ void MenuFactory::create_bbl_assemble_object_menu()
|
||||
append_menu_item_fix_through_netfabb(&m_assemble_object_menu);
|
||||
// Object Simplify
|
||||
append_menu_item_simplify(&m_assemble_object_menu);
|
||||
// Object Mesh Subdivision
|
||||
append_menu_item_smooth_mesh(&m_assemble_object_menu);
|
||||
m_assemble_object_menu.AppendSeparator();
|
||||
}
|
||||
|
||||
@@ -1483,6 +1487,7 @@ void MenuFactory::create_bbl_part_menu()
|
||||
append_menu_item_edit_text(menu);
|
||||
append_menu_item_fix_through_netfabb(menu);
|
||||
append_menu_item_simplify(menu);
|
||||
append_menu_item_smooth_mesh(menu);
|
||||
append_menu_item_center(menu);
|
||||
append_menu_item_drop(menu);
|
||||
append_menu_items_mirror(menu);
|
||||
@@ -1514,6 +1519,7 @@ void MenuFactory::create_bbl_assemble_part_menu()
|
||||
|
||||
append_menu_item_delete(menu);
|
||||
append_menu_item_simplify(menu);
|
||||
append_menu_item_smooth_mesh(menu);
|
||||
menu->AppendSeparator();
|
||||
}
|
||||
|
||||
@@ -1949,6 +1955,13 @@ void MenuFactory::append_menu_item_simplify(wxMenu* menu)
|
||||
[]() {return plater()->can_simplify(); }, m_parent);
|
||||
}
|
||||
|
||||
void MenuFactory::append_menu_item_smooth_mesh(wxMenu *menu)
|
||||
{
|
||||
wxMenuItem *menu_item = append_menu_item(
|
||||
menu, wxID_ANY, _L("Subdivision mesh") + _L("(Lost color)"), "", [](wxCommandEvent &) { obj_list()->smooth_mesh(); }, "", menu, []() { return plater()->can_smooth_mesh(); },
|
||||
m_parent);
|
||||
}
|
||||
|
||||
void MenuFactory::append_menu_item_center(wxMenu* menu)
|
||||
{
|
||||
append_menu_item(menu, wxID_ANY, _L("Center") , "",
|
||||
|
||||
Reference in New Issue
Block a user