SPE-2214 - Fixed detection of toolpaths bounding box in GCodeViewer

This commit is contained in:
enricoturri1966 2024-04-04 15:22:09 +02:00 committed by Lukas Matena
parent 6dcd97356b
commit d81a3c055b

View File

@ -1002,8 +1002,7 @@ void GCodeViewer::load_as_gcode(const GCodeProcessorResult& gcode_result, const
libvgcode::EGCodeExtrusionRole::Skirt, libvgcode::EGCodeExtrusionRole::SupportMaterial, libvgcode::EGCodeExtrusionRole::SupportMaterialInterface,
libvgcode::EGCodeExtrusionRole::WipeTower
});
m_paths_bounding_box.min = libvgcode::convert(bbox[0]).cast<double>();
m_paths_bounding_box.max = libvgcode::convert(bbox[1]).cast<double>();
m_paths_bounding_box = BoundingBoxf3(libvgcode::convert(bbox[0]).cast<double>(), libvgcode::convert(bbox[1]).cast<double>());
if (wxGetApp().is_editor())
m_contained_in_bed = wxGetApp().plater()->build_volume().all_paths_inside(gcode_result, m_paths_bounding_box);