mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 01:45:54 +08:00
Move objects_info to the beginning of the statistics block in ASCII gcode
This commit is contained in:
parent
cd2ad7f52a
commit
a5affeb98e
@ -1422,8 +1422,10 @@ void GCodeGenerator::_do_export(Print& print, GCodeOutputStream &file, Thumbnail
|
|||||||
m_processor.get_binary_data()
|
m_processor.get_binary_data()
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!export_to_binary_gcode)
|
if (!export_to_binary_gcode) {
|
||||||
|
file.write_format("; objects_info = %s\n", m_label_objects.all_objects_header_singleline_json().c_str());
|
||||||
file.write(filament_stats_string_out);
|
file.write(filament_stats_string_out);
|
||||||
|
}
|
||||||
|
|
||||||
if (export_to_binary_gcode) {
|
if (export_to_binary_gcode) {
|
||||||
bgcode::binarize::BinaryData& binary_data = m_processor.get_binary_data();
|
bgcode::binarize::BinaryData& binary_data = m_processor.get_binary_data();
|
||||||
@ -1446,8 +1448,6 @@ void GCodeGenerator::_do_export(Print& print, GCodeOutputStream &file, Thumbnail
|
|||||||
file.write_format("; total toolchanges = %i\n", print.m_print_statistics.total_toolchanges);
|
file.write_format("; total toolchanges = %i\n", print.m_print_statistics.total_toolchanges);
|
||||||
file.write_format(";%s\n", GCodeProcessor::reserved_tag(GCodeProcessor::ETags::Estimated_Printing_Time_Placeholder).c_str());
|
file.write_format(";%s\n", GCodeProcessor::reserved_tag(GCodeProcessor::ETags::Estimated_Printing_Time_Placeholder).c_str());
|
||||||
|
|
||||||
file.write_format("; objects_info = %s\n", m_label_objects.all_objects_header_singleline_json().c_str());
|
|
||||||
|
|
||||||
// if exporting gcode in ascii format, config export is done here
|
// if exporting gcode in ascii format, config export is done here
|
||||||
// Append full config, delimited by two 'phony' configuration keys prusaslicer_config = begin and prusaslicer_config = end.
|
// Append full config, delimited by two 'phony' configuration keys prusaslicer_config = begin and prusaslicer_config = end.
|
||||||
// The delimiters are structured as configuration key / value pairs to be parsable by older versions of PrusaSlicer G-code viewer.
|
// The delimiters are structured as configuration key / value pairs to be parsable by older versions of PrusaSlicer G-code viewer.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user