mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-16 18:12:10 +00:00
Material Type standarization + Technical Filament Types (#10553)
* New materials * Temps * Full filament type list * Improve nozzle temperature range validation messages Separates minimum and maximum recommended temperature warnings for nozzle configuration + generig °c usage. Co-Authored-By: Alexandre Folle de Menezes <afmenez@gmail.com> * Material Updates Co-Authored-By: Rodrigo <162915171+RF47@users.noreply.github.com> * petg-cf10 should be petg-cf options. * Pla reduced range * Adjust some temps * FilamentTempType Temperature-based logic * chamber temps * Fromatting * Filament chamber temperature range support Introduces get_filament_chamber_temp_range to retrieve safe chamber temperature limits for filament types. Updates ConfigManipulation to use these limits instead of hardcoded values. * add adhesion coefficient and yield strength Replaces hardcoded material checks for adhesion coefficient and yield strength with lookup functions using extended FilamentType struct. * Thermal length * Fix * Refactor filament type data to MaterialType class Moved filament type properties and related lookup functions from PrintConfig.cpp into a new MaterialType class. * Fix adhesion_coefficient Co-Authored-By: SoftFever <softfeverever@gmail.com> --------- Co-authored-by: Alexandre Folle de Menezes <afmenez@gmail.com> Co-authored-by: Rodrigo <162915171+RF47@users.noreply.github.com> Co-authored-by: SoftFever <softfeverever@gmail.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#include "PrintConfig.hpp"
|
||||
#include "ClipperUtils.hpp"
|
||||
#include "Config.hpp"
|
||||
#include "MaterialType.hpp"
|
||||
#include "I18N.hpp"
|
||||
#include "format.hpp"
|
||||
|
||||
@@ -53,6 +54,9 @@ namespace Slic3r {
|
||||
#define L(s) (s)
|
||||
#define _(s) Slic3r::I18N::translate(s)
|
||||
|
||||
// Filament types are defined in MaterialType.
|
||||
|
||||
|
||||
static t_config_enum_names enum_names_from_keys_map(const t_config_enum_values &enum_keys_map)
|
||||
{
|
||||
t_config_enum_names names;
|
||||
@@ -2261,45 +2265,11 @@ void PrintConfigDef::init_fff_params()
|
||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
||||
def->gui_flags = "show_value";
|
||||
|
||||
def->enum_values.push_back("ABS");
|
||||
def->enum_values.push_back("ABS-GF");
|
||||
def->enum_values.push_back("ASA");
|
||||
def->enum_values.push_back("ASA-Aero");
|
||||
def->enum_values.push_back("BVOH");
|
||||
def->enum_values.push_back("PCTG");
|
||||
def->enum_values.push_back("EVA");
|
||||
def->enum_values.push_back("FLEX");
|
||||
def->enum_values.push_back("HIPS");
|
||||
def->enum_values.push_back("PA");
|
||||
def->enum_values.push_back("PA-CF");
|
||||
def->enum_values.push_back("PA-GF");
|
||||
def->enum_values.push_back("PA6-CF");
|
||||
def->enum_values.push_back("PA11-CF");
|
||||
def->enum_values.push_back("PC");
|
||||
def->enum_values.push_back("PC-CF");
|
||||
def->enum_values.push_back("PCTG");
|
||||
def->enum_values.push_back("PE");
|
||||
def->enum_values.push_back("PE-CF");
|
||||
def->enum_values.push_back("PET-CF");
|
||||
def->enum_values.push_back("PETG");
|
||||
def->enum_values.push_back("PETG-CF");
|
||||
def->enum_values.push_back("PETG-CF10");
|
||||
def->enum_values.push_back("PETG-GF");
|
||||
def->enum_values.push_back("PHA");
|
||||
def->enum_values.push_back("PLA");
|
||||
def->enum_values.push_back("PLA-AERO");
|
||||
def->enum_values.push_back("PLA-CF");
|
||||
def->enum_values.push_back("PP");
|
||||
def->enum_values.push_back("PP-CF");
|
||||
def->enum_values.push_back("PP-GF");
|
||||
def->enum_values.push_back("PPA-CF");
|
||||
def->enum_values.push_back("PPA-GF");
|
||||
def->enum_values.push_back("PPS");
|
||||
def->enum_values.push_back("PPS-CF");
|
||||
def->enum_values.push_back("PVA");
|
||||
def->enum_values.push_back("PVB");
|
||||
def->enum_values.push_back("SBS");
|
||||
def->enum_values.push_back("TPU");
|
||||
// Populate the enum values using the shared material type database
|
||||
for (const auto& filament : MaterialType::all()) {
|
||||
def->enum_values.push_back(filament.name);
|
||||
}
|
||||
|
||||
def->mode = comSimple;
|
||||
def->set_default_value(new ConfigOptionStrings { "PLA" });
|
||||
|
||||
|
||||
Reference in New Issue
Block a user