Merge branch 'master' of https://github.com/prusa3d/PrusaSlicer into et_print_volume_fit
This commit is contained in:
commit
5ddfe8dab2
4 changed files with 13 additions and 8 deletions
|
@ -174,7 +174,7 @@ bool Bed3D::set_shape(const Pointfs& bed_shape, const double max_print_height, c
|
|||
}
|
||||
|
||||
|
||||
if (m_build_volume.bed_shape() == bed_shape && m_type == type && m_texture_filename == texture_filename && m_model_filename == model_filename)
|
||||
if (m_build_volume.bed_shape() == bed_shape && m_build_volume.max_print_height() == max_print_height && m_type == type && m_texture_filename == texture_filename && m_model_filename == model_filename)
|
||||
// No change, no need to update the UI.
|
||||
return false;
|
||||
|
||||
|
|
|
@ -3751,7 +3751,8 @@ Linef3 GLCanvas3D::mouse_ray(const Point& mouse_pos)
|
|||
|
||||
double GLCanvas3D::get_size_proportional_to_max_bed_size(double factor) const
|
||||
{
|
||||
return factor * m_bed.build_volume().bounding_volume().max_size();
|
||||
const BoundingBoxf& bbox = m_bed.build_volume().bounding_volume2d();
|
||||
return factor * std::max(bbox.size()[0], bbox.size()[1]);
|
||||
}
|
||||
|
||||
void GLCanvas3D::set_cursor(ECursorType type)
|
||||
|
@ -5119,10 +5120,12 @@ void GLCanvas3D::_render_objects(GLVolumeCollection::ERenderType type)
|
|||
break;
|
||||
}
|
||||
default:
|
||||
case BuildVolume::Type::Convex:
|
||||
case BuildVolume::Type::Custom: {
|
||||
m_volumes.set_print_volume({ static_cast<int>(type),
|
||||
{ 0.0f, 0.0f, 0.0f, 0.0f },
|
||||
{ 0.0f, 0.0f } });
|
||||
{ -FLT_MAX, -FLT_MAX, FLT_MAX, FLT_MAX },
|
||||
{ -FLT_MAX, FLT_MAX } }
|
||||
);
|
||||
}
|
||||
}
|
||||
if (m_requires_check_outside_state) {
|
||||
|
|
|
@ -468,9 +468,9 @@ void Mouse3DController::render_settings_dialog(GLCanvas3D& canvas) const
|
|||
ImGui::Separator();
|
||||
imgui.text_colored(color, _L("Speed:"));
|
||||
|
||||
float translation_scale = (float)params_copy.translation.scale / Params::DefaultTranslationScale;
|
||||
if (imgui.slider_float(_L("Translation"), &translation_scale, Params::MinTranslationScale, Params::MaxTranslationScale, "%.1f")) {
|
||||
params_copy.translation.scale = Params::DefaultTranslationScale * (double)translation_scale;
|
||||
float translation_scale = float(params_copy.translation.scale) / float(Params::DefaultTranslationScale);
|
||||
if (imgui.slider_float(_L("Translation"), &translation_scale, float(Params::MinTranslationScale), float(Params::MaxTranslationScale), "%.1f")) {
|
||||
params_copy.translation.scale = Params::DefaultTranslationScale * double(translation_scale);
|
||||
params_changed = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -6299,8 +6299,10 @@ void Plater::on_config_change(const DynamicPrintConfig &config)
|
|||
update_scheduled = true;
|
||||
p->sidebar->obj_list()->update_extruder_colors();
|
||||
}
|
||||
else if(opt_key == "max_print_height")
|
||||
else if (opt_key == "max_print_height") {
|
||||
bed_shape_changed = true;
|
||||
update_scheduled = true;
|
||||
}
|
||||
else if (opt_key == "printer_model") {
|
||||
p->reset_gcode_toolpaths();
|
||||
// update to force bed selection(for texturing)
|
||||
|
|
Loading…
Reference in a new issue