mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-10-11 18:01:14 +00:00
Merge upstream/main into iXex PR branch (#13086)
Catches the iXex/IDEX parallel-printing branch up to upstream main (102 commits). Two content conflicts resolved: - src/libslic3r/Preset.cpp: s_Preset_printer_options — kept upstream's new "use_3mf" key and our iMEX printer-capability/mode keys. - tests/fff_print/test_gcodewriter.cpp: upstream revived the disabled suite (#14196), dropping the obsolete [.]-tagged lift() test and its config_lift_unlift.ini; kept their set_speed + z_hop tests and appended our 10 per-firmware set_pressure_advance/set_temperature scenarios. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -177,7 +177,8 @@ void PartPlate::init()
|
||||
m_locked = false;
|
||||
m_ready_for_slice = true;
|
||||
m_slice_result_valid = false;
|
||||
m_slice_percent = 0.0f;
|
||||
m_slice_percent = -1.0f; // ORCA create new plates with negative values or it will take "slicing" role on toolbar
|
||||
// condition for sliced / slicing -- if (plate_list.get_plate(i)->get_slicing_percent() < 0.0f)
|
||||
m_hover_id = -1;
|
||||
m_selected = false;
|
||||
//m_quadric = ::gluNewQuadric();
|
||||
@@ -3048,11 +3049,20 @@ bool PartPlate::check_filament_printable(const DynamicPrintConfig &config, wxStr
|
||||
|
||||
std::vector<int> used_filaments = get_extruders(true); // 1 base
|
||||
if (!used_filaments.empty()) {
|
||||
const std::vector<std::string>& filament_types = config.option<ConfigOptionStrings>("filament_type")->values;
|
||||
const std::vector<int>& filament_printables = config.option<ConfigOptionInts>("filament_printable")->values;
|
||||
const std::vector<int>& filament_map = get_real_filament_maps(config);
|
||||
// This runs synchronously mid printer-switch (load_current_preset -> reload_scene), before the
|
||||
// filament-count reconciliation clears stale per-object assignments, so the plate objects can
|
||||
// still reference filament indices beyond the freshly selected printer config. Skip those to
|
||||
// avoid an out-of-range access. Matches BambuStudio's guards in the same function.
|
||||
const int filament_count = std::min({(int) filament_types.size(), (int) filament_printables.size(), (int) filament_map.size()});
|
||||
for (auto filament_idx : used_filaments) {
|
||||
int filament_id = filament_idx - 1;
|
||||
std::string filament_type = config.option<ConfigOptionStrings>("filament_type")->values.at(filament_id);
|
||||
int filament_printable_status = config.option<ConfigOptionInts>("filament_printable")->values.at(filament_id);
|
||||
std::vector<int> filament_map = get_real_filament_maps(config);
|
||||
if (filament_id < 0 || filament_id >= filament_count)
|
||||
continue;
|
||||
std::string filament_type = filament_types[filament_id];
|
||||
int filament_printable_status = filament_printables[filament_id];
|
||||
int extruder_idx = filament_map[filament_id] - 1;
|
||||
if (!(filament_printable_status >> extruder_idx & 1)) {
|
||||
wxString extruder_name = extruder_idx == 0 ? _L("left") : _L("right");
|
||||
|
||||
Reference in New Issue
Block a user