update to latest version

This commit is contained in:
QIDI TECH
2023-06-27 11:07:34 +08:00
parent afe5c54367
commit dd0d4c8c4a
80 changed files with 1931 additions and 599 deletions

View File

@@ -312,7 +312,7 @@ namespace Slic3r {
std::string gcode_out;
std::string line;
Vec2f pos = tcr.start_pos;
Vec2f transformed_pos = pos;
Vec2f transformed_pos = Eigen::Rotation2Df(angle) * pos + translation;
Vec2f old_pos(-1000.1f, -1000.1f);
while (gcode_str) {
@@ -901,6 +901,7 @@ namespace DoExport {
silent_time_estimator_enabled = (config.gcode_flavor == gcfMarlinLegacy || config.gcode_flavor == gcfMarlinFirmware)
&& config.silent_mode;
processor.reset();
processor.initialize_result_moves();
processor.apply_config(config);
processor.enable_stealth_time_estimator(silent_time_estimator_enabled);
}
@@ -1296,8 +1297,12 @@ void GCode::_do_export(Print& print, GCodeOutputStream &file, ThumbnailsGenerato
this->placeholder_parser().set("first_layer_print_min", new ConfigOptionFloats({ bbox.min.x(), bbox.min.y() }));
this->placeholder_parser().set("first_layer_print_max", new ConfigOptionFloats({ bbox.max.x(), bbox.max.y() }));
this->placeholder_parser().set("first_layer_print_size", new ConfigOptionFloats({ bbox.size().x(), bbox.size().y() }));
std::vector<unsigned char> is_extruder_used(print.config().nozzle_diameter.size(), 0);
this->placeholder_parser().set("num_extruders", int(print.config().nozzle_diameter.values.size()));
// PlaceholderParser currently substitues non-existent vector values with the zero'th value, which is harmful in the case of "is_extruder_used[]"
// as Slicer may lie about availability of such non-existent extruder.
// We rather sacrifice 256B of memory before we change the behavior of the PlaceholderParser, which should really only fill in the non-existent
// vector elements for filament parameters.
std::vector<unsigned char> is_extruder_used(std::max(size_t(255), print.config().nozzle_diameter.size()), 0);
for (unsigned int extruder_id : tool_ordering.all_extruders())
is_extruder_used[extruder_id] = true;
this->placeholder_parser().set("is_extruder_used", new ConfigOptionBools(is_extruder_used));
@@ -2510,7 +2515,7 @@ void GCode::process_layer_single_object(
int extruder_override_id = is_anything_overridden ? layer_tools.wiping_extrusions().get_extruder_override(eec, instance_id) : -1;
return print_wipe_extrusions ?
extruder_override_id == int(extruder_id) :
extruder_override_id < 0 && extruder_id == correct_extruder_id;
extruder_override_id < 0 && int(extruder_id) == correct_extruder_id;
};
ExtrusionEntitiesPtr temp_fill_extrusions;