From 003647e898cfe5ba49b712a6fd17e7fd858337ac Mon Sep 17 00:00:00 2001
From: tamasmeszaros <meszaros.q@gmail.com>
Date: Mon, 28 Nov 2022 10:48:18 +0100
Subject: [PATCH] Prepare UI for organic supports option

---
 src/libslic3r/PrintConfig.cpp               | 4 +++-
 src/libslic3r/SLA/SupportTree.cpp           | 3 +++
 src/libslic3r/SLA/SupportTreeStrategies.hpp | 2 +-
 3 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/src/libslic3r/PrintConfig.cpp b/src/libslic3r/PrintConfig.cpp
index 482e36e43..ebdfd2ff6 100644
--- a/src/libslic3r/PrintConfig.cpp
+++ b/src/libslic3r/PrintConfig.cpp
@@ -181,7 +181,8 @@ CONFIG_OPTION_ENUM_DEFINE_STATIC_MAPS(SLAMaterialSpeed);
 
 static inline const t_config_enum_values s_keys_map_SLASupportTreeType = {
     {"default", int(sla::SupportTreeType::Default)},
-    {"branching",   int(sla::SupportTreeType::Branching)}
+    {"branching",   int(sla::SupportTreeType::Branching)},
+    //TODO: {"organic", int(sla::SupportTreeType::Organic)}
 };
 CONFIG_OPTION_ENUM_DEFINE_STATIC_MAPS(SLASupportTreeType);
 
@@ -3614,6 +3615,7 @@ void PrintConfigDef::init_sla_params()
     def->enum_labels = ConfigOptionEnum<sla::SupportTreeType>::get_enum_names();
     def->enum_labels[0] = L("Default");
     def->enum_labels[1] = L("Branching");
+    // TODO: def->enum_labels[2] = L("Organic");
     def->mode = comAdvanced;
     def->set_default_value(new ConfigOptionEnum(sla::SupportTreeType::Default));
 
diff --git a/src/libslic3r/SLA/SupportTree.cpp b/src/libslic3r/SLA/SupportTree.cpp
index b221c4330..37c2e85e9 100644
--- a/src/libslic3r/SLA/SupportTree.cpp
+++ b/src/libslic3r/SLA/SupportTree.cpp
@@ -39,6 +39,9 @@ indexed_triangle_set create_support_tree(const SupportableMesh &sm,
             create_branching_tree(*builder, sm);
             break;
         }
+        case SupportTreeType::Organic: {
+            // TODO
+        }
         default:;
         }
 
diff --git a/src/libslic3r/SLA/SupportTreeStrategies.hpp b/src/libslic3r/SLA/SupportTreeStrategies.hpp
index 487f43575..2cef1a8a9 100644
--- a/src/libslic3r/SLA/SupportTreeStrategies.hpp
+++ b/src/libslic3r/SLA/SupportTreeStrategies.hpp
@@ -5,7 +5,7 @@
 
 namespace Slic3r { namespace sla {
 
-enum class SupportTreeType { Default, Branching };
+enum class SupportTreeType { Default, Branching, Organic };
 enum class PillarConnectionMode { zigzag, cross, dynamic };
 
 }} // namespace Slic3r::sla