NEW:add statistics of all plates in preview

Change-Id: Ia93ca5a31d07ae5d52a37bb7b6fb0e3b26cfd012
This commit is contained in:
liz.li authored and Lane.Wei committed 2023-02-22 20:09:17 +08:00
1 parent b731ac8db8
commit 6114a415cf
11 files changed
+466 -33

No files matched your search

+19
View File
@@ -3105,6 +3105,25 @@ PartPlate* PartPlateList::get_selected_plate()
return m_plate_list[m_current_plate];
}
std::vector<PartPlate*> PartPlateList::get_nonempty_plate_list()
{
std::vector<PartPlate*> nonempty_plate_list;
for (auto plate : m_plate_list){
if (plate->get_extruders().size() != 0) {
nonempty_plate_list.push_back(plate);
}
}
return nonempty_plate_list;
}
std::vector<const GCodeProcessorResult*> PartPlateList::get_nonempty_plates_slice_results() {
std::vector<const GCodeProcessorResult*> nonempty_plates_slice_result;
for (auto plate : get_nonempty_plate_list()) {
nonempty_plates_slice_result.push_back(plate->get_slice_result());
}
return nonempty_plates_slice_result;
}
//select plate
int PartPlateList::select_plate(int index)
{