mirror of
https://git.mirrors.martin98.com/https://github.com/slic3r/Slic3r.git
synced 2025-08-14 04:45:57 +08:00
Fix requesting z_offset from sla printer
This commit is contained in:
parent
98702a0060
commit
7106a76287
@ -741,11 +741,14 @@ void Preview::update_layers_slider(const std::vector<double>& layers_z, bool kee
|
||||
|
||||
Plater* plater = wxGetApp().plater();
|
||||
CustomGCode::Info ticks_info_from_model = plater->model().custom_gcode_per_print_z;
|
||||
//add z-shift from gcode output
|
||||
const float z_shift = wxGetApp().preset_bundle->printers.get_edited_preset().config.opt_float("z_offset");
|
||||
if (can_display_gcode() && z_shift != 0) {
|
||||
for (CustomGCode::Item& tick : ticks_info_from_model.gcodes) {
|
||||
tick.print_z += z_shift;
|
||||
if (wxGetApp().preset_bundle && wxGetApp().preset_bundle->printers.get_edited_preset().config.option("z_offset"))
|
||||
{
|
||||
//add z-shift from gcode output
|
||||
const float z_shift = wxGetApp().preset_bundle->printers.get_edited_preset().config.opt_float("z_offset");
|
||||
if (can_display_gcode() && z_shift != 0) {
|
||||
for (CustomGCode::Item& tick : ticks_info_from_model.gcodes) {
|
||||
tick.print_z += z_shift;
|
||||
}
|
||||
}
|
||||
}
|
||||
//check incoherencies
|
||||
|
Loading…
x
Reference in New Issue
Block a user