mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-29 11:51:24 +00:00
fix: expose initial_no_support_extruder to the filename format template
This commit is contained in:
@@ -4198,6 +4198,7 @@ void GCode::_do_export(Print& print, GCodeOutputStream &file, ThumbnailsGenerato
|
|||||||
// Const input (tool-change fallback for non-wipe-tower prints)
|
// Const input (tool-change fallback for non-wipe-tower prints)
|
||||||
print.tool_ordering()));
|
print.tool_ordering()));
|
||||||
print.m_print_statistics.initial_tool = initial_extruder_id;
|
print.m_print_statistics.initial_tool = initial_extruder_id;
|
||||||
|
print.m_print_statistics.initial_no_support_tool = initial_non_support_extruder_id;
|
||||||
if (!is_bbl_printers) {
|
if (!is_bbl_printers) {
|
||||||
file.write_format("; total filament used [g] = %.2lf\n",
|
file.write_format("; total filament used [g] = %.2lf\n",
|
||||||
print.m_print_statistics.total_weight);
|
print.m_print_statistics.total_weight);
|
||||||
|
|||||||
@@ -5049,6 +5049,7 @@ DynamicConfig PrintStatistics::config() const
|
|||||||
config.set_key_value("total_wipe_tower_filament", new ConfigOptionFloat(this->total_wipe_tower_filament));
|
config.set_key_value("total_wipe_tower_filament", new ConfigOptionFloat(this->total_wipe_tower_filament));
|
||||||
config.set_key_value("initial_tool", new ConfigOptionInt(static_cast<int>(this->initial_tool)));
|
config.set_key_value("initial_tool", new ConfigOptionInt(static_cast<int>(this->initial_tool)));
|
||||||
config.set_key_value("initial_extruder", new ConfigOptionInt(static_cast<int>(this->initial_tool)));
|
config.set_key_value("initial_extruder", new ConfigOptionInt(static_cast<int>(this->initial_tool)));
|
||||||
|
config.set_key_value("initial_no_support_extruder", new ConfigOptionInt(static_cast<int>(this->initial_no_support_tool)));
|
||||||
return config;
|
return config;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -5058,7 +5059,7 @@ DynamicConfig PrintStatistics::placeholders()
|
|||||||
for (const std::string key : {
|
for (const std::string key : {
|
||||||
"print_time", "normal_print_time", "silent_print_time",
|
"print_time", "normal_print_time", "silent_print_time",
|
||||||
"used_filament", "extruded_volume", "extruded_volume_total", "total_cost", "total_weight", "extruded_weight_total",
|
"used_filament", "extruded_volume", "extruded_volume_total", "total_cost", "total_weight", "extruded_weight_total",
|
||||||
"initial_tool", "initial_extruder", "total_toolchanges", "total_wipe_tower_cost", "total_wipe_tower_filament"})
|
"initial_tool", "initial_extruder", "initial_no_support_extruder", "total_toolchanges", "total_wipe_tower_cost", "total_wipe_tower_filament"})
|
||||||
config.set_key_value(key, new ConfigOptionString(std::string("{") + key + "}"));
|
config.set_key_value(key, new ConfigOptionString(std::string("{") + key + "}"));
|
||||||
return config;
|
return config;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -830,6 +830,7 @@ struct PrintStatistics
|
|||||||
double total_wipe_tower_cost;
|
double total_wipe_tower_cost;
|
||||||
double total_wipe_tower_filament;
|
double total_wipe_tower_filament;
|
||||||
unsigned int initial_tool;
|
unsigned int initial_tool;
|
||||||
|
unsigned int initial_no_support_tool;
|
||||||
std::map<size_t, double> filament_stats;
|
std::map<size_t, double> filament_stats;
|
||||||
|
|
||||||
// Config with the filled in print statistics.
|
// Config with the filled in print statistics.
|
||||||
@@ -848,6 +849,7 @@ struct PrintStatistics
|
|||||||
total_wipe_tower_cost = 0.;
|
total_wipe_tower_cost = 0.;
|
||||||
total_wipe_tower_filament = 0.;
|
total_wipe_tower_filament = 0.;
|
||||||
initial_tool = 0;
|
initial_tool = 0;
|
||||||
|
initial_no_support_tool = 0;
|
||||||
filament_stats.clear();
|
filament_stats.clear();
|
||||||
}
|
}
|
||||||
static const std::string FilamentUsedG;
|
static const std::string FilamentUsedG;
|
||||||
|
|||||||
Reference in New Issue
Block a user