mirror of
https://git.mirrors.martin98.com/https://github.com/bambulab/BambuStudio.git
synced 2025-09-21 08:33:11 +08:00
FIX: When the calibration line exceeds the range of the heatbed
Prompt user to modify parameters Jira: 4951 Change-Id: Id856c50fa999c188c403f428e7bfd874ddcca04c
This commit is contained in:
parent
64146d8386
commit
5998bcc747
@ -840,6 +840,16 @@ void CalibUtils::process_and_store_3mf(Model *model, const DynamicPrintConfig &f
|
|||||||
plate_size[1] = bedfs[2].y() - bedfs[0].y();
|
plate_size[1] = bedfs[2].y() - bedfs[0].y();
|
||||||
plate_size[2] = print_height;
|
plate_size[2] = print_height;
|
||||||
|
|
||||||
|
if (params.mode == CalibMode::Calib_PA_Line) {
|
||||||
|
double space_y = 3.5;
|
||||||
|
int max_line_nums = int(plate_size[1] - 10) / space_y;
|
||||||
|
int count = std::llround(std::ceil((params.end - params.start) / params.step));
|
||||||
|
if (count > max_line_nums) {
|
||||||
|
error_message = _L("Unable to calibrate: maybe because the set calibration value range is too large, or the step is too small");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (params.mode == CalibMode::Calib_PA_Pattern) {
|
if (params.mode == CalibMode::Calib_PA_Pattern) {
|
||||||
ModelInstance *instance = model->objects[0]->instances[0];
|
ModelInstance *instance = model->objects[0]->instances[0];
|
||||||
Vec3d offset = model->calib_pa_pattern->get_start_offset() +
|
Vec3d offset = model->calib_pa_pattern->get_start_offset() +
|
||||||
|
Loading…
x
Reference in New Issue
Block a user