Merge remote-tracking branch 'remotes/origin/master' into vb_ensurovani
@ -237,14 +237,14 @@ documentation_link = https://help.prusa3d.com/article/prusaslicer-printables-com
|
|||||||
weight = 3
|
weight = 3
|
||||||
|
|
||||||
[hint:Cut tool]
|
[hint:Cut tool]
|
||||||
text = Cut tool\nDid you know that you can cut a model at any angle and even create aligning pins with the updated Cut tool? Learn more in the documentation.
|
text = Cut tool\nDid you know that you can cut a model at any angle and even create aligning pins with the updated <a>Cut tool</a>? Learn more in the documentation.
|
||||||
documentation_link = https://help.prusa3d.com/article/cut-tool_1779
|
documentation_link = https://help.prusa3d.com/article/cut-tool_1779
|
||||||
hypertext_type = gizmo
|
hypertext_type = gizmo
|
||||||
hypertext_gizmo_item = cut
|
hypertext_gizmo_item = cut
|
||||||
weight = 3
|
weight = 3
|
||||||
|
|
||||||
[hint:Measurement tool]
|
[hint:Measurement tool]
|
||||||
text = Measurement tool\nDid you know that you can measure the distances between points, edges and planes, the radius of a hole or the angle between edges or planes? Learn more in the documentation.
|
text = Measurement tool\nDid you know that you can <a>measure</a> the distances between points, edges and planes, the radius of a hole or the angle between edges or planes? Learn more in the documentation.
|
||||||
documentation_link = https://help.prusa3d.com/article/measurement-tool_399451
|
documentation_link = https://help.prusa3d.com/article/measurement-tool_399451
|
||||||
hypertext_type = gizmo
|
hypertext_type = gizmo
|
||||||
hypertext_gizmo_item = measure
|
hypertext_gizmo_item = measure
|
||||||
|
15
resources/icons/dowel.svg
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 27.2.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||||
|
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||||
|
width="16px" height="16px" viewBox="0 0 16 16" style="enable-background:new 0 0 16 16;" xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<path fill = "#ED6B21" d="M9,12H7c-0.5522847,0-1-0.4477148-1-1V5c0-0.5522847,0.4477153-1,1-1h2c0.5522852,0,1,0.4477153,1,1v6
|
||||||
|
C10,11.5522852,9.5522852,12,9,12z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path fill="none" stroke="#808080" stroke-linecap="round" stroke-miterlimit="10" d="M1.5,6.5h2v-3c0-1.1045694,0.8954306-2,2-2h5c1.1045694,0,2,0.8954306,2,2v3h2"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path fill="none" stroke="#808080" stroke-linecap="round" stroke-miterlimit="10" d="M1.5,9.5h2v3c0,1.1045694,0.8954306,2,2,2h5c1.1045694,0,2-0.8954306,2-2v-3h2"/>
|
||||||
|
</g>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 899 B |
13
resources/icons/plug.svg
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!-- Generator: Adobe Illustrator 27.2.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
||||||
|
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
||||||
|
width="16px" height="16px" viewBox="0 0 16 16" style="enable-background:new 0 0 16 16;" xml:space="preserve">
|
||||||
|
<g>
|
||||||
|
<path fill="#ED6B21" d="M9,15H7c-0.5522847,0-1-0.4477148-1-1V5c0-0.5522847,0.4477153-1,1-1h2c0.5522852,0,1,0.4477153,1,1v9
|
||||||
|
C10,14.5522852,9.5522852,15,9,15z"/>
|
||||||
|
</g>
|
||||||
|
<g>
|
||||||
|
<path fill="none" stroke="#808080" stroke-linecap="round" stroke-miterlimit="10" d="M1.5,11.5h2v-8c0-1.1045694,0.8954306-2,2-2h5c1.1045694,0,2,0.8954306,2,2v8h2"/>
|
||||||
|
</g>
|
||||||
|
<line fill="none" stroke="#ED6B21" stroke-linecap="round" stroke-miterlimit="10" x1="1.5" y1="14.5" x2="14.5" y2="14.5"/>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 847 B |
@ -2392,7 +2392,7 @@ msgstr "Zálohy konfigurace"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Aktualizace konfigurace způsobí ztrátu změn v přednastaveních.\n"
|
"Aktualizace konfigurace způsobí ztrátu změn v přednastaveních.\n"
|
||||||
|
@ -2392,7 +2392,7 @@ msgstr "Konfigurations-Momentaufnahmen"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Bei einer Konfigurationsaktualisierung gehen voreingestellte Änderungen "
|
"Bei einer Konfigurationsaktualisierung gehen voreingestellte Änderungen "
|
||||||
|
@ -2372,7 +2372,7 @@ msgstr "Instantáneas de la Configuración"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"La actualización de la configuración hace que se pierda la modificación de "
|
"La actualización de la configuración hace que se pierda la modificación de "
|
||||||
|
@ -2399,7 +2399,7 @@ msgstr "Instantanés de Configuration capturés"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Les mises à jour de configuration entraînent une perte de modification des "
|
"Les mises à jour de configuration entraînent une perte de modification des "
|
||||||
|
@ -2379,7 +2379,7 @@ msgstr "Istantanee di Configurazione"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Gli aggiornamenti di configurazione causano la perdita della modifica del "
|
"Gli aggiornamenti di configurazione causano la perdita della modifica del "
|
||||||
|
@ -2338,7 +2338,7 @@ msgstr "設定のスナップショット"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"構成のアップデートをすると、プリセットの変更が失われます。\n"
|
"構成のアップデートをすると、プリセットの変更が失われます。\n"
|
||||||
|
@ -2403,7 +2403,7 @@ msgstr "Zrzuty konfiguracji"
|
|||||||
|
|
||||||
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
#: src/slic3r/Utils/PresetUpdater.cpp:777
|
||||||
msgid ""
|
msgid ""
|
||||||
"Configuration Updates causes a lost of preset modification.\n"
|
"Configuration Updates causes a loss of preset modification.\n"
|
||||||
"So, check unsaved changes and save them if necessary."
|
"So, check unsaved changes and save them if necessary."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Aktualizacja konfiguracji spowoduje utratę zmian w zestawach ustawień.\n"
|
"Aktualizacja konfiguracji spowoduje utratę zmian w zestawach ustawień.\n"
|
||||||
|
@ -1,4 +1,8 @@
|
|||||||
|
min_slic3r_version = 2.6.0-alpha2
|
||||||
|
0.2.1 Added Eolas Prints filaments.
|
||||||
|
0.2.0 Added Photon Mono X printer.
|
||||||
min_slic3r_version = 2.4.1-rc1
|
min_slic3r_version = 2.4.1-rc1
|
||||||
|
0.1.2 Added VOXELPLA filament profile.
|
||||||
0.1.1 Fixed before layer change g-code for Mega Zero.
|
0.1.1 Fixed before layer change g-code for Mega Zero.
|
||||||
0.1.0 Added Anycubic 4Max Pro 2.0
|
0.1.0 Added Anycubic 4Max Pro 2.0
|
||||||
min_slic3r_version = 2.3.2-alpha0
|
min_slic3r_version = 2.3.2-alpha0
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
name = Anycubic
|
name = Anycubic
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 0.1.1
|
config_version = 0.2.1
|
||||||
# Where to get the updates from?
|
# Where to get the updates from?
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Anycubic/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Anycubic/
|
||||||
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
||||||
@ -738,6 +738,17 @@ first_layer_temperature = 245
|
|||||||
filament_cost = 24.99
|
filament_cost = 24.99
|
||||||
filament_density = 1.27
|
filament_density = 1.27
|
||||||
|
|
||||||
|
[filament:VOXELPLA PLUS @MEGA0]
|
||||||
|
inherits = *PLA_mega0*
|
||||||
|
filament_vendor = VOXELPLA
|
||||||
|
temperature = 200
|
||||||
|
bed_temperature = 55
|
||||||
|
first_layer_temperature = 200
|
||||||
|
first_layer_bed_temperature = 55
|
||||||
|
filament_cost = 16.99
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_colour = #FF4640
|
||||||
|
|
||||||
# Common printer preset
|
# Common printer preset
|
||||||
[printer:*common_mega0*]
|
[printer:*common_mega0*]
|
||||||
printer_technology = FFF
|
printer_technology = FFF
|
||||||
@ -1050,6 +1061,68 @@ max_fan_speed = 50
|
|||||||
min_fan_speed = 30
|
min_fan_speed = 30
|
||||||
temperature = 240
|
temperature = 240
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA @MEGA]
|
||||||
|
inherits = *PLA_mega*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 23.50
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
first_layer_bed_temperature = 65
|
||||||
|
first_layer_temperature = 212
|
||||||
|
temperature = 208
|
||||||
|
bed_temperature = 60
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA Matte @MEGA]
|
||||||
|
inherits = Eolas Prints PLA @MEGA
|
||||||
|
filament_cost = 25.50
|
||||||
|
filament_max_volumetric_speed = 14
|
||||||
|
temperature = 212
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 850 @MEGA]
|
||||||
|
inherits = Eolas Prints PLA @MEGA
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 870 @MEGA]
|
||||||
|
inherits = Eolas Prints PLA @MEGA
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 215
|
||||||
|
first_layer_bed_temperature = 68
|
||||||
|
first_layer_temperature = 220
|
||||||
|
bed_temperature = 65
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG @MEGA]
|
||||||
|
inherits = *PETG_mega*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 29.90
|
||||||
|
filament_density = 1.27
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
temperature = 240
|
||||||
|
first_layer_bed_temperature = 85
|
||||||
|
first_layer_temperature = 235
|
||||||
|
bed_temperature = 90
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG - UV Resistant @MEGA]
|
||||||
|
inherits = Eolas Prints PETG @MEGA
|
||||||
|
filament_cost = 35.90
|
||||||
|
temperature = 242
|
||||||
|
first_layer_temperature = 237
|
||||||
|
|
||||||
|
[filament:Eolas Prints TPU 93A @MEGA]
|
||||||
|
inherits = *FLEX_mega*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 34.99
|
||||||
|
filament_density = 1.21
|
||||||
|
filament_colour = #4D9398
|
||||||
|
filament_max_volumetric_speed = 1.2
|
||||||
|
temperature = 235
|
||||||
|
first_layer_bed_temperature = 30
|
||||||
|
bed_temperature = 30
|
||||||
|
filament_retract_length = 0
|
||||||
|
extrusion_multiplier = 1.16
|
||||||
|
|
||||||
[filament:Generic PETG @MEGA]
|
[filament:Generic PETG @MEGA]
|
||||||
inherits = *PETG_mega*
|
inherits = *PETG_mega*
|
||||||
|
|
||||||
@ -1177,6 +1250,17 @@ inherits = *PLA_mega*
|
|||||||
filament_vendor = Verbatim
|
filament_vendor = Verbatim
|
||||||
filament_cost = 23.88
|
filament_cost = 23.88
|
||||||
|
|
||||||
|
[filament:VOXELPLA PLUS @MEGA]
|
||||||
|
inherits = *PLA_mega*
|
||||||
|
filament_vendor = VOXELPLA
|
||||||
|
temperature = 200
|
||||||
|
bed_temperature = 55
|
||||||
|
first_layer_temperature = 200
|
||||||
|
first_layer_bed_temperature = 55
|
||||||
|
filament_cost = 16.99
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_colour = #FF4640
|
||||||
|
|
||||||
[printer:*common_mega*]
|
[printer:*common_mega*]
|
||||||
printer_technology = FFF
|
printer_technology = FFF
|
||||||
bed_shape = 0x0,210x0,210x210,0x210
|
bed_shape = 0x0,210x0,210x210,0x210
|
||||||
@ -2240,7 +2324,7 @@ variable_layer_height = 1
|
|||||||
wipe = 0
|
wipe = 0
|
||||||
z_offset = 0
|
z_offset = 0
|
||||||
|
|
||||||
########## SLA printer presets ##########
|
## SLA printers
|
||||||
|
|
||||||
[sla_print:*common print ANYCUBIC SLA*]
|
[sla_print:*common print ANYCUBIC SLA*]
|
||||||
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
||||||
@ -2275,7 +2359,7 @@ support_small_pillar_diameter_percent = 60%
|
|||||||
inherits = *common print ANYCUBIC SLA*
|
inherits = *common print ANYCUBIC SLA*
|
||||||
layer_height = 0.05
|
layer_height = 0.05
|
||||||
|
|
||||||
########### Materials
|
## SLA materials
|
||||||
|
|
||||||
[sla_material:*common ANYCUBIC SLA*]
|
[sla_material:*common ANYCUBIC SLA*]
|
||||||
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
||||||
@ -2298,7 +2382,7 @@ material_vendor = Generic
|
|||||||
material_colour = #6080EC
|
material_colour = #6080EC
|
||||||
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
compatible_printers_condition = printer_notes=~/.*PHOTONMONOX.*/
|
||||||
|
|
||||||
########## Printers
|
## Printers
|
||||||
|
|
||||||
[printer:Anycubic Photon Mono X]
|
[printer:Anycubic Photon Mono X]
|
||||||
printer_technology = SLA
|
printer_technology = SLA
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
min_slic3r_version = 2.4.1-alpha0
|
min_slic3r_version = 2.4.1-alpha0
|
||||||
|
0.0.7 Added Eolas Prints filaments.
|
||||||
|
0.0.6 Reduced retract_length for direct extruders
|
||||||
0.0.5 Added Artillery Hornet
|
0.0.5 Added Artillery Hornet
|
||||||
min_slic3r_version = 2.3.1-beta
|
min_slic3r_version = 2.3.1-beta
|
||||||
0.0.4 Fixed first layer height in 0.28mm profile.
|
0.0.4 Fixed first layer height in 0.28mm profile.
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
name = Artillery
|
name = Artillery
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 0.0.5
|
config_version = 0.0.7
|
||||||
# Where to get the updates from?
|
# Where to get the updates from?
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Artillery/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Artillery/
|
||||||
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
||||||
@ -89,7 +89,7 @@ remaining_times = 0
|
|||||||
retract_before_travel = 1
|
retract_before_travel = 1
|
||||||
retract_before_wipe = 0%
|
retract_before_wipe = 0%
|
||||||
retract_layer_change = 1
|
retract_layer_change = 1
|
||||||
retract_length = 1.9
|
retract_length = 0.8
|
||||||
retract_length_toolchange = 4
|
retract_length_toolchange = 4
|
||||||
retract_lift = 0.6
|
retract_lift = 0.6
|
||||||
retract_lift_above = 0
|
retract_lift_above = 0
|
||||||
@ -513,3 +513,64 @@ filament_vendor = Generic
|
|||||||
[filament:Generic TPU @Artillery]
|
[filament:Generic TPU @Artillery]
|
||||||
inherits = *TPU*
|
inherits = *TPU*
|
||||||
filament_vendor = Generic
|
filament_vendor = Generic
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA @Artillery]
|
||||||
|
inherits = *PLA*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 23.50
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
first_layer_bed_temperature = 65
|
||||||
|
first_layer_temperature = 208
|
||||||
|
temperature = 202
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA Matte @Artillery]
|
||||||
|
inherits = Eolas Prints PLA @Artillery
|
||||||
|
filament_cost = 25.50
|
||||||
|
filament_max_volumetric_speed = 14
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 850 @Artillery]
|
||||||
|
inherits = Eolas Prints PLA @Artillery
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 870 @Artillery]
|
||||||
|
inherits = Eolas Prints PLA @Artillery
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 215
|
||||||
|
first_layer_bed_temperature = 68
|
||||||
|
first_layer_temperature = 220
|
||||||
|
bed_temperature = 65
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG @Artillery]
|
||||||
|
inherits = *PET*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 29.90
|
||||||
|
filament_density = 1.27
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
temperature = 240
|
||||||
|
first_layer_bed_temperature = 85
|
||||||
|
first_layer_temperature = 235
|
||||||
|
bed_temperature = 90
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG - UV Resistant @Artillery]
|
||||||
|
inherits = Eolas Prints PETG @Artillery
|
||||||
|
filament_cost = 35.90
|
||||||
|
temperature = 242
|
||||||
|
first_layer_temperature = 237
|
||||||
|
|
||||||
|
[filament:Eolas Prints TPU 93A @Artillery]
|
||||||
|
inherits = *TPU*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 34.99
|
||||||
|
filament_density = 1.21
|
||||||
|
filament_colour = #4D9398
|
||||||
|
filament_max_volumetric_speed = 1.2
|
||||||
|
temperature = 230
|
||||||
|
first_layer_bed_temperature = 30
|
||||||
|
bed_temperature = 30
|
||||||
|
filament_retract_length = 0
|
||||||
|
extrusion_multiplier = 1.16
|
@ -1,4 +1,5 @@
|
|||||||
min_slic3r_version = 2.4.1-beta3
|
min_slic3r_version = 2.4.1-beta3
|
||||||
|
0.0.6 Correct start gcode, match profile and firmware settings, and other profile improvements.
|
||||||
0.0.5 Correct Marlin Error accumulation for Ditto printer profiles.
|
0.0.5 Correct Marlin Error accumulation for Ditto printer profiles.
|
||||||
0.0.4 Correct Marlin Error accumulation
|
0.0.4 Correct Marlin Error accumulation
|
||||||
min_slic3r_version = 2.3.0-beta2
|
min_slic3r_version = 2.3.0-beta2
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
name = BIBO
|
name = BIBO
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 0.0.5
|
config_version = 0.0.6
|
||||||
# Where to get the updates from?
|
# Where to get the updates from?
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/BIBO/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/BIBO/
|
||||||
|
|
||||||
@ -37,7 +37,7 @@ clip_multipart_objects = 1
|
|||||||
compatible_printers =
|
compatible_printers =
|
||||||
complete_objects = 0
|
complete_objects = 0
|
||||||
dont_support_bridges = 1
|
dont_support_bridges = 1
|
||||||
elefant_foot_compensation = 0
|
elefant_foot_compensation = 0.3
|
||||||
ensure_vertical_shell_thickness = 1
|
ensure_vertical_shell_thickness = 1
|
||||||
external_fill_pattern = rectilinear
|
external_fill_pattern = rectilinear
|
||||||
external_perimeters_first = 0
|
external_perimeters_first = 0
|
||||||
@ -48,8 +48,8 @@ extruder_clearance_height = 12
|
|||||||
extruder_clearance_radius = 45
|
extruder_clearance_radius = 45
|
||||||
extrusion_width = 0.45
|
extrusion_width = 0.45
|
||||||
fill_angle = 45
|
fill_angle = 45
|
||||||
fill_density = 20%
|
fill_density = 15%
|
||||||
fill_pattern = grid
|
fill_pattern = cubic
|
||||||
first_layer_extrusion_width = 0.42
|
first_layer_extrusion_width = 0.42
|
||||||
first_layer_height = 0.2
|
first_layer_height = 0.2
|
||||||
first_layer_speed = 20
|
first_layer_speed = 20
|
||||||
@ -72,7 +72,7 @@ overhangs = 1
|
|||||||
only_retract_when_crossing_perimeters = 0
|
only_retract_when_crossing_perimeters = 0
|
||||||
ooze_prevention = 0
|
ooze_prevention = 0
|
||||||
output_filename_format = {input_filename_base}_{layer_height}mm_{if num_extruders==1}{filament_type[0]}{else}E1{filament_type[0]}_E2{filament_type[1]}{endif}_{printer_model}_{print_time}.gcode
|
output_filename_format = {input_filename_base}_{layer_height}mm_{if num_extruders==1}{filament_type[0]}{else}E1{filament_type[0]}_E2{filament_type[1]}{endif}_{printer_model}_{print_time}.gcode
|
||||||
perimeters = 2
|
perimeters = 3
|
||||||
perimeter_extruder = 1
|
perimeter_extruder = 1
|
||||||
perimeter_extrusion_width = 0.45
|
perimeter_extrusion_width = 0.45
|
||||||
post_process =
|
post_process =
|
||||||
@ -389,6 +389,10 @@ support_material_interface_layers = 3
|
|||||||
support_material_with_sheath = 0
|
support_material_with_sheath = 0
|
||||||
support_material_xy_spacing = 80%
|
support_material_xy_spacing = 80%
|
||||||
|
|
||||||
|
# XXXXXXXXXXXXXXXXXXXXXX
|
||||||
|
# XXX--- filament ---XXX
|
||||||
|
# XXXXXXXXXXXXXXXXXXXXXX
|
||||||
|
|
||||||
# Common filament preset
|
# Common filament preset
|
||||||
[filament:*common*]
|
[filament:*common*]
|
||||||
cooling = 0
|
cooling = 0
|
||||||
@ -494,6 +498,17 @@ inherits = *PLA*
|
|||||||
filament_vendor = Generic
|
filament_vendor = Generic
|
||||||
filament_notes = "List of materials which typically use standard PLA print settings:\n\nDas Filament\nEsun PLA\nEUMAKERS PLA\nFiberlogy HD-PLA\nFillamentum PLA\nFloreon3D\nHatchbox PLA\nPlasty Mladec PLA\nPrimavalue PLA\nProto pasta Matte Fiber\nVerbatim PLA\nVerbatim BVOH"
|
filament_notes = "List of materials which typically use standard PLA print settings:\n\nDas Filament\nEsun PLA\nEUMAKERS PLA\nFiberlogy HD-PLA\nFillamentum PLA\nFloreon3D\nHatchbox PLA\nPlasty Mladec PLA\nPrimavalue PLA\nProto pasta Matte Fiber\nVerbatim PLA\nVerbatim BVOH"
|
||||||
|
|
||||||
|
[filament:BIBO White PLA @BIBO2]
|
||||||
|
inherits = *PLA*
|
||||||
|
filament_colour = #FFFFFF
|
||||||
|
filament_vendor = BIBO
|
||||||
|
filament_notes = "General Settings for the BIBO White Filament Which is included with the printer"
|
||||||
|
filament_cost = 20
|
||||||
|
first_layer_bed_temperature = 30
|
||||||
|
bed_temperature = 30
|
||||||
|
first_layer_temperature = 200
|
||||||
|
temperature = 190
|
||||||
|
|
||||||
[filament:Generic PETG @BIBO2]
|
[filament:Generic PETG @BIBO2]
|
||||||
inherits = *PET*
|
inherits = *PET*
|
||||||
filament_vendor = Generic
|
filament_vendor = Generic
|
||||||
@ -690,6 +705,10 @@ min_print_speed = 15
|
|||||||
slowdown_below_layer_time = 10
|
slowdown_below_layer_time = 10
|
||||||
cooling = 1
|
cooling = 1
|
||||||
|
|
||||||
|
# XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
|
||||||
|
# XXX--- Printer settings ---XXX
|
||||||
|
# XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
|
||||||
|
|
||||||
# Common printer preset
|
# Common printer preset
|
||||||
[printer:*common*]
|
[printer:*common*]
|
||||||
printer_technology = FFF
|
printer_technology = FFF
|
||||||
@ -702,20 +721,20 @@ extruder_offset = 0x0
|
|||||||
gcode_flavor = marlin
|
gcode_flavor = marlin
|
||||||
silent_mode = 0
|
silent_mode = 0
|
||||||
remaining_times = 0
|
remaining_times = 0
|
||||||
machine_max_acceleration_e = 1100
|
machine_max_acceleration_x = 1100
|
||||||
machine_max_acceleration_extruding = 5000
|
machine_max_acceleration_y = 1100
|
||||||
machine_max_acceleration_retracting = 1100
|
|
||||||
machine_max_acceleration_x = 500
|
|
||||||
machine_max_acceleration_y = 500
|
|
||||||
machine_max_acceleration_z = 100
|
machine_max_acceleration_z = 100
|
||||||
machine_max_feedrate_e = 20
|
machine_max_acceleration_e = 5000
|
||||||
|
machine_max_acceleration_extruding = 1100
|
||||||
|
machine_max_acceleration_retracting = 1100
|
||||||
machine_max_feedrate_x = 350
|
machine_max_feedrate_x = 350
|
||||||
machine_max_feedrate_y = 350
|
machine_max_feedrate_y = 350
|
||||||
machine_max_feedrate_z = 2
|
machine_max_feedrate_z = 2
|
||||||
machine_max_jerk_e = 5
|
machine_max_feedrate_e = 25
|
||||||
machine_max_jerk_x = 8
|
machine_max_jerk_x = 10
|
||||||
machine_max_jerk_y = 8
|
machine_max_jerk_y = 10
|
||||||
machine_max_jerk_z = 0.3
|
machine_max_jerk_z = 0.3
|
||||||
|
machine_max_jerk_e = 5
|
||||||
machine_min_extruding_rate = 0
|
machine_min_extruding_rate = 0
|
||||||
machine_min_travel_rate = 0
|
machine_min_travel_rate = 0
|
||||||
layer_gcode = ;AFTER_LAYER_CHANGE\n;[layer_z]
|
layer_gcode = ;AFTER_LAYER_CHANGE\n;[layer_z]
|
||||||
@ -776,7 +795,7 @@ retract_lift_below = 0,0
|
|||||||
retract_restart_extra = 0,0
|
retract_restart_extra = 0,0
|
||||||
retract_restart_extra_toolchange = 0,0
|
retract_restart_extra_toolchange = 0,0
|
||||||
retract_speed = 20,20
|
retract_speed = 20,20
|
||||||
start_gcode = ;Start code PrusaSlicer BIBO 2 printers\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{max(first_layer_bed_temperature[0] - 5, first_layer_bed_temperature[1] - 5)} ; wait for bed temp\nM140 S{max(first_layer_bed_temperature[0], first_layer_bed_temperature[1])} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[1]} T1; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[1]} T1; wait for 2nd nozzle heat to first layer temperature\nM105 ; Report Temperatures\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2.0 F400 ; move the platform down 2mm\nT[initial_tool]; switch to initial tool position\nG92 E0.0 ; reset extruder\nG28 ; Home all axis\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO now Printing... ; Put now printing message on screen
|
start_gcode = ;Start code PrusaSlicer BIBO 2 printers\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{max(first_layer_bed_temperature[0] - 5, first_layer_bed_temperature[1] - 5)} ; wait for bed temp\nM140 S{max(first_layer_bed_temperature[0], first_layer_bed_temperature[1])} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[1]} T1; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[1]} T1; wait for 2nd nozzle heat to first layer temperature\nM105 ; Report Temperatures\nT0 ; Start at T0 to avoid extruder nozzle offset issues\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2.0 F400 ; move the platform down 2mm\nG92 E0.0 ; reset extruder\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nT[initial_tool]; switch to initial tool position\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO now Printing... ; Put now printing message on screen
|
||||||
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
||||||
thumbnails =
|
thumbnails =
|
||||||
toolchange_gcode =
|
toolchange_gcode =
|
||||||
@ -798,7 +817,7 @@ deretract_speed = 0 # Setting this value to 0 uses the retract speed
|
|||||||
retract_before_wipe = 100%
|
retract_before_wipe = 100%
|
||||||
default_print_profile = 0.20mm NORMAL @BIBO2
|
default_print_profile = 0.20mm NORMAL @BIBO2
|
||||||
default_filament_profile = Generic PLA @BIBO2
|
default_filament_profile = Generic PLA @BIBO2
|
||||||
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E1 only (i.e. T0)\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{first_layer_bed_temperature[0] - 5} ; wait for bed temp\nM140 S{first_layer_bed_temperature[0]} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[0] * 0.791} T1 ; set 2nd nozzle heater to 79.1 percent standby temp\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[0] * 0.791} T1 ; wait for 2nd nozzle heat to 79.1 percent standby temp\nM105 ; Report Temperatures\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nT[initial_tool] ; switch to initial tool position\nG92 E0.0 ; reset extruder\nG28 ; Home all axis\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nM117 Cleaning... ; Put Cleaning message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO E1 now Printing... ; Put now printing message on screen
|
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E1 only (i.e. T0)\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{first_layer_bed_temperature[0] - 5} ; wait for bed temp\nM140 S{first_layer_bed_temperature[0]} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[0] * 0.791} T1 ; set 2nd nozzle heater to 79.1 percent standby temp\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[0] * 0.791} T1 ; wait for 2nd nozzle heat to 79.1 percent standby temp\nM105 ; Report Temperatures\nT0 ; Start at T0 to avoid extruder nozzle offset issues\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nT[initial_tool] ; switch to initial tool position\nG92 E0.0 ; reset extruder\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nM117 Cleaning... ; Put Cleaning message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO E1 now Printing... ; Put now printing message on screen
|
||||||
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
||||||
thumbnails =
|
thumbnails =
|
||||||
toolchange_gcode =
|
toolchange_gcode =
|
||||||
@ -821,7 +840,7 @@ deretract_speed = 0 # Setting this value to 0 uses the retract speed
|
|||||||
retract_before_wipe = 100%
|
retract_before_wipe = 100%
|
||||||
default_print_profile = 0.20mm NORMAL @BIBO2
|
default_print_profile = 0.20mm NORMAL @BIBO2
|
||||||
default_filament_profile = Generic PLA @BIBO2
|
default_filament_profile = Generic PLA @BIBO2
|
||||||
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E2 only (i.e. T1)\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM140 S{first_layer_bed_temperature[0] - 5} ; set bed temp\nM105 ; Report Temperatures\nM190 S{first_layer_bed_temperature[0]} ; wait for bed temp\nM104 S{first_layer_temperature[0] * 0.791} T0 ; set 1st nozzle heater to 79.1 percent standby temp\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0] * 0.791} T0 ; set 1st nozzle heater to 79.1 percent standby temp\nM109 S{first_layer_temperature[0]} T1 ; Wait for 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2 F400 ; move the print bed down 2mm\nT0 ; switch to tool position T0\nG90 ; absolute positioning\nG92 E0.0 ; zero the current extruder coordinate\nG28 ; Home all axis\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nT1 ; switch to tool position T1\nG92 E0.0 ; zero the current extruder coordinate\nM117 E2 nozzle wipe... ; Put Nozzle wipe message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder coordinate to zero before printing\nM117 BIBO Now Printing from E2... ; Put now printing message on screen
|
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E2 only (i.e. T1)\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM140 S{first_layer_bed_temperature[0] - 5} ; set bed temp\nM105 ; Report Temperatures\nM190 S{first_layer_bed_temperature[0]} ; wait for bed temp\nM104 S{first_layer_temperature[0] * 0.791} T0 ; set 1st nozzle heater to 79.1 percent standby temp\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0] * 0.791} T0 ; set 1st nozzle heater to 79.1 percent standby temp\nM109 S{first_layer_temperature[0]} T1 ; Wait for 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nT0 ; switch to tool position T0\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2 F400 ; move the print bed down 2mm\nG92 E0.0 ; zero the current extruder coordinate\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nT1 ; switch to tool position T1\nG92 E0.0 ; zero the current extruder coordinate\nM117 E2 nozzle wipe... ; Put Nozzle wipe message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder coordinate to zero before printing\nM117 BIBO Now Printing from E2... ; Put now printing message on screen
|
||||||
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM117 BIBO Print complete ; Put print complete message on screen
|
||||||
thumbnails =
|
thumbnails =
|
||||||
toolchange_gcode =
|
toolchange_gcode =
|
||||||
@ -838,7 +857,7 @@ bed_shape = 0x-93,33x-93,33x93,0x93
|
|||||||
#bed_model = BIBO2_bed.stl
|
#bed_model = BIBO2_bed.stl
|
||||||
#bed_texture = BIBO2.svg
|
#bed_texture = BIBO2.svg
|
||||||
before_layer_gcode = ;BEFORE_LAYER_CHANGE\n;[layer_z]\nM104 S{temperature[0]} T1 ; set 2nd nozzle heater to print temperature\nG92 E0\n
|
before_layer_gcode = ;BEFORE_LAYER_CHANGE\n;[layer_z]\nM104 S{temperature[0]} T1 ; set 2nd nozzle heater to print temperature\nG92 E0\n
|
||||||
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E1 only (i.e. T0)\nM420 S1 ; Turn on Ditto Printing\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{first_layer_bed_temperature[0] - 5} ; wait for bed temp\nM140 S{first_layer_bed_temperature[0]} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to same first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[0]} T1 ; wait for 2nd nozzle heat to same first layer temperature\nM105 ; Report Temperatures\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nT[initial_tool] ; switch to initial tool position\nG92 E0.0 ; reset extruder\nG28 ; Home all axis\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nM117 Cleaning... ; Put Cleaning message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO E1 now Printing... ; Put now printing message on screen
|
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E1 only (i.e. T0)\nM420 S1 ; Turn on Ditto Printing\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM190 S{first_layer_bed_temperature[0] - 5} ; wait for bed temp\nM140 S{first_layer_bed_temperature[0]} ; continue bed heating to full temp while other things are happening\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to first layer temperature\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to same first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; wait for 1st nozzle heat to first layer temperature\nM109 S{first_layer_temperature[0]} T1 ; wait for 2nd nozzle heat to same first layer temperature\nM105 ; Report Temperatures\nT0 ; Start at T0 to avoid extruder nozzle offset issues\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Y0 F1200 E0 ; move Y to min endstop and extrude 0 filament\nT[initial_tool] ; switch to initial tool position\nG92 E0.0 ; reset extruder\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nM117 Cleaning... ; Put Cleaning message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder and zero the current extruder coordinate before printing\nM117 BIBO E1 now Printing... ; Put now printing message on screen
|
||||||
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM420 S0 ; Turn off Ditto Printing function\nM117 BIBO Print complete ; Put print complete message on screen
|
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM420 S0 ; Turn off Ditto Printing function\nM117 BIBO Print complete ; Put print complete message on screen
|
||||||
|
|
||||||
[printer:BIBO2 E2 left E1 Ditto]
|
[printer:BIBO2 E2 left E1 Ditto]
|
||||||
@ -849,5 +868,5 @@ bed_shape = -33x-93,0x-93,0x93,-33x93
|
|||||||
#bed_model = BIBO2_bed.stl
|
#bed_model = BIBO2_bed.stl
|
||||||
#bed_texture = BIBO2.svg
|
#bed_texture = BIBO2.svg
|
||||||
before_layer_gcode = ;BEFORE_LAYER_CHANGE\n;[layer_z]\nM104 S{temperature[0]} T0 ; set 1st nozzle heater to print temperature\nG92 E0\n
|
before_layer_gcode = ;BEFORE_LAYER_CHANGE\n;[layer_z]\nM104 S{temperature[0]} T0 ; set 1st nozzle heater to print temperature\nG92 E0\n
|
||||||
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E2 only (i.e. T1)\nM420 S1 ; Turn on Ditto Printing\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM140 S{first_layer_bed_temperature[0] - 5} ; set bed temp\nM105 ; Report Temperatures\nM190 S{first_layer_bed_temperature[0]} ; wait for bed temp\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to ditto print temperature\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to ditto printing temperature\nM109 S{first_layer_temperature[0]} T1 ; Wait for 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2 F400 ; move the print bed down 2mm\nT0 ; switch to tool position T0\nG90 ; absolute positioning\nG92 E0.0 ; zero the current extruder coordinate\nG28 ; Home all axis\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nT1 ; switch to tool position T1\nG92 E0.0 ; zero the current extruder coordinate\nM117 E2 nozzle wipe... ; Put Nozzle wipe message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder coordinate to zero before printing\nM117 BIBO Now Printing from E2... ; Put now printing message on screen
|
start_gcode = ;Start code PrusaSlicer BIBO 2 printers E2 only (i.e. T1)\nM420 S1 ; Turn on Ditto Printing\nG21 ; set units to metric\nG90 ; absolute positioning\nM107 ; start with the fan off\nM140 S{first_layer_bed_temperature[0] - 5} ; set bed temp\nM105 ; Report Temperatures\nM190 S{first_layer_bed_temperature[0]} ; wait for bed temp\nM104 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to ditto print temperature\nM104 S{first_layer_temperature[0]} T1 ; set 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nM109 S{first_layer_temperature[0]} T0 ; set 1st nozzle heater to ditto printing temperature\nM109 S{first_layer_temperature[0]} T1 ; Wait for 2nd nozzle heater to first layer temperature\nM105 ; Report Temperatures\nT0 ; Start at T0 to avoid extruder nozzle offset issues\nG28 X0 Y0 ; move X/Y to min endstops\nG28 Z0 ; move Z to min endstops\nG1 Z2 F400 ; move the print bed down 2mm\nG92 E0.0 ; zero the current extruder coordinate\nG1 Y0 F1200 E0 ; move Y to min endstop and reset extruder\nG92 E0.0 ; zero the current extruder coordinate\nT1 ; switch to tool position T1\nG92 E0.0 ; zero the current extruder coordinate\nM117 E2 nozzle wipe... ; Put Nozzle wipe message on screen, Attempt Nozzle Wipe (for ooze free startup)\nG1 X-15.0 Y-92.9 Z0.3 F2400.0 ; move to start-line position\nG1 X15.0 Y-92.9 Z0.3 F1000.0 E2 ; draw 1st line\nG1 X15.0 Y-92.6 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92.6 Z0.3 F1000.0 E4 ; draw 2nd line\nG1 X-15.0 Y-92.3 Z0.3 F3000.0 ; move to side a little\nG1 X15.0 Y-92.3 Z0.3 F1000.0 E6 ; draw 3rd line\nG1 X15.0 Y-92 Z0.3 F3000.0 ; move to side a little\nG1 X-15.0 Y-92 Z0.3 F1000.0 E8 ; draw 4th line\nG92 E0.0 ; reset extruder coordinate to zero before printing\nM117 BIBO Now Printing from E2... ; Put now printing message on screen
|
||||||
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM420 S0 ; Turn off Ditto Printing function\nM117 BIBO Print complete ; Put print complete message on screen
|
end_gcode = ;BIBO End GCode\nM107 ; turn fans off\nG91 ; Relative positioning\nG1 Z1 F100\nM140 S0 ; Disable heated bed\nM104 T0 S0 ; extruder T0 heater off\nM104 T1 S0 ; extruder T1 heater off\nG1 Z+0.5 X-20 Y-20 F300 ; move Z down then move print head a bit out of the way\nG28 X0 Y0 ; move X/Y to min endstops, so the head is out of the way\nG90 ; Absolute positioning\nG92 E0.0 ; Reset extruder position\nM84 ; Turn steppers off\nM420 S0 ; Turn off Ditto Printing function\nM117 BIBO Print complete ; Put print complete message on screen
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
min_slic3r_version = 2.6.0-alpha0
|
min_slic3r_version = 2.6.0-alpha0
|
||||||
|
0.2.7 Added Eolas Prints filaments.
|
||||||
0.2.6 Add Ender-5 Pro, Ender-5 S1, Sermoon-V1, Sermoon-V1 Pro. Unlock HIGHSPEED/SUPERSPEED presets for Ender-5 S1/Ender-6/Ender-7.
|
0.2.6 Add Ender-5 Pro, Ender-5 S1, Sermoon-V1, Sermoon-V1 Pro. Unlock HIGHSPEED/SUPERSPEED presets for Ender-5 S1/Ender-6/Ender-7.
|
||||||
min_slic3r_version = 2.5.0-alpha0
|
min_slic3r_version = 2.5.0-alpha0
|
||||||
0.2.4 Add SPEED presets. More conservative extruder clearance.
|
0.2.4 Add SPEED presets. More conservative extruder clearance.
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
name = Creality
|
name = Creality
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 0.2.6
|
config_version = 0.2.7
|
||||||
# Where to get the updates from?
|
# Where to get the updates from?
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Creality/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Creality/
|
||||||
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
# changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
||||||
@ -1510,7 +1510,66 @@ filament_cost = 28.99
|
|||||||
filament_density = 1.12
|
filament_density = 1.12
|
||||||
filament_colour = #3598DB
|
filament_colour = #3598DB
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA @CREALITY]
|
||||||
|
inherits = *PLA*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 23.50
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
first_layer_bed_temperature = 65
|
||||||
|
first_layer_temperature = 208
|
||||||
|
temperature = 202
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA Matte @CREALITY]
|
||||||
|
inherits = Eolas Prints PLA @CREALITY
|
||||||
|
filament_cost = 25.50
|
||||||
|
filament_max_volumetric_speed = 14
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 850 @CREALITY]
|
||||||
|
inherits = Eolas Prints PLA @CREALITY
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 870 @CREALITY]
|
||||||
|
inherits = Eolas Prints PLA @CREALITY
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 215
|
||||||
|
first_layer_bed_temperature = 68
|
||||||
|
first_layer_temperature = 220
|
||||||
|
bed_temperature = 65
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG @CREALITY]
|
||||||
|
inherits = *PET*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 29.90
|
||||||
|
filament_density = 1.27
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
temperature = 240
|
||||||
|
first_layer_bed_temperature = 85
|
||||||
|
first_layer_temperature = 235
|
||||||
|
bed_temperature = 90
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG - UV Resistant @CREALITY]
|
||||||
|
inherits = Eolas Prints PETG @CREALITY
|
||||||
|
filament_cost = 35.90
|
||||||
|
temperature = 242
|
||||||
|
first_layer_temperature = 237
|
||||||
|
|
||||||
|
[filament:Eolas Prints TPU 93A @CREALITY]
|
||||||
|
inherits = *TPU*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 34.99
|
||||||
|
filament_density = 1.21
|
||||||
|
filament_colour = #4D9398
|
||||||
|
filament_max_volumetric_speed = 1.2
|
||||||
|
temperature = 235
|
||||||
|
first_layer_bed_temperature = 30
|
||||||
|
bed_temperature = 30
|
||||||
|
filament_retract_length = 0
|
||||||
|
extrusion_multiplier = 1.16
|
||||||
|
|
||||||
# Common printer preset
|
# Common printer preset
|
||||||
[printer:*common*]
|
[printer:*common*]
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
min_slic3r_version = 2.6.0-alpha1
|
min_slic3r_version = 2.6.0-alpha1
|
||||||
|
1.0.3 Added Eolas Prints filaments.
|
||||||
1.0.2 Added new printer models.
|
1.0.2 Added new printer models.
|
||||||
min_slic3r_version = 2.5.0-alpha3
|
min_slic3r_version = 2.5.0-alpha3
|
||||||
1.0.1 Decreased bed size to 220x220.
|
1.0.1 Decreased bed size to 220x220.
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
name = Elegoo
|
name = Elegoo
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 1.0.2
|
config_version = 1.0.3
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Elegoo/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/Elegoo/
|
||||||
|
|
||||||
# The printer models will be shown by the Configuration Wizard in this order,
|
# The printer models will be shown by the Configuration Wizard in this order,
|
||||||
@ -365,6 +365,54 @@ first_layer_bed_temperature = 90
|
|||||||
bed_temperature = 90
|
bed_temperature = 90
|
||||||
filament_vendor = Generic
|
filament_vendor = Generic
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA @ELEGOO]
|
||||||
|
inherits = *PLA*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 23.50
|
||||||
|
filament_density = 1.24
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
first_layer_bed_temperature = 65
|
||||||
|
first_layer_temperature = 208
|
||||||
|
temperature = 202
|
||||||
|
|
||||||
|
[filament:Eolas Prints PLA Matte @ELEGOO]
|
||||||
|
inherits = Eolas Prints PLA @ELEGOO
|
||||||
|
filament_cost = 25.50
|
||||||
|
filament_max_volumetric_speed = 14
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 850 @ELEGOO]
|
||||||
|
inherits = Eolas Prints PLA @ELEGOO
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 210
|
||||||
|
|
||||||
|
[filament:Eolas Prints INGEO 870 @ELEGOO]
|
||||||
|
inherits = Eolas Prints PLA @ELEGOO
|
||||||
|
filament_cost = 25.90
|
||||||
|
temperature = 215
|
||||||
|
first_layer_bed_temperature = 68
|
||||||
|
first_layer_temperature = 220
|
||||||
|
bed_temperature = 65
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG @ELEGOO]
|
||||||
|
inherits = *PET*
|
||||||
|
filament_vendor = Eolas Prints
|
||||||
|
filament_cost = 29.90
|
||||||
|
filament_density = 1.27
|
||||||
|
filament_spool_weight = 0
|
||||||
|
filament_colour = #4D9398
|
||||||
|
temperature = 240
|
||||||
|
first_layer_bed_temperature = 85
|
||||||
|
first_layer_temperature = 235
|
||||||
|
bed_temperature = 90
|
||||||
|
|
||||||
|
[filament:Eolas Prints PETG - UV Resistant @ELEGOO]
|
||||||
|
inherits = Eolas Prints PETG @ELEGOO
|
||||||
|
filament_cost = 35.90
|
||||||
|
temperature = 242
|
||||||
|
first_layer_temperature = 237
|
||||||
|
|
||||||
# Common printer preset
|
# Common printer preset
|
||||||
[printer:*common*]
|
[printer:*common*]
|
||||||
printer_technology = FFF
|
printer_technology = FFF
|
||||||
|
2
resources/profiles/MakerGear.idx
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
min_slic3r_version = 2.6.0-alpha1
|
||||||
|
0.1.0 Initial version
|
1754
resources/profiles/MakerGear.ini
Normal file
BIN
resources/profiles/MakerGear/M2_M3.stl
Normal file
1
resources/profiles/MakerGear/M2_M3.svg
Normal file
After Width: | Height: | Size: 27 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_M2_DUAL_thumbnail.png
Normal file
After Width: | Height: | Size: 41 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_M2_thumbnail.png
Normal file
After Width: | Height: | Size: 51 KiB |
After Width: | Height: | Size: 32 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_M3_SE_thumbnail.png
Normal file
After Width: | Height: | Size: 39 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_M3_thumbnail.png
Normal file
After Width: | Height: | Size: 38 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_MICRO_thumbnail.png
Normal file
After Width: | Height: | Size: 47 KiB |
BIN
resources/profiles/MakerGear/MAKERGEAR_U1_thumbnail.png
Normal file
After Width: | Height: | Size: 46 KiB |
@ -1,6 +1,8 @@
|
|||||||
min_slic3r_version = 2.6.0-alpha1
|
min_slic3r_version = 2.6.0-alpha1
|
||||||
|
1.6.0-alpha1 Updated FW version notification. Decreased min layer time for PLA.
|
||||||
1.6.0-alpha0 Default top fill set to monotonic lines. Updated infill/perimeter overlap values. Updated output filename format. Enabled dynamic overhang speeds.
|
1.6.0-alpha0 Default top fill set to monotonic lines. Updated infill/perimeter overlap values. Updated output filename format. Enabled dynamic overhang speeds.
|
||||||
min_slic3r_version = 2.5.0-alpha0
|
min_slic3r_version = 2.5.0-alpha0
|
||||||
|
1.5.6 Updated FW version notification (MK2.5/MK3 family). Added filament profile for Kimya PEBA-S.
|
||||||
1.5.5 Added new Prusament Resin material profiles. Enabled g-code thumbnails for MK2.5 family printers.
|
1.5.5 Added new Prusament Resin material profiles. Enabled g-code thumbnails for MK2.5 family printers.
|
||||||
1.5.4 Added material profiles for Prusament Resin BioBased60.
|
1.5.4 Added material profiles for Prusament Resin BioBased60.
|
||||||
1.5.3 Added filament profiles for ColorFabb VarioShore TPU, FormFutura PP, NinjaTek NinjaFlex/Cheetah TPU and for multiple Eolas Prints filaments. Updated bridging settings in 50um and 70um profiles.
|
1.5.3 Added filament profiles for ColorFabb VarioShore TPU, FormFutura PP, NinjaTek NinjaFlex/Cheetah TPU and for multiple Eolas Prints filaments. Updated bridging settings in 50um and 70um profiles.
|
||||||
@ -10,6 +12,7 @@ min_slic3r_version = 2.5.0-alpha0
|
|||||||
1.5.0-alpha1 Added filament profile for Prusament PA11 Carbon Fiber. Added profiles for multiple 3D-Fuel filaments.
|
1.5.0-alpha1 Added filament profile for Prusament PA11 Carbon Fiber. Added profiles for multiple 3D-Fuel filaments.
|
||||||
1.5.0-alpha0 Added parameters for Arachne perimeter generator. Changed default seam position. Updated output filename format.
|
1.5.0-alpha0 Added parameters for Arachne perimeter generator. Changed default seam position. Updated output filename format.
|
||||||
min_slic3r_version = 2.4.0-rc
|
min_slic3r_version = 2.4.0-rc
|
||||||
|
1.4.9 Updated FW version notification.
|
||||||
1.4.8 Added filament and SLA material profiles. Updated settings.
|
1.4.8 Added filament and SLA material profiles. Updated settings.
|
||||||
1.4.7 Added filament profile for Prusament PA11 Carbon Fiber. Added profiles for multiple 3D-Fuel filaments.
|
1.4.7 Added filament profile for Prusament PA11 Carbon Fiber. Added profiles for multiple 3D-Fuel filaments.
|
||||||
1.4.6 Added SLA materials. Updated filament profiles.
|
1.4.6 Added SLA materials. Updated filament profiles.
|
||||||
@ -39,6 +42,7 @@ min_slic3r_version = 2.4.0-alpha0
|
|||||||
1.3.0-alpha1 Added Prusament PCCF. Increased travel acceleration for Prusa MINI. Updated start g-code for Prusa MINI. Added multiple add:north and Extrudr filament profiles. Updated Z travel speed values.
|
1.3.0-alpha1 Added Prusament PCCF. Increased travel acceleration for Prusa MINI. Updated start g-code for Prusa MINI. Added multiple add:north and Extrudr filament profiles. Updated Z travel speed values.
|
||||||
1.3.0-alpha0 Disabled thick bridges, updated support settings.
|
1.3.0-alpha0 Disabled thick bridges, updated support settings.
|
||||||
min_slic3r_version = 2.3.2-alpha0
|
min_slic3r_version = 2.3.2-alpha0
|
||||||
|
1.3.8 Updated FW version notification.
|
||||||
1.3.7 Updated firmware version.
|
1.3.7 Updated firmware version.
|
||||||
1.3.6 Updated firmware version.
|
1.3.6 Updated firmware version.
|
||||||
1.3.5 Added material profiles for Prusament Resins.
|
1.3.5 Added material profiles for Prusament Resins.
|
||||||
@ -48,6 +52,7 @@ min_slic3r_version = 2.3.2-alpha0
|
|||||||
1.3.1 Added multiple add:north and Extrudr filament profiles. Updated support head settings (SL1S).
|
1.3.1 Added multiple add:north and Extrudr filament profiles. Updated support head settings (SL1S).
|
||||||
1.3.0 Added SL1S SPEED profiles.
|
1.3.0 Added SL1S SPEED profiles.
|
||||||
min_slic3r_version = 2.3.0-rc1
|
min_slic3r_version = 2.3.0-rc1
|
||||||
|
1.2.13 Updated FW version notification.
|
||||||
1.2.12 Updated firmware version.
|
1.2.12 Updated firmware version.
|
||||||
1.2.11 Updated firmware version.
|
1.2.11 Updated firmware version.
|
||||||
1.2.10 Added multiple profiles for Filatech filaments. Updated SLA print settings (pad wall slope angle).
|
1.2.10 Added multiple profiles for Filatech filaments. Updated SLA print settings (pad wall slope angle).
|
||||||
@ -69,6 +74,7 @@ min_slic3r_version = 2.3.0-alpha4
|
|||||||
1.2.0-alpha1 Renamed MK3S and MINI printer profiles. Updated end g-code (MINI). Added new SLA materials and filament profiles.
|
1.2.0-alpha1 Renamed MK3S and MINI printer profiles. Updated end g-code (MINI). Added new SLA materials and filament profiles.
|
||||||
1.2.0-alpha0 Added filament spool weights
|
1.2.0-alpha0 Added filament spool weights
|
||||||
min_slic3r_version = 2.2.0-alpha3
|
min_slic3r_version = 2.2.0-alpha3
|
||||||
|
1.1.17 Updated FW version notification.
|
||||||
1.1.16 Updated firmware version.
|
1.1.16 Updated firmware version.
|
||||||
1.1.15 Updated firmware version.
|
1.1.15 Updated firmware version.
|
||||||
1.1.14 Updated firmware version.
|
1.1.14 Updated firmware version.
|
||||||
@ -95,6 +101,7 @@ min_slic3r_version = 2.2.0-alpha0
|
|||||||
1.1.1-alpha2 Bumped up config version, so our in house customer will get updated profiles.
|
1.1.1-alpha2 Bumped up config version, so our in house customer will get updated profiles.
|
||||||
1.1.0 Filament aliases, Creality profiles and other goodies for PrusaSlicer 2.2.0-alpha0
|
1.1.0 Filament aliases, Creality profiles and other goodies for PrusaSlicer 2.2.0-alpha0
|
||||||
min_slic3r_version = 2.1.1-beta0
|
min_slic3r_version = 2.1.1-beta0
|
||||||
|
1.0.13 Updated FW version notification.
|
||||||
1.0.12 Updated firmware version.
|
1.0.12 Updated firmware version.
|
||||||
1.0.11 Updated firmware version.
|
1.0.11 Updated firmware version.
|
||||||
1.0.10 Updated firmware version for MK2.5/S and MK3/S.
|
1.0.10 Updated firmware version for MK2.5/S and MK3/S.
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
name = Prusa Research
|
name = Prusa Research
|
||||||
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
# Configuration version of this file. Config file will only be installed, if the config_version differs.
|
||||||
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
# This means, the server may force the PrusaSlicer configuration to be downgraded.
|
||||||
config_version = 1.6.0-alpha0
|
config_version = 1.6.0-alpha1
|
||||||
# Where to get the updates from?
|
# Where to get the updates from?
|
||||||
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/PrusaResearch/
|
config_update_url = https://files.prusa3d.com/wp-content/uploads/repository/PrusaSlicer-settings-master/live/PrusaResearch/
|
||||||
changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
changelog_url = https://files.prusa3d.com/?latest=slicer-profiles&lng=%1%
|
||||||
@ -1589,6 +1589,7 @@ first_layer_temperature = 215
|
|||||||
max_fan_speed = 100
|
max_fan_speed = 100
|
||||||
min_fan_speed = 100
|
min_fan_speed = 100
|
||||||
temperature = 210
|
temperature = 210
|
||||||
|
slowdown_below_layer_time = 10
|
||||||
start_filament_gcode = "M900 K{if printer_notes=~/.*PRINTER_MODEL_MINI.*/ and nozzle_diameter[0]==0.6}0.12{elsif printer_notes=~/.*PRINTER_MODEL_MINI.*/ and nozzle_diameter[0]==0.8}0.06{elsif printer_notes=~/.*PRINTER_MODEL_MINI.*/}0.2{elsif nozzle_diameter[0]==0.8}0.01{elsif nozzle_diameter[0]==0.6}0.04{else}0.05{endif} ; Filament gcode LA 1.5\n{if printer_notes=~/.*PRINTER_MODEL_MINI.*/};{elsif printer_notes=~/.*PRINTER_HAS_BOWDEN.*/}M900 K200{elsif nozzle_diameter[0]==0.6}M900 K18{elsif nozzle_diameter[0]==0.8};{else}M900 K30{endif} ; Filament gcode LA 1.0"
|
start_filament_gcode = "M900 K{if printer_notes=~/.*PRINTER_MODEL_MINI.*/ and nozzle_diameter[0]==0.6}0.12{elsif printer_notes=~/.*PRINTER_MODEL_MINI.*/ and nozzle_diameter[0]==0.8}0.06{elsif printer_notes=~/.*PRINTER_MODEL_MINI.*/}0.2{elsif nozzle_diameter[0]==0.8}0.01{elsif nozzle_diameter[0]==0.6}0.04{else}0.05{endif} ; Filament gcode LA 1.5\n{if printer_notes=~/.*PRINTER_MODEL_MINI.*/};{elsif printer_notes=~/.*PRINTER_HAS_BOWDEN.*/}M900 K200{elsif nozzle_diameter[0]==0.6}M900 K18{elsif nozzle_diameter[0]==0.8};{else}M900 K30{endif} ; Filament gcode LA 1.0"
|
||||||
|
|
||||||
[filament:*PET*]
|
[filament:*PET*]
|
||||||
@ -9491,7 +9492,7 @@ inherits = Original Prusa i3 MK2S
|
|||||||
printer_model = MK2.5
|
printer_model = MK2.5
|
||||||
remaining_times = 1
|
remaining_times = 1
|
||||||
machine_max_jerk_e = 4.5
|
machine_max_jerk_e = 4.5
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
thumbnails = 160x120
|
thumbnails = 160x120
|
||||||
|
|
||||||
@ -9500,7 +9501,7 @@ inherits = Original Prusa i3 MK2S 0.25 nozzle
|
|||||||
printer_model = MK2.5
|
printer_model = MK2.5
|
||||||
remaining_times = 1
|
remaining_times = 1
|
||||||
machine_max_jerk_e = 4.5
|
machine_max_jerk_e = 4.5
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\nG92 E0
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
thumbnails = 160x120
|
thumbnails = 160x120
|
||||||
|
|
||||||
@ -9510,7 +9511,7 @@ printer_model = MK2.5
|
|||||||
remaining_times = 1
|
remaining_times = 1
|
||||||
machine_max_jerk_e = 4.5
|
machine_max_jerk_e = 4.5
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
thumbnails = 160x120
|
thumbnails = 160x120
|
||||||
|
|
||||||
@ -9527,7 +9528,7 @@ deretract_speed = 20
|
|||||||
retract_lift = 0.25
|
retract_lift = 0.25
|
||||||
remaining_times = 1
|
remaining_times = 1
|
||||||
machine_max_jerk_e = 4.5
|
machine_max_jerk_e = 4.5
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y200 F3600 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG4 ; wait\nM104 S0 ; turn off temperature\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
default_filament_profile = Prusament PLA @0.8 nozzle
|
default_filament_profile = Prusament PLA @0.8 nozzle
|
||||||
@ -9542,7 +9543,7 @@ max_print_height = 200
|
|||||||
default_print_profile = 0.15mm OPTIMAL @MK2.5
|
default_print_profile = 0.15mm OPTIMAL @MK2.5
|
||||||
default_filament_profile = Prusament PLA
|
default_filament_profile = Prusament PLA
|
||||||
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK2.5\n
|
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK2.5\n
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\n; select extruder\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; load to nozzle\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.20 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\n; select extruder\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; load to nozzle\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.20 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK2.5 MMU2 Single 0.8 nozzle]
|
[printer:Original Prusa i3 MK2.5 MMU2 Single 0.8 nozzle]
|
||||||
@ -9566,7 +9567,7 @@ printer_notes = Don't remove the following keywords! These keywords are used in
|
|||||||
single_extruder_multi_material = 1
|
single_extruder_multi_material = 1
|
||||||
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
||||||
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\nG92 E0\n
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK2.5S]
|
[printer:Original Prusa i3 MK2.5S]
|
||||||
@ -9593,7 +9594,7 @@ max_print_height = 200
|
|||||||
default_print_profile = 0.15mm OPTIMAL @MK2.5
|
default_print_profile = 0.15mm OPTIMAL @MK2.5
|
||||||
default_filament_profile = Prusament PLA
|
default_filament_profile = Prusament PLA
|
||||||
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK2.5\n
|
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK2.5\n
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK2.5S MMU2S Single 0.8 nozzle]
|
[printer:Original Prusa i3 MK2.5S MMU2S Single 0.8 nozzle]
|
||||||
@ -9607,7 +9608,7 @@ retract_length = 0.7
|
|||||||
retract_speed = 35
|
retract_speed = 35
|
||||||
deretract_speed = 20
|
deretract_speed = 20
|
||||||
retract_lift = 0.25
|
retract_lift = 0.25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
||||||
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
default_filament_profile = Prusament PLA @0.8 nozzle
|
default_filament_profile = Prusament PLA @0.8 nozzle
|
||||||
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
||||||
@ -9632,7 +9633,7 @@ nozzle_diameter = 0.25
|
|||||||
printer_variant = 0.25
|
printer_variant = 0.25
|
||||||
retract_lift = 0.15
|
retract_lift = 0.15
|
||||||
default_print_profile = 0.10mm DETAIL 0.25 nozzle
|
default_print_profile = 0.10mm DETAIL 0.25 nozzle
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n
|
||||||
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK2.5S MMU2S]
|
[printer:Original Prusa i3 MK2.5S MMU2S]
|
||||||
@ -9644,7 +9645,7 @@ printer_notes = Don't remove the following keywords! These keywords are used in
|
|||||||
single_extruder_multi_material = 1
|
single_extruder_multi_material = 1
|
||||||
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
||||||
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\nG92 E0\n
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\nG92 E0\n
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 X0 Y210 F7200\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 X0 Y210 F7200\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM104 S0 ; turn off temperature\nM900 K0 ; reset LA\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK2.5S MMU2S 0.6 nozzle]
|
[printer:Original Prusa i3 MK2.5S MMU2S 0.6 nozzle]
|
||||||
@ -9697,7 +9698,7 @@ color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
|||||||
## printer_variant = 0.8
|
## printer_variant = 0.8
|
||||||
## retract_length = 1
|
## retract_length = 1
|
||||||
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\nG92 E0.0\n
|
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\nG92 E0.0\n
|
||||||
|
|
||||||
## [printer:Original Prusa i3 MK2.5 MMU2 0.8 nozzle]
|
## [printer:Original Prusa i3 MK2.5 MMU2 0.8 nozzle]
|
||||||
## inherits = Original Prusa i3 MK2.5 MMU2
|
## inherits = Original Prusa i3 MK2.5 MMU2
|
||||||
@ -9707,7 +9708,7 @@ color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
|||||||
## printer_variant = 0.8
|
## printer_variant = 0.8
|
||||||
## retract_length = 1
|
## retract_length = 1
|
||||||
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\nG92 E0.0\n
|
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\nG92 E0.0\n
|
||||||
|
|
||||||
# XXXXXXXXXXXXXXXXX
|
# XXXXXXXXXXXXXXXXX
|
||||||
# XXX--- MK3 ---XXX
|
# XXX--- MK3 ---XXX
|
||||||
@ -9737,7 +9738,7 @@ remaining_times = 1
|
|||||||
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK3\n
|
printer_notes = Don't remove the following keywords! These keywords are used in the "compatible printer" condition of the print and filament profiles to link the particular print and filament profiles to this printer profile.\nPRINTER_VENDOR_PRUSA3D\nPRINTER_MODEL_MK3\n
|
||||||
retract_lift_below = 209
|
retract_lift_below = 209
|
||||||
max_print_height = 210
|
max_print_height = 210
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
||||||
printer_model = MK3
|
printer_model = MK3
|
||||||
default_print_profile = 0.15mm QUALITY @MK3
|
default_print_profile = 0.15mm QUALITY @MK3
|
||||||
thumbnails = 160x120
|
thumbnails = 160x120
|
||||||
@ -9749,7 +9750,7 @@ max_layer_height = 0.15
|
|||||||
min_layer_height = 0.05
|
min_layer_height = 0.05
|
||||||
printer_variant = 0.25
|
printer_variant = 0.25
|
||||||
retract_lift = 0.15
|
retract_lift = 0.15
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E8 F700 ; intro line\nG1 X100 E12.5 F700 ; intro line\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E8 F700 ; intro line\nG1 X100 E12.5 F700 ; intro line\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
||||||
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9760,7 +9761,7 @@ max_layer_height = 0.40
|
|||||||
min_layer_height = 0.15
|
min_layer_height = 0.15
|
||||||
printer_variant = 0.6
|
printer_variant = 0.6
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S{if layer_height<0.075}100{else}95{endif}
|
||||||
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9774,7 +9775,7 @@ retract_length = 0.7
|
|||||||
retract_speed = 35
|
retract_speed = 35
|
||||||
deretract_speed = 20
|
deretract_speed = 20
|
||||||
retract_lift = 0.25
|
retract_lift = 0.25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S95
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n{if filament_settings_id[initial_tool]=~/.*Prusament PA11.*/}\nG1 Z0.3 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E9 F1000 ; intro line\n{else}\nG1 Z0.2 F720\nG1 Y-3 F1000 ; go outside print area\nG92 E0\nG1 X60 E9 F1000 ; intro line\nG1 X100 E12.5 F1000 ; intro line\n{endif}\nG92 E0\nM221 S95
|
||||||
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
default_filament_profile = Prusament PLA @0.8 nozzle
|
default_filament_profile = Prusament PLA @0.8 nozzle
|
||||||
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
||||||
@ -9846,7 +9847,7 @@ default_filament_profile = Prusament PLA @MMU2
|
|||||||
inherits = *mm2*
|
inherits = *mm2*
|
||||||
single_extruder_multi_material = 0
|
single_extruder_multi_material = 0
|
||||||
default_filament_profile = Prusament PLA
|
default_filament_profile = Prusament PLA
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK3 MMU2 Single 0.6 nozzle]
|
[printer:Original Prusa i3 MK3 MMU2 Single 0.6 nozzle]
|
||||||
@ -9857,7 +9858,7 @@ max_layer_height = 0.40
|
|||||||
min_layer_height = 0.15
|
min_layer_height = 0.15
|
||||||
printer_variant = 0.6
|
printer_variant = 0.6
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9872,7 +9873,7 @@ retract_length = 0.7
|
|||||||
retract_speed = 35
|
retract_speed = 35
|
||||||
deretract_speed = 20
|
deretract_speed = 20
|
||||||
retract_lift = 0.25
|
retract_lift = 0.25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
default_filament_profile = Prusament PLA @0.8 nozzle
|
default_filament_profile = Prusament PLA @0.8 nozzle
|
||||||
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
||||||
@ -9885,7 +9886,7 @@ max_layer_height = 0.15
|
|||||||
min_layer_height = 0.05
|
min_layer_height = 0.05
|
||||||
printer_variant = 0.25
|
printer_variant = 0.25
|
||||||
retract_lift = 0.15
|
retract_lift = 0.15
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F1000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 E8 F1000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
||||||
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9894,7 +9895,7 @@ inherits = *mm2*
|
|||||||
machine_max_acceleration_e = 8000,8000
|
machine_max_acceleration_e = 8000,8000
|
||||||
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
||||||
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK3S & MK3S+ MMU2S Single]
|
[printer:Original Prusa i3 MK3S & MK3S+ MMU2S Single]
|
||||||
@ -9902,7 +9903,7 @@ inherits = *mm2s*
|
|||||||
renamed_from = "Original Prusa i3 MK3S MMU2S Single"
|
renamed_from = "Original Prusa i3 MK3S MMU2S Single"
|
||||||
single_extruder_multi_material = 0
|
single_extruder_multi_material = 0
|
||||||
default_filament_profile = Prusament PLA
|
default_filament_profile = Prusament PLA
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\nM702 C\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
[printer:Original Prusa i3 MK3S & MK3S+ MMU2S Single 0.6 nozzle]
|
[printer:Original Prusa i3 MK3S & MK3S+ MMU2S Single 0.6 nozzle]
|
||||||
@ -9914,7 +9915,7 @@ max_layer_height = 0.40
|
|||||||
min_layer_height = 0.15
|
min_layer_height = 0.15
|
||||||
printer_variant = 0.6
|
printer_variant = 0.6
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9929,7 +9930,7 @@ retract_length = 0.7
|
|||||||
retract_speed = 35
|
retract_speed = 35
|
||||||
deretract_speed = 20
|
deretract_speed = 20
|
||||||
retract_lift = 0.25
|
retract_lift = 0.25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
default_filament_profile = Prusament PLA @0.8 nozzle
|
default_filament_profile = Prusament PLA @0.8 nozzle
|
||||||
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.6 F1500 ; prime after color change
|
||||||
@ -9943,7 +9944,7 @@ max_layer_height = 0.15
|
|||||||
min_layer_height = 0.05
|
min_layer_height = 0.05
|
||||||
printer_variant = 0.25
|
printer_variant = 0.25
|
||||||
retract_lift = 0.15
|
retract_lift = 0.15
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nTx\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nTc\n; purge line\nG1 X55 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F1400\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E value below. Excessive value can damage the printer.\n{if print_settings_id=~/.*@0.25 nozzle MK3.*/}M907 E430 ; set extruder motor current{endif}
|
||||||
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
default_print_profile = 0.10mm DETAIL @0.25 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9953,7 +9954,7 @@ renamed_from = "Original Prusa i3 MK3S MMU2S"
|
|||||||
machine_max_acceleration_e = 8000,8000
|
machine_max_acceleration_e = 8000,8000
|
||||||
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
nozzle_diameter = 0.4,0.4,0.4,0.4,0.4
|
||||||
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
extruder_colour = #FF8000;#DB5182;#3EC0FF;#FF4F4F;#FBEB7D
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0\n\n; Don't change E values below. Excessive value can damage the printer.\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE).*/}M907 E430 ; set extruder motor current{endif}\n{if print_settings_id=~/.*(SPEED @MK3|DRAFT @MK3).*/}M907 E538 ; set extruder motor current{endif}
|
||||||
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
end_gcode = {if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+1, max_print_height)} F720 ; Move print head up{endif}\nG1 X0 Y210 F7200 ; park\n{if max_layer_z < max_print_height}G1 Z{z_offset+min(max_layer_z+49, max_print_height)} F720 ; Move print head further up{endif}\n{if has_wipe_tower}\nG1 E-15 F3000\n{else}\nG1 E2 F5000\nG1 E2 F5500\nG1 E2 F6000\nG1 E-15 F5800\nG1 E-20 F5500\nG1 E10 F3000\nG1 E-10 F3100\nG1 E10 F3150\nG1 E-10 F3250\nG1 E10 F3300\n{endif}\n\nM140 S0 ; turn off heatbed\nM107 ; turn off fan\n\n; Unload filament\nM702 C\n\nG4 ; wait\nM221 S100 ; reset flow\nM900 K0 ; reset LA\n{if print_settings_id=~/.*(DETAIL @MK3|QUALITY @MK3|SOLUBLE|@0.25 nozzle MK3).*/}M907 E538 ; reset extruder motor current{endif}\nM104 S0 ; turn off temperature\nM84 ; disable motors\n; max_layer_z = [max_layer_z]
|
||||||
|
|
||||||
## 0.6mm nozzle MMU2/S printer profiles
|
## 0.6mm nozzle MMU2/S printer profiles
|
||||||
@ -9966,7 +9967,7 @@ max_layer_height = 0.40
|
|||||||
min_layer_height = 0.15
|
min_layer_height = 0.15
|
||||||
printer_variant = 0.6
|
printer_variant = 0.6
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E29 F1073\nG1 X5 E29 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -9977,7 +9978,7 @@ max_layer_height = 0.40
|
|||||||
min_layer_height = 0.15
|
min_layer_height = 0.15
|
||||||
printer_variant = 0.6
|
printer_variant = 0.6
|
||||||
deretract_speed = 25
|
deretract_speed = 25
|
||||||
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55 E32 F1073\nG1 X5 E32 F1800\nG1 X55 E8 F2000\nG1 Z0.3 F1000\nG92 E0\nG1 X240 E25 F2200\nG1 Y-2 F1000\nG1 X55 E25 F1400\nG1 Z0.2 F1000\nG1 X5 E4 F1000\nG92 E0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0
|
||||||
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
default_print_profile = 0.30mm QUALITY @0.6 nozzle MK3
|
||||||
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
color_change_gcode = M600\nG1 E0.5 F1500 ; prime after color change
|
||||||
|
|
||||||
@ -10011,7 +10012,7 @@ color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
|||||||
## max_layer_height = 0.6
|
## max_layer_height = 0.6
|
||||||
## min_layer_height = 0.2
|
## min_layer_height = 0.2
|
||||||
## printer_variant = 0.8
|
## printer_variant = 0.8
|
||||||
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E32.0 F1073.0\nG1 X5.0 E32.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0.0
|
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000\nG1 Z0.4 F1000\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E32.0 F1073.0\nG1 X5.0 E32.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0.0
|
||||||
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
|
|
||||||
## [printer:Original Prusa i3 MK3S & MK3S+ MMU2S 0.8 nozzle]
|
## [printer:Original Prusa i3 MK3S & MK3S+ MMU2S 0.8 nozzle]
|
||||||
@ -10020,7 +10021,7 @@ color_change_gcode = M600\nG1 E0.3 F1500 ; prime after color change
|
|||||||
## max_layer_height = 0.6
|
## max_layer_height = 0.6
|
||||||
## min_layer_height = 0.2
|
## min_layer_height = 0.2
|
||||||
## printer_variant = 0.8
|
## printer_variant = 0.8
|
||||||
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.11.0 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0.0
|
## start_gcode = M862.3 P \"[printer_model]\" ; printer model check\nM862.1 P[nozzle_diameter] ; nozzle diameter check\nM115 U3.12.1 ; tell printer latest fw version\nG90 ; use absolute coordinates\nM83 ; extruder relative mode\nM104 S[first_layer_temperature] ; set extruder temp\nM140 S[first_layer_bed_temperature] ; set bed temp\nM190 S[first_layer_bed_temperature] ; wait for bed temp\nM109 S[first_layer_temperature] ; wait for extruder temp\nG28 W ; home all without mesh bed level\nG80 ; mesh bed leveling\n\n; Send the filament type to the MMU2.0 unit.\n; E stands for extruder number, F stands for filament type (0: default; 1:flex; 2: PVA)\nM403 E0 F{"" + ((filament_type[0]=="FLEX") ? 1 : ((filament_type[0]=="PVA") ? 2 : 0))}\nM403 E1 F{"" + ((filament_type[1]=="FLEX") ? 1 : ((filament_type[1]=="PVA") ? 2 : 0))}\nM403 E2 F{"" + ((filament_type[2]=="FLEX") ? 1 : ((filament_type[2]=="PVA") ? 2 : 0))}\nM403 E3 F{"" + ((filament_type[3]=="FLEX") ? 1 : ((filament_type[3]=="PVA") ? 2 : 0))}\nM403 E4 F{"" + ((filament_type[4]=="FLEX") ? 1 : ((filament_type[4]=="PVA") ? 2 : 0))}\n\n{if not has_single_extruder_multi_material_priming}\n;go outside print area\nG1 Y-3.0 F1000.0\nG1 Z0.4 F1000.0\n; select extruder\nT[initial_tool]\n; initial load\nG1 X55.0 E29.0 F1073.0\nG1 X5.0 E29.0 F1800.0\nG1 X55.0 E8.0 F2000.0\nG1 Z0.3 F1000.0\nG92 E0.0\nG1 X240.0 E25.0 F2200.0\nG1 Y-2.0 F1000.0\nG1 X55.0 E25 F1400.0\nG1 Z0.20 F1000.0\nG1 X5.0 E4.0 F1000.0\nG92 E0.0\n{endif}\n\nM221 S{if layer_height<0.075}100{else}95{endif}\nG92 E0.0
|
||||||
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
## default_print_profile = 0.40mm QUALITY @0.8 nozzle
|
||||||
|
|
||||||
## MINI
|
## MINI
|
||||||
|
@ -24,6 +24,9 @@ struct SlopeDetection
|
|||||||
};
|
};
|
||||||
|
|
||||||
uniform vec4 uniform_color;
|
uniform vec4 uniform_color;
|
||||||
|
uniform bool use_color_clip_plane;
|
||||||
|
uniform vec4 uniform_color_clip_plane_1;
|
||||||
|
uniform vec4 uniform_color_clip_plane_2;
|
||||||
uniform SlopeDetection slope;
|
uniform SlopeDetection slope;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
@ -34,6 +37,7 @@ uniform SlopeDetection slope;
|
|||||||
uniform PrintVolumeDetection print_volume;
|
uniform PrintVolumeDetection print_volume;
|
||||||
|
|
||||||
varying vec3 clipping_planes_dots;
|
varying vec3 clipping_planes_dots;
|
||||||
|
varying float color_clip_plane_dot;
|
||||||
|
|
||||||
// x = diffuse, y = specular;
|
// x = diffuse, y = specular;
|
||||||
varying vec2 intensity;
|
varying vec2 intensity;
|
||||||
@ -46,12 +50,18 @@ void main()
|
|||||||
{
|
{
|
||||||
if (any(lessThan(clipping_planes_dots, ZERO)))
|
if (any(lessThan(clipping_planes_dots, ZERO)))
|
||||||
discard;
|
discard;
|
||||||
vec3 color = uniform_color.rgb;
|
|
||||||
float alpha = uniform_color.a;
|
vec4 color;
|
||||||
|
if (use_color_clip_plane) {
|
||||||
|
color.rgb = (color_clip_plane_dot < 0.0) ? uniform_color_clip_plane_1.rgb : uniform_color_clip_plane_2.rgb;
|
||||||
|
color.a = uniform_color.a;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
color = uniform_color;
|
||||||
|
|
||||||
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
||||||
color = vec3(0.7, 0.7, 1.0);
|
color.rgb = vec3(0.7, 0.7, 1.0);
|
||||||
alpha = 1.0;
|
color.a = 1.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// if the fragment is outside the print volume -> use darker color
|
// if the fragment is outside the print volume -> use darker color
|
||||||
@ -68,12 +78,12 @@ void main()
|
|||||||
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
||||||
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
||||||
}
|
}
|
||||||
color = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color, ZERO, 0.3333) : color;
|
color.rgb = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color.rgb, ZERO, 0.3333) : color.rgb;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
if (use_environment_tex)
|
if (use_environment_tex)
|
||||||
gl_FragColor = vec4(0.45 * texture2D(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color * intensity.x, alpha);
|
gl_FragColor = vec4(0.45 * texture(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color.rgb * intensity.x, color.a);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
gl_FragColor = vec4(vec3(intensity.y) + color * intensity.x, alpha);
|
gl_FragColor = vec4(vec3(intensity.y) + color.rgb * intensity.x, color.a);
|
||||||
}
|
}
|
||||||
|
@ -35,6 +35,8 @@ uniform SlopeDetection slope;
|
|||||||
uniform vec2 z_range;
|
uniform vec2 z_range;
|
||||||
// Clipping plane - general orientation. Used by the SLA gizmo.
|
// Clipping plane - general orientation. Used by the SLA gizmo.
|
||||||
uniform vec4 clipping_plane;
|
uniform vec4 clipping_plane;
|
||||||
|
// Color clip plane - general orientation. Used by the cut gizmo.
|
||||||
|
uniform vec4 color_clip_plane;
|
||||||
|
|
||||||
attribute vec3 v_position;
|
attribute vec3 v_position;
|
||||||
attribute vec3 v_normal;
|
attribute vec3 v_normal;
|
||||||
@ -43,6 +45,7 @@ attribute vec3 v_normal;
|
|||||||
varying vec2 intensity;
|
varying vec2 intensity;
|
||||||
|
|
||||||
varying vec3 clipping_planes_dots;
|
varying vec3 clipping_planes_dots;
|
||||||
|
varying float color_clip_plane_dot;
|
||||||
|
|
||||||
varying vec4 world_pos;
|
varying vec4 world_pos;
|
||||||
varying float world_normal_z;
|
varying float world_normal_z;
|
||||||
@ -74,4 +77,5 @@ void main()
|
|||||||
gl_Position = projection_matrix * position;
|
gl_Position = projection_matrix * position;
|
||||||
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
||||||
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
||||||
|
color_clip_plane_dot = dot(world_pos, color_clip_plane);
|
||||||
}
|
}
|
||||||
|
@ -24,6 +24,9 @@ struct SlopeDetection
|
|||||||
};
|
};
|
||||||
|
|
||||||
uniform vec4 uniform_color;
|
uniform vec4 uniform_color;
|
||||||
|
uniform bool use_color_clip_plane;
|
||||||
|
uniform vec4 uniform_color_clip_plane_1;
|
||||||
|
uniform vec4 uniform_color_clip_plane_2;
|
||||||
uniform SlopeDetection slope;
|
uniform SlopeDetection slope;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
@ -34,6 +37,7 @@ uniform SlopeDetection slope;
|
|||||||
uniform PrintVolumeDetection print_volume;
|
uniform PrintVolumeDetection print_volume;
|
||||||
|
|
||||||
in vec3 clipping_planes_dots;
|
in vec3 clipping_planes_dots;
|
||||||
|
in float color_clip_plane_dot;
|
||||||
|
|
||||||
// x = diffuse, y = specular;
|
// x = diffuse, y = specular;
|
||||||
in vec2 intensity;
|
in vec2 intensity;
|
||||||
@ -48,12 +52,18 @@ void main()
|
|||||||
{
|
{
|
||||||
if (any(lessThan(clipping_planes_dots, ZERO)))
|
if (any(lessThan(clipping_planes_dots, ZERO)))
|
||||||
discard;
|
discard;
|
||||||
vec3 color = uniform_color.rgb;
|
|
||||||
float alpha = uniform_color.a;
|
vec4 color;
|
||||||
|
if (use_color_clip_plane) {
|
||||||
|
color.rgb = (color_clip_plane_dot < 0.0) ? uniform_color_clip_plane_1.rgb : uniform_color_clip_plane_2.rgb;
|
||||||
|
color.a = uniform_color.a;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
color = uniform_color;
|
||||||
|
|
||||||
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
||||||
color = vec3(0.7, 0.7, 1.0);
|
color.rgb = vec3(0.7, 0.7, 1.0);
|
||||||
alpha = 1.0;
|
color.a = 1.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// if the fragment is outside the print volume -> use darker color
|
// if the fragment is outside the print volume -> use darker color
|
||||||
@ -70,12 +80,12 @@ void main()
|
|||||||
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
||||||
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
||||||
}
|
}
|
||||||
color = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color, ZERO, 0.3333) : color;
|
color.rgb = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color.rgb, ZERO, 0.3333) : color.rgb;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
if (use_environment_tex)
|
if (use_environment_tex)
|
||||||
out_color = vec4(0.45 * texture(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color * intensity.x, alpha);
|
out_color = vec4(0.45 * texture(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color.rgb * intensity.x, color.a);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
out_color = vec4(vec3(intensity.y) + color * intensity.x, alpha);
|
out_color = vec4(vec3(intensity.y) + color.rgb * intensity.x, color.a);
|
||||||
}
|
}
|
||||||
|
@ -35,6 +35,8 @@ uniform SlopeDetection slope;
|
|||||||
uniform vec2 z_range;
|
uniform vec2 z_range;
|
||||||
// Clipping plane - general orientation. Used by the SLA gizmo.
|
// Clipping plane - general orientation. Used by the SLA gizmo.
|
||||||
uniform vec4 clipping_plane;
|
uniform vec4 clipping_plane;
|
||||||
|
// Color clip plane - general orientation. Used by the cut gizmo.
|
||||||
|
uniform vec4 color_clip_plane;
|
||||||
|
|
||||||
in vec3 v_position;
|
in vec3 v_position;
|
||||||
in vec3 v_normal;
|
in vec3 v_normal;
|
||||||
@ -43,6 +45,7 @@ in vec3 v_normal;
|
|||||||
out vec2 intensity;
|
out vec2 intensity;
|
||||||
|
|
||||||
out vec3 clipping_planes_dots;
|
out vec3 clipping_planes_dots;
|
||||||
|
out float color_clip_plane_dot;
|
||||||
|
|
||||||
out vec4 world_pos;
|
out vec4 world_pos;
|
||||||
out float world_normal_z;
|
out float world_normal_z;
|
||||||
@ -74,4 +77,5 @@ void main()
|
|||||||
gl_Position = projection_matrix * position;
|
gl_Position = projection_matrix * position;
|
||||||
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
||||||
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
||||||
|
color_clip_plane_dot = dot(world_pos, color_clip_plane);
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,9 @@ struct SlopeDetection
|
|||||||
};
|
};
|
||||||
|
|
||||||
uniform vec4 uniform_color;
|
uniform vec4 uniform_color;
|
||||||
|
uniform bool use_color_clip_plane;
|
||||||
|
uniform vec4 uniform_color_clip_plane_1;
|
||||||
|
uniform vec4 uniform_color_clip_plane_2;
|
||||||
uniform SlopeDetection slope;
|
uniform SlopeDetection slope;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
@ -36,6 +39,7 @@ uniform SlopeDetection slope;
|
|||||||
uniform PrintVolumeDetection print_volume;
|
uniform PrintVolumeDetection print_volume;
|
||||||
|
|
||||||
varying vec3 clipping_planes_dots;
|
varying vec3 clipping_planes_dots;
|
||||||
|
varying float color_clip_plane_dot;
|
||||||
|
|
||||||
// x = diffuse, y = specular;
|
// x = diffuse, y = specular;
|
||||||
varying vec2 intensity;
|
varying vec2 intensity;
|
||||||
@ -48,12 +52,18 @@ void main()
|
|||||||
{
|
{
|
||||||
if (any(lessThan(clipping_planes_dots, ZERO)))
|
if (any(lessThan(clipping_planes_dots, ZERO)))
|
||||||
discard;
|
discard;
|
||||||
vec3 color = uniform_color.rgb;
|
|
||||||
float alpha = uniform_color.a;
|
vec4 color;
|
||||||
|
if (use_color_clip_plane) {
|
||||||
|
color.rgb = (color_clip_plane_dot < 0.0) ? uniform_color_clip_plane_1.rgb : uniform_color_clip_plane_2.rgb;
|
||||||
|
color.a = uniform_color.a;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
color = uniform_color;
|
||||||
|
|
||||||
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
if (slope.actived && world_normal_z < slope.normal_z - EPSILON) {
|
||||||
color = vec3(0.7, 0.7, 1.0);
|
color.rgb = vec3(0.7, 0.7, 1.0);
|
||||||
alpha = 1.0;
|
color.a = 1.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// if the fragment is outside the print volume -> use darker color
|
// if the fragment is outside the print volume -> use darker color
|
||||||
@ -70,12 +80,12 @@ void main()
|
|||||||
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
pv_check_min = vec3(delta_radius, 0.0, world_pos.z - print_volume.z_data.x);
|
||||||
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
pv_check_max = vec3(0.0, 0.0, world_pos.z - print_volume.z_data.y);
|
||||||
}
|
}
|
||||||
color = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color, ZERO, 0.3333) : color;
|
color.rgb = (any(lessThan(pv_check_min, ZERO)) || any(greaterThan(pv_check_max, ZERO))) ? mix(color.rgb, ZERO, 0.3333) : color.rgb;
|
||||||
|
|
||||||
#ifdef ENABLE_ENVIRONMENT_MAP
|
#ifdef ENABLE_ENVIRONMENT_MAP
|
||||||
if (use_environment_tex)
|
if (use_environment_tex)
|
||||||
gl_FragColor = vec4(0.45 * texture2D(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color * intensity.x, alpha);
|
gl_FragColor = vec4(0.45 * texture(environment_tex, normalize(eye_normal).xy * 0.5 + 0.5).xyz + 0.8 * color.rgb * intensity.x, color.a);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
gl_FragColor = vec4(vec3(intensity.y) + color * intensity.x, alpha);
|
gl_FragColor = vec4(vec3(intensity.y) + color.rgb * intensity.x, color.a);
|
||||||
}
|
}
|
||||||
|
@ -35,6 +35,8 @@ uniform SlopeDetection slope;
|
|||||||
uniform vec2 z_range;
|
uniform vec2 z_range;
|
||||||
// Clipping plane - general orientation. Used by the SLA gizmo.
|
// Clipping plane - general orientation. Used by the SLA gizmo.
|
||||||
uniform vec4 clipping_plane;
|
uniform vec4 clipping_plane;
|
||||||
|
// Color clip plane - general orientation. Used by the cut gizmo.
|
||||||
|
uniform vec4 color_clip_plane;
|
||||||
|
|
||||||
attribute vec3 v_position;
|
attribute vec3 v_position;
|
||||||
attribute vec3 v_normal;
|
attribute vec3 v_normal;
|
||||||
@ -43,6 +45,7 @@ attribute vec3 v_normal;
|
|||||||
varying vec2 intensity;
|
varying vec2 intensity;
|
||||||
|
|
||||||
varying vec3 clipping_planes_dots;
|
varying vec3 clipping_planes_dots;
|
||||||
|
varying float color_clip_plane_dot;
|
||||||
|
|
||||||
varying vec4 world_pos;
|
varying vec4 world_pos;
|
||||||
varying float world_normal_z;
|
varying float world_normal_z;
|
||||||
@ -74,4 +77,5 @@ void main()
|
|||||||
gl_Position = projection_matrix * position;
|
gl_Position = projection_matrix * position;
|
||||||
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
// Fill in the scalars for fragment shader clipping. Fragments with any of these components lower than zero are discarded.
|
||||||
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
clipping_planes_dots = vec3(dot(world_pos, clipping_plane), world_pos.z - z_range.x, z_range.y - world_pos.z);
|
||||||
|
color_clip_plane_dot = dot(world_pos, color_clip_plane);
|
||||||
}
|
}
|
||||||
|
@ -72,6 +72,8 @@ int CLI::run(int argc, char **argv)
|
|||||||
{
|
{
|
||||||
// Mark the main thread for the debugger and for runtime checks.
|
// Mark the main thread for the debugger and for runtime checks.
|
||||||
set_current_thread_name("slic3r_main");
|
set_current_thread_name("slic3r_main");
|
||||||
|
// Save the thread ID of the main thread.
|
||||||
|
save_main_thread_id();
|
||||||
|
|
||||||
#ifdef __WXGTK__
|
#ifdef __WXGTK__
|
||||||
// On Linux, wxGTK has no support for Wayland, and the app crashes on
|
// On Linux, wxGTK has no support for Wayland, and the app crashes on
|
||||||
|
@ -108,6 +108,10 @@ inline cInt Round(double val)
|
|||||||
return static_cast<cInt>((val < 0) ? (val - 0.5) : (val + 0.5));
|
return static_cast<cInt>((val < 0) ? (val - 0.5) : (val + 0.5));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Overriding the Eigen operators because we don't want to compare Z coordinate if IntPoint is 3 dimensional.
|
||||||
|
inline bool operator==(const IntPoint &l, const IntPoint &r) { return l.x() == r.x() && l.y() == r.y(); }
|
||||||
|
inline bool operator!=(const IntPoint &l, const IntPoint &r) { return l.x() != r.x() || l.y() != r.y(); }
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// PolyTree methods ...
|
// PolyTree methods ...
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
@ -178,19 +182,25 @@ double Area(const Path &poly)
|
|||||||
}
|
}
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
double Area(const OutRec &outRec)
|
double Area(const OutPt *op)
|
||||||
{
|
{
|
||||||
OutPt *op = outRec.Pts;
|
const OutPt *startOp = op;
|
||||||
if (!op) return 0;
|
if (!op) return 0;
|
||||||
double a = 0;
|
double a = 0;
|
||||||
do {
|
do {
|
||||||
a += (double)(op->Prev->Pt.x() + op->Pt.x()) * (double)(op->Prev->Pt.y() - op->Pt.y());
|
a += (double)(op->Prev->Pt.x() + op->Pt.x()) * (double)(op->Prev->Pt.y() - op->Pt.y());
|
||||||
op = op->Next;
|
op = op->Next;
|
||||||
} while (op != outRec.Pts);
|
} while (op != startOp);
|
||||||
return a * 0.5;
|
return a * 0.5;
|
||||||
}
|
}
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
double Area(const OutRec &outRec)
|
||||||
|
{
|
||||||
|
return Area(outRec.Pts);
|
||||||
|
}
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
bool PointIsVertex(const IntPoint &Pt, OutPt *pp)
|
bool PointIsVertex(const IntPoint &Pt, OutPt *pp)
|
||||||
{
|
{
|
||||||
OutPt *pp2 = pp;
|
OutPt *pp2 = pp;
|
||||||
@ -524,27 +534,32 @@ bool FirstIsBottomPt(const OutPt* btmPt1, const OutPt* btmPt2)
|
|||||||
p = btmPt2->Next;
|
p = btmPt2->Next;
|
||||||
while ((p->Pt == btmPt2->Pt) && (p != btmPt2)) p = p->Next;
|
while ((p->Pt == btmPt2->Pt) && (p != btmPt2)) p = p->Next;
|
||||||
double dx2n = std::fabs(GetDx(btmPt2->Pt, p->Pt));
|
double dx2n = std::fabs(GetDx(btmPt2->Pt, p->Pt));
|
||||||
return (dx1p >= dx2p && dx1p >= dx2n) || (dx1n >= dx2p && dx1n >= dx2n);
|
|
||||||
|
if (std::max(dx1p, dx1n) == std::max(dx2p, dx2n) &&
|
||||||
|
std::min(dx1p, dx1n) == std::min(dx2p, dx2n))
|
||||||
|
return Area(btmPt1) > 0; //if otherwise identical use orientation
|
||||||
|
else
|
||||||
|
return (dx1p >= dx2p && dx1p >= dx2n) || (dx1n >= dx2p && dx1n >= dx2n);
|
||||||
}
|
}
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
// Called by GetLowermostRec()
|
// Called by GetLowermostRec()
|
||||||
OutPt* GetBottomPt(OutPt *pp)
|
OutPt* GetBottomPt(OutPt *pp)
|
||||||
{
|
{
|
||||||
OutPt* dups = 0;
|
OutPt* dups = nullptr;
|
||||||
OutPt* p = pp->Next;
|
OutPt* p = pp->Next;
|
||||||
while (p != pp)
|
while (p != pp)
|
||||||
{
|
{
|
||||||
if (p->Pt.y() > pp->Pt.y())
|
if (p->Pt.y() > pp->Pt.y())
|
||||||
{
|
{
|
||||||
pp = p;
|
pp = p;
|
||||||
dups = 0;
|
dups = nullptr;
|
||||||
}
|
}
|
||||||
else if (p->Pt.y() == pp->Pt.y() && p->Pt.x() <= pp->Pt.x())
|
else if (p->Pt.y() == pp->Pt.y() && p->Pt.x() <= pp->Pt.x())
|
||||||
{
|
{
|
||||||
if (p->Pt.x() < pp->Pt.x())
|
if (p->Pt.x() < pp->Pt.x())
|
||||||
{
|
{
|
||||||
dups = 0;
|
dups = nullptr;
|
||||||
pp = p;
|
pp = p;
|
||||||
} else
|
} else
|
||||||
{
|
{
|
||||||
@ -565,6 +580,7 @@ OutPt* GetBottomPt(OutPt *pp)
|
|||||||
}
|
}
|
||||||
return pp;
|
return pp;
|
||||||
}
|
}
|
||||||
|
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
bool Pt2IsBetweenPt1AndPt3(const IntPoint &pt1,
|
bool Pt2IsBetweenPt1AndPt3(const IntPoint &pt1,
|
||||||
|
@ -150,6 +150,8 @@ namespace ImGui
|
|||||||
// const wchar_t CustomSupportsMarker = 0x1D;
|
// const wchar_t CustomSupportsMarker = 0x1D;
|
||||||
// const wchar_t CustomSeamMarker = 0x1E;
|
// const wchar_t CustomSeamMarker = 0x1E;
|
||||||
// const wchar_t MmuSegmentationMarker = 0x1F;
|
// const wchar_t MmuSegmentationMarker = 0x1F;
|
||||||
|
const wchar_t PlugMarker = 0x1C;
|
||||||
|
const wchar_t DowelMarker = 0x1D;
|
||||||
// Do not forget use following letters only in wstring
|
// Do not forget use following letters only in wstring
|
||||||
const wchar_t DocumentationButton = 0x2600;
|
const wchar_t DocumentationButton = 0x2600;
|
||||||
const wchar_t DocumentationHoverButton = 0x2601;
|
const wchar_t DocumentationHoverButton = 0x2601;
|
||||||
|
@ -38,16 +38,16 @@ class AnyPtr {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
template<class TT = T, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT = T, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr(TT *p = nullptr) : ptr{p}
|
AnyPtr(TT *p = nullptr) : ptr{p}
|
||||||
{}
|
{}
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr(std::unique_ptr<TT> p) : ptr{std::unique_ptr<T>(std::move(p))}
|
AnyPtr(std::unique_ptr<TT> p) : ptr{std::unique_ptr<T>(std::move(p))}
|
||||||
{}
|
{}
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr(std::shared_ptr<TT> p) : ptr{std::shared_ptr<T>(std::move(p))}
|
AnyPtr(std::shared_ptr<TT> p) : ptr{std::shared_ptr<T>(std::move(p))}
|
||||||
{}
|
{}
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr(std::weak_ptr<TT> p) : ptr{std::weak_ptr<T>(std::move(p))}
|
AnyPtr(std::weak_ptr<TT> p) : ptr{std::weak_ptr<T>(std::move(p))}
|
||||||
{}
|
{}
|
||||||
|
|
||||||
@ -59,16 +59,16 @@ public:
|
|||||||
AnyPtr &operator=(AnyPtr &&other) noexcept { ptr = std::move(other.ptr); return *this; }
|
AnyPtr &operator=(AnyPtr &&other) noexcept { ptr = std::move(other.ptr); return *this; }
|
||||||
AnyPtr &operator=(const AnyPtr &other) = delete;
|
AnyPtr &operator=(const AnyPtr &other) = delete;
|
||||||
|
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr &operator=(TT *p) { ptr = p; return *this; }
|
AnyPtr &operator=(TT *p) { ptr = p; return *this; }
|
||||||
|
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr &operator=(std::unique_ptr<TT> p) { ptr = std::move(p); return *this; }
|
AnyPtr &operator=(std::unique_ptr<TT> p) { ptr = std::move(p); return *this; }
|
||||||
|
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr &operator=(std::shared_ptr<TT> p) { ptr = p; return *this; }
|
AnyPtr &operator=(std::shared_ptr<TT> p) { ptr = p; return *this; }
|
||||||
|
|
||||||
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT, T>>>
|
template<class TT, class = std::enable_if_t<std::is_convertible_v<TT*, T*>>>
|
||||||
AnyPtr &operator=(std::weak_ptr<TT> p) { ptr = std::move(p); return *this; }
|
AnyPtr &operator=(std::weak_ptr<TT> p) { ptr = std::move(p); return *this; }
|
||||||
|
|
||||||
const T &operator*() const { return *get_ptr(*this); }
|
const T &operator*() const { return *get_ptr(*this); }
|
||||||
|
@ -417,12 +417,8 @@ std::string AppConfig::load()
|
|||||||
|
|
||||||
void AppConfig::save()
|
void AppConfig::save()
|
||||||
{
|
{
|
||||||
{
|
if (! is_main_thread_active())
|
||||||
// Returns "undefined" if the thread naming functionality is not supported by the operating system.
|
throw CriticalException("Calling AppConfig::save() from a worker thread!");
|
||||||
std::optional<std::string> current_thread_name = get_current_thread_name();
|
|
||||||
if (current_thread_name && *current_thread_name != "slic3r_main")
|
|
||||||
throw CriticalException("Calling AppConfig::save() from a worker thread!");
|
|
||||||
}
|
|
||||||
|
|
||||||
// The config is first written to a file with a PID suffix and then moved
|
// The config is first written to a file with a PID suffix and then moved
|
||||||
// to avoid race conditions with multiple instances of Slic3r
|
// to avoid race conditions with multiple instances of Slic3r
|
||||||
@ -491,6 +487,46 @@ void AppConfig::save()
|
|||||||
m_dirty = false;
|
m_dirty = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool AppConfig::erase(const std::string §ion, const std::string &key)
|
||||||
|
{
|
||||||
|
if (auto it_storage = m_storage.find(section); it_storage != m_storage.end()) {
|
||||||
|
auto §ion = it_storage->second;
|
||||||
|
auto it = section.find(key);
|
||||||
|
if (it != section.end()) {
|
||||||
|
section.erase(it);
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool AppConfig::set_section(const std::string §ion, std::map<std::string, std::string> data)
|
||||||
|
{
|
||||||
|
auto it_section = m_storage.find(section);
|
||||||
|
if (it_section == m_storage.end()) {
|
||||||
|
if (data.empty())
|
||||||
|
return false;
|
||||||
|
it_section = m_storage.insert({ section, {} }).first;
|
||||||
|
}
|
||||||
|
auto &dst = it_section->second;
|
||||||
|
if (dst == data)
|
||||||
|
return false;
|
||||||
|
dst = std::move(data);
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool AppConfig::clear_section(const std::string §ion)
|
||||||
|
{
|
||||||
|
if (auto it_section = m_storage.find(section); it_section != m_storage.end() && ! it_section->second.empty()) {
|
||||||
|
it_section->second.clear();
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
bool AppConfig::get_variant(const std::string &vendor, const std::string &model, const std::string &variant) const
|
bool AppConfig::get_variant(const std::string &vendor, const std::string &model, const std::string &variant) const
|
||||||
{
|
{
|
||||||
const auto it_v = m_vendors.find(vendor);
|
const auto it_v = m_vendors.find(vendor);
|
||||||
@ -499,28 +535,47 @@ bool AppConfig::get_variant(const std::string &vendor, const std::string &model,
|
|||||||
return it_m == it_v->second.end() ? false : it_m->second.find(variant) != it_m->second.end();
|
return it_m == it_v->second.end() ? false : it_m->second.find(variant) != it_m->second.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::set_variant(const std::string &vendor, const std::string &model, const std::string &variant, bool enable)
|
bool AppConfig::set_variant(const std::string &vendor, const std::string &model, const std::string &variant, bool enable)
|
||||||
{
|
{
|
||||||
if (enable) {
|
if (enable) {
|
||||||
if (get_variant(vendor, model, variant)) { return; }
|
if (get_variant(vendor, model, variant))
|
||||||
|
return false;
|
||||||
m_vendors[vendor][model].insert(variant);
|
m_vendors[vendor][model].insert(variant);
|
||||||
} else {
|
} else {
|
||||||
auto it_v = m_vendors.find(vendor);
|
auto it_v = m_vendors.find(vendor);
|
||||||
if (it_v == m_vendors.end()) { return; }
|
if (it_v == m_vendors.end())
|
||||||
|
return false;
|
||||||
auto it_m = it_v->second.find(model);
|
auto it_m = it_v->second.find(model);
|
||||||
if (it_m == it_v->second.end()) { return; }
|
if (it_m == it_v->second.end())
|
||||||
|
return false;
|
||||||
auto it_var = it_m->second.find(variant);
|
auto it_var = it_m->second.find(variant);
|
||||||
if (it_var == it_m->second.end()) { return; }
|
if (it_var == it_m->second.end())
|
||||||
|
return false;
|
||||||
it_m->second.erase(it_var);
|
it_m->second.erase(it_var);
|
||||||
}
|
}
|
||||||
// If we got here, there was an update
|
// If we got here, there was an update
|
||||||
m_dirty = true;
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::set_vendors(const AppConfig &from)
|
bool AppConfig::set_vendors(const VendorMap &vendors)
|
||||||
{
|
{
|
||||||
m_vendors = from.m_vendors;
|
if (m_vendors != vendors) {
|
||||||
m_dirty = true;
|
m_vendors = vendors;
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
} else
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool AppConfig::set_vendors(VendorMap &&vendors)
|
||||||
|
{
|
||||||
|
if (m_vendors != vendors) {
|
||||||
|
m_vendors = std::move(vendors);
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
} else
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string AppConfig::get_last_dir() const
|
std::string AppConfig::get_last_dir() const
|
||||||
@ -555,34 +610,52 @@ std::vector<std::string> AppConfig::get_recent_projects() const
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::set_recent_projects(const std::vector<std::string>& recent_projects)
|
bool AppConfig::set_recent_projects(const std::vector<std::string>& recent_projects)
|
||||||
{
|
{
|
||||||
auto it = m_storage.find("recent_projects");
|
static constexpr const char *section = "recent_projects";
|
||||||
if (it == m_storage.end())
|
auto it_section = m_storage.find(section);
|
||||||
it = m_storage.insert(std::map<std::string, std::map<std::string, std::string>>::value_type("recent_projects", std::map<std::string, std::string>())).first;
|
if (it_section == m_storage.end()) {
|
||||||
|
if (recent_projects.empty())
|
||||||
it->second.clear();
|
return false;
|
||||||
for (unsigned int i = 0; i < (unsigned int)recent_projects.size(); ++i)
|
it_section = m_storage.insert({ std::string(section), {} }).first;
|
||||||
{
|
|
||||||
it->second[std::to_string(i + 1)] = recent_projects[i];
|
|
||||||
}
|
}
|
||||||
|
auto &dst = it_section->second;
|
||||||
|
|
||||||
|
std::map<std::string, std::string> src;
|
||||||
|
for (unsigned int i = 0; i < (unsigned int)recent_projects.size(); ++i)
|
||||||
|
src[std::to_string(i + 1)] = recent_projects[i];
|
||||||
|
|
||||||
|
if (src != dst) {
|
||||||
|
dst = std::move(src);
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
} else
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::set_mouse_device(const std::string& name, double translation_speed, double translation_deadzone,
|
bool AppConfig::set_mouse_device(const std::string& name, double translation_speed, double translation_deadzone,
|
||||||
float rotation_speed, float rotation_deadzone, double zoom_speed, bool swap_yz)
|
float rotation_speed, float rotation_deadzone, double zoom_speed, bool swap_yz)
|
||||||
{
|
{
|
||||||
std::string key = std::string("mouse_device:") + name;
|
const std::string key = std::string("mouse_device:") + name;
|
||||||
auto it = m_storage.find(key);
|
auto it_section = m_storage.find(key);
|
||||||
if (it == m_storage.end())
|
if (it_section == m_storage.end())
|
||||||
it = m_storage.insert(std::map<std::string, std::map<std::string, std::string>>::value_type(key, std::map<std::string, std::string>())).first;
|
it_section = m_storage.insert({ key, {} }).first;
|
||||||
|
auto &dst = it_section->second;
|
||||||
|
|
||||||
it->second.clear();
|
std::map<std::string, std::string> src;
|
||||||
it->second["translation_speed"] = float_to_string_decimal_point(translation_speed);
|
src["translation_speed"] = float_to_string_decimal_point(translation_speed);
|
||||||
it->second["translation_deadzone"] = float_to_string_decimal_point(translation_deadzone);
|
src["translation_deadzone"] = float_to_string_decimal_point(translation_deadzone);
|
||||||
it->second["rotation_speed"] = float_to_string_decimal_point(rotation_speed);
|
src["rotation_speed"] = float_to_string_decimal_point(rotation_speed);
|
||||||
it->second["rotation_deadzone"] = float_to_string_decimal_point(rotation_deadzone);
|
src["rotation_deadzone"] = float_to_string_decimal_point(rotation_deadzone);
|
||||||
it->second["zoom_speed"] = float_to_string_decimal_point(zoom_speed);
|
src["zoom_speed"] = float_to_string_decimal_point(zoom_speed);
|
||||||
it->second["swap_yz"] = swap_yz ? "1" : "0";
|
src["swap_yz"] = swap_yz ? "1" : "0";
|
||||||
|
|
||||||
|
if (src != dst) {
|
||||||
|
dst = std::move(src);
|
||||||
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
|
} else
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<std::string> AppConfig::get_mouse_device_names() const
|
std::vector<std::string> AppConfig::get_mouse_device_names() const
|
||||||
@ -596,16 +669,16 @@ std::vector<std::string> AppConfig::get_mouse_device_names() const
|
|||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::update_config_dir(const std::string &dir)
|
bool AppConfig::update_config_dir(const std::string &dir)
|
||||||
{
|
{
|
||||||
this->set("recent", "config_directory", dir);
|
return this->set("recent", "config_directory", dir);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::update_skein_dir(const std::string &dir)
|
bool AppConfig::update_skein_dir(const std::string &dir)
|
||||||
{
|
{
|
||||||
if (is_shapes_dir(dir))
|
if (is_shapes_dir(dir))
|
||||||
return; // do not save "shapes gallery" directory
|
return false; // do not save "shapes gallery" directory
|
||||||
this->set("recent", "skein_directory", dir);
|
return this->set("recent", "skein_directory", dir);
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
std::string AppConfig::get_last_output_dir(const std::string &alt) const
|
std::string AppConfig::get_last_output_dir(const std::string &alt) const
|
||||||
@ -640,9 +713,9 @@ std::string AppConfig::get_last_output_dir(const std::string& alt, const bool re
|
|||||||
return is_shapes_dir(alt) ? get_last_dir() : alt;
|
return is_shapes_dir(alt) ? get_last_dir() : alt;
|
||||||
}
|
}
|
||||||
|
|
||||||
void AppConfig::update_last_output_dir(const std::string& dir, const bool removable)
|
bool AppConfig::update_last_output_dir(const std::string& dir, const bool removable)
|
||||||
{
|
{
|
||||||
this->set("", (removable ? "last_output_path_removable" : "last_output_path"), dir);
|
return this->set("", (removable ? "last_output_path_removable" : "last_output_path"), dir);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -660,7 +733,7 @@ void AppConfig::reset_selections()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string AppConfig::config_path()
|
std::string AppConfig::config_path() const
|
||||||
{
|
{
|
||||||
std::string path = (m_mode == EAppMode::Editor) ?
|
std::string path = (m_mode == EAppMode::Editor) ?
|
||||||
(boost::filesystem::path(Slic3r::data_dir()) / (SLIC3R_APP_KEY ".ini")).make_preferred().string() :
|
(boost::filesystem::path(Slic3r::data_dir()) / (SLIC3R_APP_KEY ".ini")).make_preferred().string() :
|
||||||
@ -695,7 +768,7 @@ std::string AppConfig::profile_folder_url() const
|
|||||||
return PROFILE_FOLDER_URL;
|
return PROFILE_FOLDER_URL;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool AppConfig::exists()
|
bool AppConfig::exists() const
|
||||||
{
|
{
|
||||||
return boost::filesystem::exists(config_path());
|
return boost::filesystem::exists(config_path());
|
||||||
}
|
}
|
||||||
|
@ -58,9 +58,13 @@ public:
|
|||||||
}
|
}
|
||||||
std::string get(const std::string §ion, const std::string &key) const
|
std::string get(const std::string §ion, const std::string &key) const
|
||||||
{ std::string value; this->get(section, key, value); return value; }
|
{ std::string value; this->get(section, key, value); return value; }
|
||||||
|
bool get_bool(const std::string §ion, const std::string &key) const
|
||||||
|
{ return this->get(section, key) == "1"; }
|
||||||
std::string get(const std::string &key) const
|
std::string get(const std::string &key) const
|
||||||
{ std::string value; this->get("", key, value); return value; }
|
{ std::string value; this->get("", key, value); return value; }
|
||||||
void set(const std::string §ion, const std::string &key, const std::string &value)
|
bool get_bool(const std::string &key) const
|
||||||
|
{ return this->get(key) == "1"; }
|
||||||
|
bool set(const std::string §ion, const std::string &key, const std::string &value)
|
||||||
{
|
{
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
{
|
{
|
||||||
@ -74,10 +78,12 @@ public:
|
|||||||
if (old != value) {
|
if (old != value) {
|
||||||
old = value;
|
old = value;
|
||||||
m_dirty = true;
|
m_dirty = true;
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
void set(const std::string &key, const std::string &value)
|
bool set(const std::string &key, const std::string &value)
|
||||||
{ this->set("", key, value); }
|
{ return this->set("", key, value); }
|
||||||
bool has(const std::string §ion, const std::string &key) const
|
bool has(const std::string §ion, const std::string &key) const
|
||||||
{
|
{
|
||||||
auto it = m_storage.find(section);
|
auto it = m_storage.find(section);
|
||||||
@ -89,40 +95,32 @@ public:
|
|||||||
bool has(const std::string &key) const
|
bool has(const std::string &key) const
|
||||||
{ return this->has("", key); }
|
{ return this->has("", key); }
|
||||||
|
|
||||||
void erase(const std::string §ion, const std::string &key)
|
bool erase(const std::string §ion, const std::string &key);
|
||||||
{
|
|
||||||
auto it = m_storage.find(section);
|
|
||||||
if (it != m_storage.end()) {
|
|
||||||
it->second.erase(key);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
bool has_section(const std::string §ion) const
|
bool has_section(const std::string §ion) const
|
||||||
{ return m_storage.find(section) != m_storage.end(); }
|
{ return m_storage.find(section) != m_storage.end(); }
|
||||||
const std::map<std::string, std::string>& get_section(const std::string §ion) const
|
const std::map<std::string, std::string>& get_section(const std::string §ion) const
|
||||||
{ auto it = m_storage.find(section); assert(it != m_storage.end()); return it->second; }
|
{ auto it = m_storage.find(section); assert(it != m_storage.end()); return it->second; }
|
||||||
void set_section(const std::string §ion, const std::map<std::string, std::string>& data)
|
bool set_section(const std::string §ion, std::map<std::string, std::string> data);
|
||||||
{ m_storage[section] = data; }
|
bool clear_section(const std::string §ion);
|
||||||
void clear_section(const std::string §ion)
|
|
||||||
{ m_storage[section].clear(); }
|
|
||||||
|
|
||||||
typedef std::map<std::string, std::map<std::string, std::set<std::string>>> VendorMap;
|
typedef std::map<std::string, std::map<std::string, std::set<std::string>>> VendorMap;
|
||||||
bool get_variant(const std::string &vendor, const std::string &model, const std::string &variant) const;
|
bool get_variant(const std::string &vendor, const std::string &model, const std::string &variant) const;
|
||||||
void set_variant(const std::string &vendor, const std::string &model, const std::string &variant, bool enable);
|
bool set_variant(const std::string &vendor, const std::string &model, const std::string &variant, bool enable);
|
||||||
void set_vendors(const AppConfig &from);
|
bool set_vendors(const AppConfig &from) { return this->set_vendors(from.vendors()); }
|
||||||
void set_vendors(const VendorMap &vendors) { m_vendors = vendors; m_dirty = true; }
|
bool set_vendors(const VendorMap &vendors);
|
||||||
void set_vendors(VendorMap &&vendors) { m_vendors = std::move(vendors); m_dirty = true; }
|
bool set_vendors(VendorMap &&vendors);
|
||||||
const VendorMap& vendors() const { return m_vendors; }
|
const VendorMap& vendors() const { return m_vendors; }
|
||||||
|
|
||||||
// return recent/skein_directory or recent/config_directory or empty string.
|
// return recent/skein_directory or recent/config_directory or empty string.
|
||||||
std::string get_last_dir() const;
|
std::string get_last_dir() const;
|
||||||
void update_config_dir(const std::string &dir);
|
bool update_config_dir(const std::string &dir);
|
||||||
void update_skein_dir(const std::string &dir);
|
bool update_skein_dir(const std::string &dir);
|
||||||
|
|
||||||
//std::string get_last_output_dir(const std::string &alt) const;
|
//std::string get_last_output_dir(const std::string &alt) const;
|
||||||
//void update_last_output_dir(const std::string &dir);
|
//void update_last_output_dir(const std::string &dir);
|
||||||
std::string get_last_output_dir(const std::string& alt, const bool removable = false) const;
|
std::string get_last_output_dir(const std::string& alt, const bool removable = false) const;
|
||||||
void update_last_output_dir(const std::string &dir, const bool removable = false);
|
bool update_last_output_dir(const std::string &dir, const bool removable = false);
|
||||||
|
|
||||||
// reset the current print / filament / printer selections, so that
|
// reset the current print / filament / printer selections, so that
|
||||||
// the PresetBundle::load_selections(const AppConfig &config) call will select
|
// the PresetBundle::load_selections(const AppConfig &config) call will select
|
||||||
@ -130,7 +128,7 @@ public:
|
|||||||
void reset_selections();
|
void reset_selections();
|
||||||
|
|
||||||
// Get the default config path from Slic3r::data_dir().
|
// Get the default config path from Slic3r::data_dir().
|
||||||
std::string config_path();
|
std::string config_path() const;
|
||||||
|
|
||||||
// Returns true if the user's data directory comes from before Slic3r 1.40.0 (no updating)
|
// Returns true if the user's data directory comes from before Slic3r 1.40.0 (no updating)
|
||||||
bool legacy_datadir() const { return m_legacy_datadir; }
|
bool legacy_datadir() const { return m_legacy_datadir; }
|
||||||
@ -140,9 +138,9 @@ public:
|
|||||||
// This returns a hardcoded string unless it is overriden by "version_check_url" in the ini file.
|
// This returns a hardcoded string unless it is overriden by "version_check_url" in the ini file.
|
||||||
std::string version_check_url() const;
|
std::string version_check_url() const;
|
||||||
// Get the Slic3r url to vendor index archive zip.
|
// Get the Slic3r url to vendor index archive zip.
|
||||||
std::string index_archive_url() const;
|
std::string index_archive_url() const;
|
||||||
// Get the Slic3r url to folder with vendor profile files.
|
// Get the Slic3r url to folder with vendor profile files.
|
||||||
std::string profile_folder_url() const;
|
std::string profile_folder_url() const;
|
||||||
|
|
||||||
|
|
||||||
// Returns the original Slic3r version found in the ini file before it was overwritten
|
// Returns the original Slic3r version found in the ini file before it was overwritten
|
||||||
@ -150,12 +148,12 @@ public:
|
|||||||
Semver orig_version() const { return m_orig_version; }
|
Semver orig_version() const { return m_orig_version; }
|
||||||
|
|
||||||
// Does the config file exist?
|
// Does the config file exist?
|
||||||
bool exists();
|
bool exists() const;
|
||||||
|
|
||||||
std::vector<std::string> get_recent_projects() const;
|
std::vector<std::string> get_recent_projects() const;
|
||||||
void set_recent_projects(const std::vector<std::string>& recent_projects);
|
bool set_recent_projects(const std::vector<std::string>& recent_projects);
|
||||||
|
|
||||||
void set_mouse_device(const std::string& name, double translation_speed, double translation_deadzone, float rotation_speed, float rotation_deadzone, double zoom_speed, bool swap_yz);
|
bool set_mouse_device(const std::string& name, double translation_speed, double translation_deadzone, float rotation_speed, float rotation_deadzone, double zoom_speed, bool swap_yz);
|
||||||
std::vector<std::string> get_mouse_device_names() const;
|
std::vector<std::string> get_mouse_device_names() const;
|
||||||
bool get_mouse_device_translation_speed(const std::string& name, double& speed) const
|
bool get_mouse_device_translation_speed(const std::string& name, double& speed) const
|
||||||
{ return get_3dmouse_device_numeric_value(name, "translation_speed", speed); }
|
{ return get_3dmouse_device_numeric_value(name, "translation_speed", speed); }
|
||||||
|
@ -26,7 +26,6 @@ MeshBoolean::cgal::CGALMeshPtr get_cgalmesh(const CSGPartT &csgpart)
|
|||||||
MeshBoolean::cgal::CGALMeshPtr ret;
|
MeshBoolean::cgal::CGALMeshPtr ret;
|
||||||
|
|
||||||
indexed_triangle_set m = *its;
|
indexed_triangle_set m = *its;
|
||||||
auto tr = get_transform(csgpart);
|
|
||||||
its_transform(m, get_transform(csgpart), true);
|
its_transform(m, get_transform(csgpart), true);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -364,6 +364,8 @@ inline Slic3r::Polygons expand(const Slic3r::Polygon &polygon, const float del
|
|||||||
{ assert(delta > 0); return offset(polygon, delta, joinType, miterLimit); }
|
{ assert(delta > 0); return offset(polygon, delta, joinType, miterLimit); }
|
||||||
inline Slic3r::Polygons expand(const Slic3r::Polygons &polygons, const float delta, ClipperLib::JoinType joinType = DefaultJoinType, double miterLimit = DefaultMiterLimit)
|
inline Slic3r::Polygons expand(const Slic3r::Polygons &polygons, const float delta, ClipperLib::JoinType joinType = DefaultJoinType, double miterLimit = DefaultMiterLimit)
|
||||||
{ assert(delta > 0); return offset(polygons, delta, joinType, miterLimit); }
|
{ assert(delta > 0); return offset(polygons, delta, joinType, miterLimit); }
|
||||||
|
inline Slic3r::Polygons expand(const Slic3r::ExPolygons &polygons, const float delta, ClipperLib::JoinType joinType = DefaultJoinType, double miterLimit = DefaultMiterLimit)
|
||||||
|
{ assert(delta > 0); return offset(polygons, delta, joinType, miterLimit); }
|
||||||
inline Slic3r::ExPolygons expand_ex(const Slic3r::Polygons &polygons, const float delta, ClipperLib::JoinType joinType = DefaultJoinType, double miterLimit = DefaultMiterLimit)
|
inline Slic3r::ExPolygons expand_ex(const Slic3r::Polygons &polygons, const float delta, ClipperLib::JoinType joinType = DefaultJoinType, double miterLimit = DefaultMiterLimit)
|
||||||
{ assert(delta > 0); return offset_ex(polygons, delta, joinType, miterLimit); }
|
{ assert(delta > 0); return offset_ex(polygons, delta, joinType, miterLimit); }
|
||||||
// Input polygons for shrinking shall be "normalized": There must be no overlap / intersections between the input polygons.
|
// Input polygons for shrinking shall be "normalized": There must be no overlap / intersections between the input polygons.
|
||||||
|
@ -268,7 +268,7 @@ ConfigOption* ConfigOptionDef::create_empty_option() const
|
|||||||
// case coPoint3s: return new ConfigOptionPoint3s();
|
// case coPoint3s: return new ConfigOptionPoint3s();
|
||||||
case coBool: return new ConfigOptionBool();
|
case coBool: return new ConfigOptionBool();
|
||||||
case coBools: return new ConfigOptionBools();
|
case coBools: return new ConfigOptionBools();
|
||||||
case coEnum: return new ConfigOptionEnumGeneric(this->enum_keys_map);
|
case coEnum: return new ConfigOptionEnumGeneric(this->enum_def->m_enum_keys_map);
|
||||||
default: throw ConfigurationError(std::string("Unknown option type for option ") + this->label);
|
default: throw ConfigurationError(std::string("Unknown option type for option ") + this->label);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -279,7 +279,7 @@ ConfigOption* ConfigOptionDef::create_default_option() const
|
|||||||
if (this->default_value)
|
if (this->default_value)
|
||||||
return (this->default_value->type() == coEnum) ?
|
return (this->default_value->type() == coEnum) ?
|
||||||
// Special case: For a DynamicConfig, convert a templated enum to a generic enum.
|
// Special case: For a DynamicConfig, convert a templated enum to a generic enum.
|
||||||
new ConfigOptionEnumGeneric(this->enum_keys_map, this->default_value->getInt()) :
|
new ConfigOptionEnumGeneric(this->enum_def->m_enum_keys_map, this->default_value->getInt()) :
|
||||||
this->default_value->clone();
|
this->default_value->clone();
|
||||||
return this->create_empty_option();
|
return this->create_empty_option();
|
||||||
}
|
}
|
||||||
@ -303,6 +303,31 @@ ConfigOptionDef* ConfigDef::add_nullable(const t_config_option_key &opt_key, Con
|
|||||||
return def;
|
return def;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ConfigDef::finalize()
|
||||||
|
{
|
||||||
|
// Validate & finalize open & closed enums.
|
||||||
|
for (std::pair<const t_config_option_key, ConfigOptionDef> &kvp : options) {
|
||||||
|
ConfigOptionDef& def = kvp.second;
|
||||||
|
if (def.type == coEnum) {
|
||||||
|
assert(def.enum_def);
|
||||||
|
assert(def.enum_def->is_valid_closed_enum());
|
||||||
|
assert(def.gui_type != ConfigOptionDef::GUIType::i_enum_open &&
|
||||||
|
def.gui_type != ConfigOptionDef::GUIType::f_enum_open &&
|
||||||
|
def.gui_type != ConfigOptionDef::GUIType::select_open);
|
||||||
|
def.enum_def->finalize_closed_enum();
|
||||||
|
} else if (def.gui_type == ConfigOptionDef::GUIType::i_enum_open || def.gui_type == ConfigOptionDef::GUIType::f_enum_open ||
|
||||||
|
def.gui_type == ConfigOptionDef::GUIType::select_open) {
|
||||||
|
assert(def.enum_def);
|
||||||
|
assert(def.enum_def->is_valid_open_enum());
|
||||||
|
assert(def.gui_type != ConfigOptionDef::GUIType::i_enum_open || def.type == coInt || def.type == coInts);
|
||||||
|
assert(def.gui_type != ConfigOptionDef::GUIType::f_enum_open || def.type == coFloat || def.type == coPercent || def.type == coFloatOrPercent);
|
||||||
|
assert(def.gui_type != ConfigOptionDef::GUIType::select_open || def.type == coString || def.type == coStrings);
|
||||||
|
} else {
|
||||||
|
assert(! def.enum_def);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
std::ostream& ConfigDef::print_cli_help(std::ostream& out, bool show_defaults, std::function<bool(const ConfigOptionDef &)> filter) const
|
std::ostream& ConfigDef::print_cli_help(std::ostream& out, bool show_defaults, std::function<bool(const ConfigOptionDef &)> filter) const
|
||||||
{
|
{
|
||||||
// prepare a function for wrapping text
|
// prepare a function for wrapping text
|
||||||
@ -378,8 +403,8 @@ std::ostream& ConfigDef::print_cli_help(std::ostream& out, bool show_defaults, s
|
|||||||
descr += " (";
|
descr += " (";
|
||||||
if (!def.sidetext.empty()) {
|
if (!def.sidetext.empty()) {
|
||||||
descr += def.sidetext + ", ";
|
descr += def.sidetext + ", ";
|
||||||
} else if (!def.enum_values.empty()) {
|
} else if (def.enum_def->has_values()) {
|
||||||
descr += boost::algorithm::join(def.enum_values, ", ") + "; ";
|
descr += boost::algorithm::join(def.enum_def->values(), ", ") + "; ";
|
||||||
}
|
}
|
||||||
descr += "default: " + def.default_value->serialize() + ")";
|
descr += "default: " + def.default_value->serialize() + ")";
|
||||||
}
|
}
|
||||||
@ -1142,7 +1167,7 @@ bool DynamicConfig::read_cli(int argc, const char* const argv[], t_config_option
|
|||||||
}
|
}
|
||||||
|
|
||||||
const t_config_option_key &opt_key = it->second;
|
const t_config_option_key &opt_key = it->second;
|
||||||
const ConfigOptionDef &optdef = this->def()->options.at(opt_key);
|
const ConfigOptionDef &optdef = *this->option_def(opt_key);
|
||||||
|
|
||||||
// If the option type expects a value and it was not already provided,
|
// If the option type expects a value and it was not already provided,
|
||||||
// look for it in the next token.
|
// look for it in the next token.
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
#include <stdexcept>
|
#include <stdexcept>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <string_view>
|
#include <string_view>
|
||||||
|
#include <type_traits>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
#include <float.h>
|
#include <float.h>
|
||||||
#include "libslic3r.h"
|
#include "libslic3r.h"
|
||||||
@ -226,6 +227,7 @@ enum ForwardCompatibilitySubstitutionRule
|
|||||||
EnableSilentDisableSystem,
|
EnableSilentDisableSystem,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class ConfigDef;
|
||||||
class ConfigOption;
|
class ConfigOption;
|
||||||
class ConfigOptionDef;
|
class ConfigOptionDef;
|
||||||
// For forward definition of ConfigOption in ConfigOptionUniquePtr, we have to define a custom deleter.
|
// For forward definition of ConfigOption in ConfigOptionUniquePtr, we have to define a custom deleter.
|
||||||
@ -1547,7 +1549,7 @@ public:
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Map from an enum name to an enum integer value.
|
// Map from an enum integer value to name.
|
||||||
static const t_config_enum_names& get_enum_names();
|
static const t_config_enum_names& get_enum_names();
|
||||||
// Map from an enum name to an enum integer value.
|
// Map from an enum name to an enum integer value.
|
||||||
static const t_config_enum_values& get_enum_values();
|
static const t_config_enum_values& get_enum_values();
|
||||||
@ -1619,6 +1621,177 @@ private:
|
|||||||
template<class Archive> void serialize(Archive& ar) { ar(cereal::base_class<ConfigOptionInt>(this)); }
|
template<class Archive> void serialize(Archive& ar) { ar(cereal::base_class<ConfigOptionInt>(this)); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// Definition of values / labels for a combo box.
|
||||||
|
// Mostly used for closed enums (when type == coEnum), but may be used for
|
||||||
|
// open enums with ints resp. floats, if gui_type is set to GUIType::i_enum_open" resp. GUIType::f_enum_open.
|
||||||
|
class ConfigOptionEnumDef {
|
||||||
|
public:
|
||||||
|
bool has_values() const { return ! m_values.empty(); }
|
||||||
|
bool has_labels() const { return ! m_labels.empty(); }
|
||||||
|
const std::vector<std::string>& values() const { return m_values; }
|
||||||
|
const std::string& value(int idx) const { return m_values[idx]; }
|
||||||
|
// Used for open enums (gui_type is set to GUIType::i_enum_open" resp. GUIType::f_enum_open).
|
||||||
|
// If values not defined, use labels.
|
||||||
|
const std::vector<std::string>& enums() const {
|
||||||
|
assert(this->is_valid_open_enum());
|
||||||
|
return this->has_values() ? m_values : m_labels;
|
||||||
|
}
|
||||||
|
// Used for closed enums. If labels are not defined, use values instead.
|
||||||
|
const std::vector<std::string>& labels() const { return this->has_labels() ? m_labels : m_values; }
|
||||||
|
const std::string& label(int idx) const { return this->labels()[idx]; }
|
||||||
|
|
||||||
|
// Look up a closed enum value of this combo box based on an index of the combo box value / label.
|
||||||
|
// Such a mapping should always succeed.
|
||||||
|
int index_to_enum(int index) const {
|
||||||
|
// It has to be a closed enum, thus values have to be defined.
|
||||||
|
assert(this->is_valid_closed_enum());
|
||||||
|
assert(index >= 0 && index < int(m_values.size()));
|
||||||
|
if (m_values_ordinary)
|
||||||
|
return index;
|
||||||
|
else {
|
||||||
|
auto it = m_enum_keys_map->find(m_values[index]);
|
||||||
|
assert(it != m_enum_keys_map->end());
|
||||||
|
return it->second;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Look up an index of value / label of this combo box based on enum value.
|
||||||
|
// Such a mapping may fail, thus an optional is returned.
|
||||||
|
std::optional<int> enum_to_index(int enum_val) const {
|
||||||
|
assert(this->is_valid_closed_enum());
|
||||||
|
assert(enum_val >= 0 && enum_val < int(m_enum_names->size()));
|
||||||
|
if (m_values_ordinary)
|
||||||
|
return { enum_val };
|
||||||
|
else {
|
||||||
|
auto it = std::find(m_values.begin(), m_values.end(), (*m_enum_names)[enum_val]);
|
||||||
|
return it == m_values.end() ? std::optional<int>{} : std::optional<int>{ int(it - m_values.begin()) };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Look up an index of value / label of this combo box based on value string.
|
||||||
|
std::optional<int> value_to_index(const std::string &value) const {
|
||||||
|
assert(this->is_valid_open_enum() || this->is_valid_closed_enum());
|
||||||
|
auto it = std::find(m_values.begin(), m_values.end(), value);
|
||||||
|
return it == m_values.end() ?
|
||||||
|
std::optional<int>{} : std::optional<int>{ it - m_values.begin() };
|
||||||
|
}
|
||||||
|
|
||||||
|
// Look up an index of label of this combo box. Used for open enums.
|
||||||
|
std::optional<int> label_to_index(const std::string &value) const {
|
||||||
|
assert(is_valid_open_enum());
|
||||||
|
const auto &ls = this->labels();
|
||||||
|
auto it = std::find(ls.begin(), ls.end(), value);
|
||||||
|
return it == ls.end() ?
|
||||||
|
std::optional<int>{} : std::optional<int>{ it - ls.begin() };
|
||||||
|
}
|
||||||
|
|
||||||
|
std::optional<std::reference_wrapper<const std::string>> enum_to_value(int enum_val) const {
|
||||||
|
assert(this->is_valid_closed_enum());
|
||||||
|
auto opt = this->enum_to_index(enum_val);
|
||||||
|
return opt.has_value() ?
|
||||||
|
std::optional<std::reference_wrapper<const std::string>>{ this->value(*opt) } :
|
||||||
|
std::optional<std::reference_wrapper<const std::string>>{};
|
||||||
|
}
|
||||||
|
|
||||||
|
std::optional<std::reference_wrapper<const std::string>> enum_to_label(int enum_val) const {
|
||||||
|
assert(this->is_valid_closed_enum());
|
||||||
|
auto opt = this->enum_to_index(enum_val);
|
||||||
|
return opt.has_value() ?
|
||||||
|
std::optional<std::reference_wrapper<const std::string>>{ this->label(*opt) } :
|
||||||
|
std::optional<std::reference_wrapper<const std::string>>{};
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifndef NDEBUG
|
||||||
|
bool is_valid_closed_enum() const {
|
||||||
|
return m_enum_names != nullptr && m_enum_keys_map != nullptr &&
|
||||||
|
! m_values.empty() && (m_labels.empty() || m_values.size() == m_labels.size());
|
||||||
|
}
|
||||||
|
bool is_valid_open_enum() const {
|
||||||
|
return m_enum_names == nullptr && m_enum_keys_map == nullptr &&
|
||||||
|
(! m_values.empty() || ! m_labels.empty()) && (m_values.empty() || m_labels.empty() || m_values.size() == m_labels.size());
|
||||||
|
}
|
||||||
|
#endif // NDEBUG
|
||||||
|
|
||||||
|
void clear() {
|
||||||
|
m_values_ordinary = false;
|
||||||
|
m_enum_names = nullptr;
|
||||||
|
m_enum_keys_map = nullptr;
|
||||||
|
m_values.clear();
|
||||||
|
m_labels.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
ConfigOptionEnumDef* clone() const { return new ConfigOptionEnumDef{ *this }; }
|
||||||
|
|
||||||
|
private:
|
||||||
|
friend ConfigDef;
|
||||||
|
friend ConfigOptionDef;
|
||||||
|
|
||||||
|
// Only allow ConfigOptionEnumDef() to be created from ConfigOptionDef.
|
||||||
|
ConfigOptionEnumDef() = default;
|
||||||
|
|
||||||
|
void set_values(const std::vector<std::string> &v) {
|
||||||
|
m_values = v;
|
||||||
|
assert(m_labels.empty() || m_labels.size() == m_values.size());
|
||||||
|
}
|
||||||
|
void set_values(const std::initializer_list<std::string_view> il) {
|
||||||
|
m_values.clear();
|
||||||
|
m_values.reserve(il.size());
|
||||||
|
for (const std::string_view p : il)
|
||||||
|
m_values.emplace_back(p);
|
||||||
|
assert(m_labels.empty() || m_labels.size() == m_values.size());
|
||||||
|
}
|
||||||
|
void set_values(const std::initializer_list<std::pair<std::string_view, std::string_view>> il) {
|
||||||
|
m_values.clear();
|
||||||
|
m_values.reserve(il.size());
|
||||||
|
m_labels.clear();
|
||||||
|
m_labels.reserve(il.size());
|
||||||
|
for (const std::pair<std::string_view, std::string_view> p : il) {
|
||||||
|
m_values.emplace_back(p.first);
|
||||||
|
m_labels.emplace_back(p.second);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
void set_labels(const std::initializer_list<std::string_view> il) {
|
||||||
|
m_labels.clear();
|
||||||
|
m_labels.reserve(il.size());
|
||||||
|
for (const std::string_view p : il)
|
||||||
|
m_labels.emplace_back(p);
|
||||||
|
assert(m_values.empty() || m_labels.size() == m_values.size());
|
||||||
|
}
|
||||||
|
void finalize_closed_enum() {
|
||||||
|
assert(this->is_valid_closed_enum());
|
||||||
|
// Check whether def.enum_values contains all the values of def.enum_keys_map and
|
||||||
|
// that they are sorted by their ordinary values.
|
||||||
|
m_values_ordinary = true;
|
||||||
|
for (const std::pair<std::string, int>& key : *m_enum_keys_map) {
|
||||||
|
assert(key.second >= 0);
|
||||||
|
if (key.second >= this->values().size() || this->value(key.second) != key.first) {
|
||||||
|
m_values_ordinary = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> m_values;
|
||||||
|
std::vector<std::string> m_labels;
|
||||||
|
// If true, then enum_values are sorted and they contain all the values, thus the UI element ordinary
|
||||||
|
// to enum value could be converted directly.
|
||||||
|
bool m_values_ordinary { false };
|
||||||
|
|
||||||
|
template<typename EnumType>
|
||||||
|
void set_enum_map()
|
||||||
|
{
|
||||||
|
m_enum_names = &ConfigOptionEnum<EnumType>::get_enum_names();
|
||||||
|
m_enum_keys_map = &ConfigOptionEnum<EnumType>::get_enum_values();
|
||||||
|
}
|
||||||
|
|
||||||
|
// For enums (when type == coEnum). Maps enums to enum names.
|
||||||
|
// Initialized by ConfigOptionEnum<xxx>::get_enum_names()
|
||||||
|
const t_config_enum_names* m_enum_names{ nullptr };
|
||||||
|
// For enums (when type == coEnum). Maps enum_values to enums.
|
||||||
|
// Initialized by ConfigOptionEnum<xxx>::get_enum_values()
|
||||||
|
const t_config_enum_values* m_enum_keys_map{ nullptr };
|
||||||
|
};
|
||||||
|
|
||||||
// Definition of a configuration value for the purpose of GUI presentation, editing, value mapping and config file handling.
|
// Definition of a configuration value for the purpose of GUI presentation, editing, value mapping and config file handling.
|
||||||
class ConfigOptionDef
|
class ConfigOptionDef
|
||||||
{
|
{
|
||||||
@ -1629,16 +1802,18 @@ public:
|
|||||||
i_enum_open,
|
i_enum_open,
|
||||||
// Open enums, float value could be one of the enumerated values or something else.
|
// Open enums, float value could be one of the enumerated values or something else.
|
||||||
f_enum_open,
|
f_enum_open,
|
||||||
|
// Open enums, string value could be one of the enumerated values or something else.
|
||||||
|
select_open,
|
||||||
// Color picker, string value.
|
// Color picker, string value.
|
||||||
color,
|
color,
|
||||||
// ???
|
|
||||||
select_open,
|
|
||||||
// Currently unused.
|
// Currently unused.
|
||||||
slider,
|
slider,
|
||||||
// Static text
|
// Static text
|
||||||
legend,
|
legend,
|
||||||
// Vector value, but edited as a single string.
|
// Vector value, but edited as a single string.
|
||||||
one_string,
|
one_string,
|
||||||
|
// Close parameter, string value could be one of the list values.
|
||||||
|
select_close,
|
||||||
};
|
};
|
||||||
|
|
||||||
// Identifier of this option. It is stored here so that it is accessible through the by_serialization_key_ordinal map.
|
// Identifier of this option. It is stored here so that it is accessible through the by_serialization_key_ordinal map.
|
||||||
@ -1683,7 +1858,7 @@ public:
|
|||||||
case coPoint3: { auto opt = new ConfigOptionPoint3(); archive(*opt); return opt; }
|
case coPoint3: { auto opt = new ConfigOptionPoint3(); archive(*opt); return opt; }
|
||||||
case coBool: { auto opt = new ConfigOptionBool(); archive(*opt); return opt; }
|
case coBool: { auto opt = new ConfigOptionBool(); archive(*opt); return opt; }
|
||||||
case coBools: { auto opt = new ConfigOptionBools(); archive(*opt); return opt; }
|
case coBools: { auto opt = new ConfigOptionBools(); archive(*opt); return opt; }
|
||||||
case coEnum: { auto opt = new ConfigOptionEnumGeneric(this->enum_keys_map); archive(*opt); return opt; }
|
case coEnum: { auto opt = new ConfigOptionEnumGeneric(this->enum_def->m_enum_keys_map); archive(*opt); return opt; }
|
||||||
default: throw ConfigurationError(std::string("ConfigOptionDef::load_option_from_archive(): Unknown option type for option ") + this->opt_key);
|
default: throw ConfigurationError(std::string("ConfigOptionDef::load_option_from_archive(): Unknown option type for option ") + this->opt_key);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1780,30 +1955,73 @@ public:
|
|||||||
// Sometimes a single value may well define multiple values in a "beginner" mode.
|
// Sometimes a single value may well define multiple values in a "beginner" mode.
|
||||||
// Currently used for aliasing "solid_layers" to "top_solid_layers", "bottom_solid_layers".
|
// Currently used for aliasing "solid_layers" to "top_solid_layers", "bottom_solid_layers".
|
||||||
std::vector<t_config_option_key> shortcut;
|
std::vector<t_config_option_key> shortcut;
|
||||||
// Definition of values / labels for a combo box.
|
|
||||||
// Mostly used for enums (when type == coEnum), but may be used for ints resp. floats, if gui_type is set to "i_enum_open" resp. "f_enum_open".
|
|
||||||
std::vector<std::string> enum_values;
|
|
||||||
std::vector<std::string> enum_labels;
|
|
||||||
// For enums (when type == coEnum). Maps enum_values to enums.
|
|
||||||
// Initialized by ConfigOptionEnum<xxx>::get_enum_values()
|
|
||||||
const t_config_enum_values *enum_keys_map = nullptr;
|
|
||||||
|
|
||||||
void set_enum_values(std::initializer_list<std::pair<std::string_view, std::string_view>> il) {
|
Slic3r::clonable_ptr<ConfigOptionEnumDef> enum_def;
|
||||||
enum_values.clear();
|
|
||||||
enum_values.reserve(il.size());
|
void set_enum_values(const std::initializer_list<std::string_view> il) {
|
||||||
enum_labels.clear();
|
this->enum_def_new();
|
||||||
enum_labels.reserve(il.size());
|
enum_def->set_values(il);
|
||||||
for (const std::pair<std::string_view, std::string_view> &p : il) {
|
}
|
||||||
enum_values.emplace_back(p.first);
|
|
||||||
enum_labels.emplace_back(p.second);
|
void set_enum_values(GUIType gui_type, const std::initializer_list<std::string_view> il) {
|
||||||
}
|
this->enum_def_new();
|
||||||
|
assert(gui_type == GUIType::i_enum_open || gui_type == GUIType::f_enum_open || gui_type == GUIType::select_open);
|
||||||
|
this->gui_type = gui_type;
|
||||||
|
enum_def->set_values(il);
|
||||||
|
}
|
||||||
|
|
||||||
|
void set_enum_values(const std::initializer_list<std::pair<std::string_view, std::string_view>> il) {
|
||||||
|
this->enum_def_new();
|
||||||
|
enum_def->set_values(il);
|
||||||
|
}
|
||||||
|
|
||||||
|
void set_enum_values(GUIType gui_type, const std::initializer_list<std::pair<std::string_view, std::string_view>> il) {
|
||||||
|
this->enum_def_new();
|
||||||
|
assert(gui_type == GUIType::i_enum_open || gui_type == GUIType::f_enum_open);
|
||||||
|
this->gui_type = gui_type;
|
||||||
|
enum_def->set_values(il);
|
||||||
|
}
|
||||||
|
|
||||||
|
template<typename Values, typename Labels>
|
||||||
|
void set_enum_values(Values &&values, Labels &&labels) {
|
||||||
|
this->enum_def_new();
|
||||||
|
enum_def->set_values(std::move(values));
|
||||||
|
enum_def->set_labels(std::move(labels));
|
||||||
|
}
|
||||||
|
|
||||||
|
void set_enum_labels(GUIType gui_type, const std::initializer_list<std::string_view> il) {
|
||||||
|
this->enum_def_new();
|
||||||
|
assert(gui_type == GUIType::i_enum_open || gui_type == GUIType::f_enum_open || gui_type == ConfigOptionDef::GUIType::select_open);
|
||||||
|
this->gui_type = gui_type;
|
||||||
|
enum_def->set_labels(il);
|
||||||
|
}
|
||||||
|
|
||||||
|
template<typename EnumType>
|
||||||
|
void set_enum(std::initializer_list<std::string_view> il) {
|
||||||
|
this->set_enum_values(il);
|
||||||
|
enum_def->set_enum_map<EnumType>();
|
||||||
|
}
|
||||||
|
|
||||||
|
template<typename EnumType>
|
||||||
|
void set_enum(std::initializer_list<std::pair<std::string_view, std::string_view>> il) {
|
||||||
|
this->set_enum_values(il);
|
||||||
|
enum_def->set_enum_map<EnumType>();
|
||||||
|
}
|
||||||
|
|
||||||
|
template<typename EnumType, typename Values, typename Labels>
|
||||||
|
void set_enum(Values &&values, Labels &&labels) {
|
||||||
|
this->set_enum_values(std::move(values), std::move(labels));
|
||||||
|
enum_def->set_enum_map<EnumType>();
|
||||||
|
}
|
||||||
|
|
||||||
|
template<typename EnumType, typename Values>
|
||||||
|
void set_enum(Values &&values, const std::initializer_list<std::string_view> labels) {
|
||||||
|
this->set_enum_values(std::move(values), labels);
|
||||||
|
enum_def->set_enum_map<EnumType>();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool has_enum_value(const std::string &value) const {
|
bool has_enum_value(const std::string &value) const {
|
||||||
for (const std::string &v : enum_values)
|
return enum_def && enum_def->value_to_index(value).has_value();
|
||||||
if (v == value)
|
|
||||||
return true;
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 0 is an invalid key.
|
// 0 is an invalid key.
|
||||||
@ -1815,6 +2033,14 @@ public:
|
|||||||
|
|
||||||
// Assign this key to cli to disable CLI for this option.
|
// Assign this key to cli to disable CLI for this option.
|
||||||
static const constexpr char *nocli = "~~~noCLI";
|
static const constexpr char *nocli = "~~~noCLI";
|
||||||
|
|
||||||
|
private:
|
||||||
|
void enum_def_new() {
|
||||||
|
if (enum_def)
|
||||||
|
enum_def->clear();
|
||||||
|
else
|
||||||
|
enum_def = Slic3r::clonable_ptr<ConfigOptionEnumDef>(new ConfigOptionEnumDef{});
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
inline bool operator<(const ConfigSubstitution &lhs, const ConfigSubstitution &rhs) throw() {
|
inline bool operator<(const ConfigSubstitution &lhs, const ConfigSubstitution &rhs) throw() {
|
||||||
@ -1860,6 +2086,8 @@ public:
|
|||||||
protected:
|
protected:
|
||||||
ConfigOptionDef* add(const t_config_option_key &opt_key, ConfigOptionType type);
|
ConfigOptionDef* add(const t_config_option_key &opt_key, ConfigOptionType type);
|
||||||
ConfigOptionDef* add_nullable(const t_config_option_key &opt_key, ConfigOptionType type);
|
ConfigOptionDef* add_nullable(const t_config_option_key &opt_key, ConfigOptionType type);
|
||||||
|
// Finalize open / close enums, validate everything.
|
||||||
|
void finalize();
|
||||||
};
|
};
|
||||||
|
|
||||||
// A pure interface to resolving ConfigOptions.
|
// A pure interface to resolving ConfigOptions.
|
||||||
@ -1970,6 +2198,11 @@ public:
|
|||||||
template<class T> const T* opt(const t_config_option_key &opt_key) const
|
template<class T> const T* opt(const t_config_option_key &opt_key) const
|
||||||
{ return dynamic_cast<const T*>(this->optptr(opt_key)); }
|
{ return dynamic_cast<const T*>(this->optptr(opt_key)); }
|
||||||
|
|
||||||
|
// Get definition for a particular option.
|
||||||
|
// Returns null if such an option definition does not exist.
|
||||||
|
const ConfigOptionDef* option_def(const t_config_option_key &opt_key) const
|
||||||
|
{ return this->def()->get(opt_key); }
|
||||||
|
|
||||||
// Apply all keys of other ConfigBase defined by this->def() to this ConfigBase.
|
// Apply all keys of other ConfigBase defined by this->def() to this ConfigBase.
|
||||||
// An UnknownOptionException is thrown in case some option keys of other are not defined by this->def(),
|
// An UnknownOptionException is thrown in case some option keys of other are not defined by this->def(),
|
||||||
// or this ConfigBase is of a StaticConfig type and it does not support some of the keys, and ignore_nonexistent is not set.
|
// or this ConfigBase is of a StaticConfig type and it does not support some of the keys, and ignore_nonexistent is not set.
|
||||||
|
@ -31,6 +31,9 @@ public:
|
|||||||
virtual void reverse() = 0;
|
virtual void reverse() = 0;
|
||||||
virtual const Point& first_point() const = 0;
|
virtual const Point& first_point() const = 0;
|
||||||
virtual const Point& last_point() const = 0;
|
virtual const Point& last_point() const = 0;
|
||||||
|
// Returns an approximately middle point of a path, loop or an extrusion collection.
|
||||||
|
// Used to get a sample point of an extrusion or extrusion collection, which is possibly deep inside its island.
|
||||||
|
virtual const Point& middle_point() const = 0;
|
||||||
// Produce a list of 2D polygons covered by the extruded paths, offsetted by the extrusion width.
|
// Produce a list of 2D polygons covered by the extruded paths, offsetted by the extrusion width.
|
||||||
// Increase the offset by scaled_epsilon to achieve an overlap, so a union will produce no gaps.
|
// Increase the offset by scaled_epsilon to achieve an overlap, so a union will produce no gaps.
|
||||||
virtual void polygons_covered_by_width(Polygons &out, const float scaled_epsilon) const = 0;
|
virtual void polygons_covered_by_width(Polygons &out, const float scaled_epsilon) const = 0;
|
||||||
@ -81,6 +84,7 @@ public:
|
|||||||
void reverse() override { this->polyline.reverse(); }
|
void reverse() override { this->polyline.reverse(); }
|
||||||
const Point& first_point() const override { return this->polyline.points.front(); }
|
const Point& first_point() const override { return this->polyline.points.front(); }
|
||||||
const Point& last_point() const override { return this->polyline.points.back(); }
|
const Point& last_point() const override { return this->polyline.points.back(); }
|
||||||
|
const Point& middle_point() const override { return this->polyline.points[this->polyline.size() / 2]; }
|
||||||
size_t size() const { return this->polyline.size(); }
|
size_t size() const { return this->polyline.size(); }
|
||||||
bool empty() const { return this->polyline.empty(); }
|
bool empty() const { return this->polyline.empty(); }
|
||||||
bool is_closed() const { return ! this->empty() && this->polyline.points.front() == this->polyline.points.back(); }
|
bool is_closed() const { return ! this->empty() && this->polyline.points.front() == this->polyline.points.back(); }
|
||||||
@ -153,6 +157,7 @@ public:
|
|||||||
void reverse() override;
|
void reverse() override;
|
||||||
const Point& first_point() const override { return this->paths.front().polyline.points.front(); }
|
const Point& first_point() const override { return this->paths.front().polyline.points.front(); }
|
||||||
const Point& last_point() const override { return this->paths.back().polyline.points.back(); }
|
const Point& last_point() const override { return this->paths.back().polyline.points.back(); }
|
||||||
|
const Point& middle_point() const override { auto &path = this->paths[this->paths.size() / 2]; return path.polyline.points[path.polyline.size() / 2]; }
|
||||||
size_t size() const { return this->paths.size(); }
|
size_t size() const { return this->paths.size(); }
|
||||||
bool empty() const { return this->paths.empty(); }
|
bool empty() const { return this->paths.empty(); }
|
||||||
double length() const override;
|
double length() const override;
|
||||||
@ -204,6 +209,7 @@ public:
|
|||||||
void reverse() override;
|
void reverse() override;
|
||||||
const Point& first_point() const override { return this->paths.front().polyline.points.front(); }
|
const Point& first_point() const override { return this->paths.front().polyline.points.front(); }
|
||||||
const Point& last_point() const override { assert(this->first_point() == this->paths.back().polyline.points.back()); return this->first_point(); }
|
const Point& last_point() const override { assert(this->first_point() == this->paths.back().polyline.points.back()); return this->first_point(); }
|
||||||
|
const Point& middle_point() const override { auto& path = this->paths[this->paths.size() / 2]; return path.polyline.points[path.polyline.size() / 2]; }
|
||||||
Polygon polygon() const;
|
Polygon polygon() const;
|
||||||
double length() const override;
|
double length() const override;
|
||||||
bool split_at_vertex(const Point &point, const double scaled_epsilon = scaled<double>(0.001));
|
bool split_at_vertex(const Point &point, const double scaled_epsilon = scaled<double>(0.001));
|
||||||
@ -288,12 +294,12 @@ inline void extrusion_entities_append_paths(ExtrusionEntitiesPtr &dst, const Pol
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void extrusion_entities_append_paths(ExtrusionEntitiesPtr &dst, Polylines &&polylines, ExtrusionRole role, double mm3_per_mm, float width, float height)
|
inline void extrusion_entities_append_paths(ExtrusionEntitiesPtr &dst, Polylines &&polylines, ExtrusionRole role, double mm3_per_mm, float width, float height, bool can_reverse = true)
|
||||||
{
|
{
|
||||||
dst.reserve(dst.size() + polylines.size());
|
dst.reserve(dst.size() + polylines.size());
|
||||||
for (Polyline &polyline : polylines)
|
for (Polyline &polyline : polylines)
|
||||||
if (polyline.is_valid()) {
|
if (polyline.is_valid()) {
|
||||||
ExtrusionPath *extrusion_path = new ExtrusionPath(role, mm3_per_mm, width, height);
|
ExtrusionPath *extrusion_path = can_reverse ? new ExtrusionPath(role, mm3_per_mm, width, height) : new ExtrusionPathOriented(role, mm3_per_mm, width, height);
|
||||||
dst.push_back(extrusion_path);
|
dst.push_back(extrusion_path);
|
||||||
extrusion_path->polyline = std::move(polyline);
|
extrusion_path->polyline = std::move(polyline);
|
||||||
}
|
}
|
||||||
|
@ -102,6 +102,7 @@ public:
|
|||||||
void reverse() override;
|
void reverse() override;
|
||||||
const Point& first_point() const override { return this->entities.front()->first_point(); }
|
const Point& first_point() const override { return this->entities.front()->first_point(); }
|
||||||
const Point& last_point() const override { return this->entities.back()->last_point(); }
|
const Point& last_point() const override { return this->entities.back()->last_point(); }
|
||||||
|
const Point& middle_point() const override { return this->entities[this->entities.size() / 2]->middle_point(); }
|
||||||
// Produce a list of 2D polygons covered by the extruded paths, offsetted by the extrusion width.
|
// Produce a list of 2D polygons covered by the extruded paths, offsetted by the extrusion width.
|
||||||
// Increase the offset by scaled_epsilon to achieve an overlap, so a union will produce no gaps.
|
// Increase the offset by scaled_epsilon to achieve an overlap, so a union will produce no gaps.
|
||||||
void polygons_covered_by_width(Polygons &out, const float scaled_epsilon) const override;
|
void polygons_covered_by_width(Polygons &out, const float scaled_epsilon) const override;
|
||||||
|
@ -83,6 +83,11 @@ struct ExtrusionRole : public ExtrusionRoleModifiers
|
|||||||
bool is_solid_infill() const { return this->is_infill() && this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Solid); }
|
bool is_solid_infill() const { return this->is_infill() && this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Solid); }
|
||||||
bool is_external() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::External); }
|
bool is_external() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::External); }
|
||||||
bool is_bridge() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Bridge); }
|
bool is_bridge() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Bridge); }
|
||||||
|
|
||||||
|
bool is_support() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Support); }
|
||||||
|
bool is_support_base() const { return this->is_support() && ! this->is_external(); }
|
||||||
|
bool is_support_interface() const { return this->is_support() && this->is_external(); }
|
||||||
|
bool is_mixed() const { return this->ExtrusionRoleModifiers::has(ExtrusionRoleModifier::Mixed); }
|
||||||
};
|
};
|
||||||
|
|
||||||
// Special flags describing loop
|
// Special flags describing loop
|
||||||
|
@ -230,6 +230,8 @@ namespace Slic3r {
|
|||||||
|
|
||||||
std::string tcr_rotated_gcode = post_process_wipe_tower_moves(tcr, wipe_tower_offset, wipe_tower_rotation);
|
std::string tcr_rotated_gcode = post_process_wipe_tower_moves(tcr, wipe_tower_offset, wipe_tower_rotation);
|
||||||
|
|
||||||
|
gcode += gcodegen.writer().unlift(); // Make sure there is no z-hop (in most cases, there isn't).
|
||||||
|
|
||||||
double current_z = gcodegen.writer().get_position().z();
|
double current_z = gcodegen.writer().get_position().z();
|
||||||
if (z == -1.) // in case no specific z was provided, print at current_z pos
|
if (z == -1.) // in case no specific z was provided, print at current_z pos
|
||||||
z = current_z;
|
z = current_z;
|
||||||
@ -1192,7 +1194,7 @@ void GCode::_do_export(Print& print, GCodeOutputStream &file, ThumbnailsGenerato
|
|||||||
m_placeholder_parser.set("first_layer_print_size", new ConfigOptionFloats({ bbox.size().x(), bbox.size().y() }));
|
m_placeholder_parser.set("first_layer_print_size", new ConfigOptionFloats({ bbox.size().x(), bbox.size().y() }));
|
||||||
|
|
||||||
std::vector<unsigned char> is_extruder_used(print.config().nozzle_diameter.size(), 0);
|
std::vector<unsigned char> is_extruder_used(print.config().nozzle_diameter.size(), 0);
|
||||||
for (unsigned int extruder_id : print.extruders())
|
for (unsigned int extruder_id : tool_ordering.all_extruders())
|
||||||
is_extruder_used[extruder_id] = true;
|
is_extruder_used[extruder_id] = true;
|
||||||
m_placeholder_parser.set("is_extruder_used", new ConfigOptionBools(is_extruder_used));
|
m_placeholder_parser.set("is_extruder_used", new ConfigOptionBools(is_extruder_used));
|
||||||
}
|
}
|
||||||
@ -1784,9 +1786,7 @@ std::vector<GCode::InstanceToPrint> GCode::sort_print_object_instances(
|
|||||||
if (ordering == nullptr) {
|
if (ordering == nullptr) {
|
||||||
// Sequential print, single object is being printed.
|
// Sequential print, single object is being printed.
|
||||||
assert(object_layers.size() == 1);
|
assert(object_layers.size() == 1);
|
||||||
const Layer *layer = object_layers.front().object_layer;
|
out.emplace_back(0, *object_layers.front().object(), single_object_instance_idx);
|
||||||
assert(layer != nullptr);
|
|
||||||
out.emplace_back(0, *layer->object(), single_object_instance_idx);
|
|
||||||
} else {
|
} else {
|
||||||
// Create mapping from PrintObject* to ObjectLayerToPrint ID.
|
// Create mapping from PrintObject* to ObjectLayerToPrint ID.
|
||||||
std::vector<std::pair<const PrintObject*, size_t>> sorted;
|
std::vector<std::pair<const PrintObject*, size_t>> sorted;
|
||||||
@ -2248,29 +2248,24 @@ void GCode::process_layer_single_object(
|
|||||||
if (! print_wipe_extrusions && layer_to_print.support_layer != nullptr)
|
if (! print_wipe_extrusions && layer_to_print.support_layer != nullptr)
|
||||||
if (const SupportLayer &support_layer = *layer_to_print.support_layer; ! support_layer.support_fills.entities.empty()) {
|
if (const SupportLayer &support_layer = *layer_to_print.support_layer; ! support_layer.support_fills.entities.empty()) {
|
||||||
ExtrusionRole role = support_layer.support_fills.role();
|
ExtrusionRole role = support_layer.support_fills.role();
|
||||||
bool has_support = role == ExtrusionRole::Mixed || role == ExtrusionRole::SupportMaterial;
|
bool has_support = role.is_mixed() || role.is_support_base();
|
||||||
bool has_interface = role == ExtrusionRole::Mixed || role == ExtrusionRole::SupportMaterialInterface;
|
bool has_interface = role.is_mixed() || role.is_support_interface();
|
||||||
// Extruder ID of the support base. -1 if "don't care".
|
// Extruder ID of the support base. -1 if "don't care".
|
||||||
unsigned int support_extruder = print_object.config().support_material_extruder.value - 1;
|
unsigned int support_extruder = print_object.config().support_material_extruder.value - 1;
|
||||||
// Shall the support be printed with the active extruder, preferably with non-soluble, to avoid tool changes?
|
// Shall the support be printed with the active extruder, preferably with non-soluble, to avoid tool changes?
|
||||||
bool support_dontcare = print_object.config().support_material_extruder.value == 0;
|
bool support_dontcare = support_extruder == std::numeric_limits<unsigned int>::max();
|
||||||
// Extruder ID of the support interface. -1 if "don't care".
|
// Extruder ID of the support interface. -1 if "don't care".
|
||||||
unsigned int interface_extruder = print_object.config().support_material_interface_extruder.value - 1;
|
unsigned int interface_extruder = print_object.config().support_material_interface_extruder.value - 1;
|
||||||
// Shall the support interface be printed with the active extruder, preferably with non-soluble, to avoid tool changes?
|
// Shall the support interface be printed with the active extruder, preferably with non-soluble, to avoid tool changes?
|
||||||
bool interface_dontcare = print_object.config().support_material_interface_extruder.value == 0;
|
bool interface_dontcare = interface_extruder == std::numeric_limits<unsigned int>::max();
|
||||||
if (support_dontcare || interface_dontcare) {
|
if (support_dontcare || interface_dontcare) {
|
||||||
// Some support will be printed with "don't care" material, preferably non-soluble.
|
// Some support will be printed with "don't care" material, preferably non-soluble.
|
||||||
// Is the current extruder assigned a soluble filament?
|
// Is the current extruder assigned a soluble filament?
|
||||||
unsigned int dontcare_extruder = layer_tools.extruders.front();
|
auto it_nonsoluble = std::find_if(layer_tools.extruders.begin(), layer_tools.extruders.end(),
|
||||||
if (print.config().filament_soluble.get_at(dontcare_extruder)) {
|
[&soluble = std::as_const(print.config().filament_soluble)](unsigned int extruder_id) { return ! soluble.get_at(extruder_id); });
|
||||||
// The last extruder printed on the previous layer extrudes soluble filament.
|
// There should be a non-soluble extruder available.
|
||||||
// Try to find a non-soluble extruder on the same layer.
|
assert(it_nonsoluble != layer_tools.extruders.end());
|
||||||
for (unsigned int extruder_id : layer_tools.extruders)
|
unsigned int dontcare_extruder = it_nonsoluble == layer_tools.extruders.end() ? layer_tools.extruders.front() : *it_nonsoluble;
|
||||||
if (! print.config().filament_soluble.get_at(extruder_id)) {
|
|
||||||
dontcare_extruder = extruder_id;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (support_dontcare)
|
if (support_dontcare)
|
||||||
support_extruder = dontcare_extruder;
|
support_extruder = dontcare_extruder;
|
||||||
if (interface_dontcare)
|
if (interface_dontcare)
|
||||||
@ -2284,7 +2279,7 @@ void GCode::process_layer_single_object(
|
|||||||
m_object_layer_over_raft = false;
|
m_object_layer_over_raft = false;
|
||||||
gcode += this->extrude_support(
|
gcode += this->extrude_support(
|
||||||
// support_extrusion_role is ExtrusionRole::SupportMaterial, ExtrusionRole::SupportMaterialInterface or ExtrusionRole::Mixed for all extrusion paths.
|
// support_extrusion_role is ExtrusionRole::SupportMaterial, ExtrusionRole::SupportMaterialInterface or ExtrusionRole::Mixed for all extrusion paths.
|
||||||
support_layer.support_fills.chained_path_from(m_last_pos, has_support ? (has_interface ? ExtrusionRole::Mixed : ExtrusionRole::SupportMaterial) : ExtrusionRole::SupportMaterialInterface));
|
support_layer.support_fills.chained_path_from(m_last_pos, extrude_support ? (extrude_interface ? ExtrusionRole::Mixed : ExtrusionRole::SupportMaterial) : ExtrusionRole::SupportMaterialInterface));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2798,8 +2793,14 @@ std::string GCode::_extrude(const ExtrusionPath &path, const std::string_view de
|
|||||||
acceleration = m_config.first_layer_acceleration_over_raft.value;
|
acceleration = m_config.first_layer_acceleration_over_raft.value;
|
||||||
} else if (m_config.bridge_acceleration.value > 0 && path.role().is_bridge()) {
|
} else if (m_config.bridge_acceleration.value > 0 && path.role().is_bridge()) {
|
||||||
acceleration = m_config.bridge_acceleration.value;
|
acceleration = m_config.bridge_acceleration.value;
|
||||||
|
} else if (m_config.top_solid_infill_acceleration > 0 && path.role() == ExtrusionRole::TopSolidInfill) {
|
||||||
|
acceleration = m_config.top_solid_infill_acceleration.value;
|
||||||
|
} else if (m_config.solid_infill_acceleration > 0 && path.role().is_solid_infill()) {
|
||||||
|
acceleration = m_config.solid_infill_acceleration.value;
|
||||||
} else if (m_config.infill_acceleration.value > 0 && path.role().is_infill()) {
|
} else if (m_config.infill_acceleration.value > 0 && path.role().is_infill()) {
|
||||||
acceleration = m_config.infill_acceleration.value;
|
acceleration = m_config.infill_acceleration.value;
|
||||||
|
} else if (m_config.external_perimeter_acceleration > 0 && path.role().is_external_perimeter()) {
|
||||||
|
acceleration = m_config.external_perimeter_acceleration.value;
|
||||||
} else if (m_config.perimeter_acceleration.value > 0 && path.role().is_perimeter()) {
|
} else if (m_config.perimeter_acceleration.value > 0 && path.role().is_perimeter()) {
|
||||||
acceleration = m_config.perimeter_acceleration.value;
|
acceleration = m_config.perimeter_acceleration.value;
|
||||||
} else {
|
} else {
|
||||||
@ -2861,9 +2862,12 @@ std::string GCode::_extrude(const ExtrusionPath &path, const std::string_view de
|
|||||||
bool variable_speed = false;
|
bool variable_speed = false;
|
||||||
std::vector<ProcessedPoint> new_points{};
|
std::vector<ProcessedPoint> new_points{};
|
||||||
if (this->m_config.enable_dynamic_overhang_speeds && !this->on_first_layer() && path.role().is_perimeter()) {
|
if (this->m_config.enable_dynamic_overhang_speeds && !this->on_first_layer() && path.role().is_perimeter()) {
|
||||||
|
double external_perim_reference_speed = std::min(m_config.get_abs_value("external_perimeter_speed"),
|
||||||
|
std::min(EXTRUDER_CONFIG(filament_max_volumetric_speed) / path.mm3_per_mm,
|
||||||
|
m_config.max_volumetric_speed.value / path.mm3_per_mm));
|
||||||
new_points = m_extrusion_quality_estimator.estimate_extrusion_quality(path, m_config.overhang_overlap_levels,
|
new_points = m_extrusion_quality_estimator.estimate_extrusion_quality(path, m_config.overhang_overlap_levels,
|
||||||
m_config.dynamic_overhang_speeds,
|
m_config.dynamic_overhang_speeds,
|
||||||
m_config.get_abs_value("external_perimeter_speed"), speed);
|
external_perim_reference_speed, speed);
|
||||||
variable_speed = std::any_of(new_points.begin(), new_points.end(), [speed](const ProcessedPoint &p) { return p.speed != speed; });
|
variable_speed = std::any_of(new_points.begin(), new_points.end(), [speed](const ProcessedPoint &p) { return p.speed != speed; });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2948,10 +2952,10 @@ std::string GCode::_extrude(const ExtrusionPath &path, const std::string_view de
|
|||||||
prev = p;
|
prev = p;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
std::string comment;
|
std::string marked_comment;
|
||||||
if (m_config.gcode_comments) {
|
if (m_config.gcode_comments) {
|
||||||
comment = description;
|
marked_comment = description;
|
||||||
comment += description_bridge;
|
marked_comment += description_bridge;
|
||||||
}
|
}
|
||||||
double last_set_speed = new_points[0].speed * 60.0;
|
double last_set_speed = new_points[0].speed * 60.0;
|
||||||
gcode += m_writer.set_speed(last_set_speed, "", comment);
|
gcode += m_writer.set_speed(last_set_speed, "", comment);
|
||||||
@ -2960,7 +2964,7 @@ std::string GCode::_extrude(const ExtrusionPath &path, const std::string_view de
|
|||||||
const ProcessedPoint& processed_point = new_points[i];
|
const ProcessedPoint& processed_point = new_points[i];
|
||||||
Vec2d p = this->point_to_gcode_quantized(processed_point.p);
|
Vec2d p = this->point_to_gcode_quantized(processed_point.p);
|
||||||
const double line_length = (p - prev).norm();
|
const double line_length = (p - prev).norm();
|
||||||
gcode += m_writer.extrude_to_xy(p, e_per_mm * line_length, comment);
|
gcode += m_writer.extrude_to_xy(p, e_per_mm * line_length, marked_comment);
|
||||||
prev = p;
|
prev = p;
|
||||||
double new_speed = processed_point.speed * 60.0;
|
double new_speed = processed_point.speed * 60.0;
|
||||||
if (last_set_speed != new_speed) {
|
if (last_set_speed != new_speed) {
|
||||||
|
@ -462,24 +462,24 @@ std::vector<PerExtruderAdjustments> CoolingBuffer::parse_layer_gcode(const std::
|
|||||||
}
|
}
|
||||||
active_speed_modifier = size_t(-1);
|
active_speed_modifier = size_t(-1);
|
||||||
} else if (boost::starts_with(sline, m_toolchange_prefix)) {
|
} else if (boost::starts_with(sline, m_toolchange_prefix)) {
|
||||||
unsigned int new_extruder;
|
unsigned int new_extruder = 0;
|
||||||
//auto res =
|
auto res = std::from_chars(sline.data() + m_toolchange_prefix.size(), sline.data() + sline.size(), new_extruder);
|
||||||
std::from_chars(sline.data() + m_toolchange_prefix.size(), sline.data() + sline.size(), new_extruder);
|
if (res.ec != std::errc::invalid_argument) {
|
||||||
// Only change extruder in case the number is meaningful. User could provide an out-of-range index through custom gcodes - those shall be ignored.
|
// Only change extruder in case the number is meaningful. User could provide an out-of-range index through custom gcodes - those shall be ignored.
|
||||||
if (new_extruder < map_extruder_to_per_extruder_adjustment.size()) {
|
if (new_extruder < map_extruder_to_per_extruder_adjustment.size()) {
|
||||||
if (new_extruder != current_extruder) {
|
if (new_extruder != current_extruder) {
|
||||||
// Switch the tool.
|
// Switch the tool.
|
||||||
line.type = CoolingLine::TYPE_SET_TOOL;
|
line.type = CoolingLine::TYPE_SET_TOOL;
|
||||||
current_extruder = new_extruder;
|
current_extruder = new_extruder;
|
||||||
adjustment = &per_extruder_adjustments[map_extruder_to_per_extruder_adjustment[current_extruder]];
|
adjustment = &per_extruder_adjustments[map_extruder_to_per_extruder_adjustment[current_extruder]];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
// Only log the error in case of MM printer. Single extruder printers likely ignore any T anyway.
|
||||||
|
if (map_extruder_to_per_extruder_adjustment.size() > 1)
|
||||||
|
BOOST_LOG_TRIVIAL(error) << "CoolingBuffer encountered an invalid toolchange, maybe from a custom gcode: " << sline;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
// Only log the error in case of MM printer. Single extruder printers likely ignore any T anyway.
|
|
||||||
if (map_extruder_to_per_extruder_adjustment.size() > 1)
|
|
||||||
BOOST_LOG_TRIVIAL(error) << "CoolingBuffer encountered an invalid toolchange, maybe from a custom gcode: " << sline;
|
|
||||||
}
|
|
||||||
|
|
||||||
} else if (boost::starts_with(sline, ";_BRIDGE_FAN_START")) {
|
} else if (boost::starts_with(sline, ";_BRIDGE_FAN_START")) {
|
||||||
line.type = CoolingLine::TYPE_BRIDGE_FAN_START;
|
line.type = CoolingLine::TYPE_BRIDGE_FAN_START;
|
||||||
} else if (boost::starts_with(sline, ";_BRIDGE_FAN_END")) {
|
} else if (boost::starts_with(sline, ";_BRIDGE_FAN_END")) {
|
||||||
@ -788,10 +788,9 @@ std::string CoolingBuffer::apply_layer_cooldown(
|
|||||||
if (line_start > pos)
|
if (line_start > pos)
|
||||||
new_gcode.append(pos, line_start - pos);
|
new_gcode.append(pos, line_start - pos);
|
||||||
if (line->type & CoolingLine::TYPE_SET_TOOL) {
|
if (line->type & CoolingLine::TYPE_SET_TOOL) {
|
||||||
unsigned int new_extruder;
|
unsigned int new_extruder = 0;
|
||||||
//auto res =
|
auto res = std::from_chars(line_start + m_toolchange_prefix.size(), line_end, new_extruder);
|
||||||
std::from_chars(line_start + m_toolchange_prefix.size(), line_end, new_extruder);
|
if (res.ec != std::errc::invalid_argument && new_extruder != m_current_extruder) {
|
||||||
if (new_extruder != m_current_extruder) {
|
|
||||||
m_current_extruder = new_extruder;
|
m_current_extruder = new_extruder;
|
||||||
change_extruder_set_fan();
|
change_extruder_set_fan();
|
||||||
}
|
}
|
||||||
|
@ -264,10 +264,11 @@ public:
|
|||||||
float original_speed)
|
float original_speed)
|
||||||
{
|
{
|
||||||
size_t speed_sections_count = std::min(overlaps.values.size(), speeds.values.size());
|
size_t speed_sections_count = std::min(overlaps.values.size(), speeds.values.size());
|
||||||
|
float speed_base = ext_perimeter_speed > 0 ? ext_perimeter_speed : original_speed;
|
||||||
std::vector<std::pair<float, float>> speed_sections;
|
std::vector<std::pair<float, float>> speed_sections;
|
||||||
for (size_t i = 0; i < speed_sections_count; i++) {
|
for (size_t i = 0; i < speed_sections_count; i++) {
|
||||||
float distance = path.width * (1.0 - (overlaps.get_at(i) / 100.0));
|
float distance = path.width * (1.0 - (overlaps.get_at(i) / 100.0));
|
||||||
float speed = speeds.get_at(i).percent ? (ext_perimeter_speed * speeds.get_at(i).value / 100.0) : speeds.get_at(i).value;
|
float speed = speeds.get_at(i).percent ? (speed_base * speeds.get_at(i).value / 100.0) : speeds.get_at(i).value;
|
||||||
speed_sections.push_back({distance, speed});
|
speed_sections.push_back({distance, speed});
|
||||||
}
|
}
|
||||||
std::sort(speed_sections.begin(), speed_sections.end(),
|
std::sort(speed_sections.begin(), speed_sections.end(),
|
||||||
|
@ -593,9 +593,11 @@ void GCodeProcessor::apply_config(const PrintConfig& config)
|
|||||||
m_time_processor.filament_unload_times[i] = static_cast<float>(config.filament_unload_time.values[i]);
|
m_time_processor.filament_unload_times[i] = static_cast<float>(config.filament_unload_time.values[i]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
m_single_extruder_multi_material = config.single_extruder_multi_material;
|
||||||
|
|
||||||
// With MM setups like Prusa MMU2, the filaments may be expected to be parked at the beginning.
|
// With MM setups like Prusa MMU2, the filaments may be expected to be parked at the beginning.
|
||||||
// Remember the parking position so the initial load is not included in filament estimate.
|
// Remember the parking position so the initial load is not included in filament estimate.
|
||||||
if (config.single_extruder_multi_material && extruders_count > 1 && config.wipe_tower) {
|
if (m_single_extruder_multi_material && extruders_count > 1 && config.wipe_tower) {
|
||||||
m_parking_position = float(config.parking_pos_retraction.value);
|
m_parking_position = float(config.parking_pos_retraction.value);
|
||||||
m_extra_loading_move = float(config.extra_loading_move);
|
m_extra_loading_move = float(config.extra_loading_move);
|
||||||
}
|
}
|
||||||
@ -772,8 +774,10 @@ void GCodeProcessor::apply_config(const DynamicPrintConfig& config)
|
|||||||
const ConfigOptionFloat* parking_pos_retraction = config.option<ConfigOptionFloat>("parking_pos_retraction");
|
const ConfigOptionFloat* parking_pos_retraction = config.option<ConfigOptionFloat>("parking_pos_retraction");
|
||||||
const ConfigOptionFloat* extra_loading_move = config.option<ConfigOptionFloat>("extra_loading_move");
|
const ConfigOptionFloat* extra_loading_move = config.option<ConfigOptionFloat>("extra_loading_move");
|
||||||
|
|
||||||
if (single_extruder_multi_material != nullptr && wipe_tower != nullptr && parking_pos_retraction != nullptr && extra_loading_move != nullptr) {
|
m_single_extruder_multi_material = single_extruder_multi_material != nullptr && single_extruder_multi_material->value;
|
||||||
if (single_extruder_multi_material->value && m_result.extruders_count > 1 && wipe_tower->value) {
|
|
||||||
|
if (m_single_extruder_multi_material && wipe_tower != nullptr && parking_pos_retraction != nullptr && extra_loading_move != nullptr) {
|
||||||
|
if (m_single_extruder_multi_material && m_result.extruders_count > 1 && wipe_tower->value) {
|
||||||
m_parking_position = float(parking_pos_retraction->value);
|
m_parking_position = float(parking_pos_retraction->value);
|
||||||
m_extra_loading_move = float(extra_loading_move->value);
|
m_extra_loading_move = float(extra_loading_move->value);
|
||||||
}
|
}
|
||||||
@ -977,6 +981,8 @@ void GCodeProcessor::reset()
|
|||||||
m_spiral_vase_active = false;
|
m_spiral_vase_active = false;
|
||||||
m_kissslicer_toolchange_time_correction = 0.0f;
|
m_kissslicer_toolchange_time_correction = 0.0f;
|
||||||
|
|
||||||
|
m_single_extruder_multi_material = false;
|
||||||
|
|
||||||
#if ENABLE_GCODE_VIEWER_DATA_CHECKING
|
#if ENABLE_GCODE_VIEWER_DATA_CHECKING
|
||||||
m_mm3_per_mm_compare.reset();
|
m_mm3_per_mm_compare.reset();
|
||||||
m_height_compare.reset();
|
m_height_compare.reset();
|
||||||
@ -3372,6 +3378,11 @@ void GCodeProcessor::process_T(const std::string_view command)
|
|||||||
extra_time += m_kissslicer_toolchange_time_correction;
|
extra_time += m_kissslicer_toolchange_time_correction;
|
||||||
simulate_st_synchronize(extra_time);
|
simulate_st_synchronize(extra_time);
|
||||||
|
|
||||||
|
// specific to single extruder multi material, set the extruder temperature
|
||||||
|
// if not done yet
|
||||||
|
if (m_single_extruder_multi_material && m_extruder_temps[m_extruder_id] == 0.0f)
|
||||||
|
m_extruder_temps[m_extruder_id] = m_extruder_temps[old_extruder_id];
|
||||||
|
|
||||||
m_result.extruders_count = std::max<size_t>(m_result.extruders_count, m_extruder_id + 1);
|
m_result.extruders_count = std::max<size_t>(m_result.extruders_count, m_extruder_id + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -559,6 +559,7 @@ namespace Slic3r {
|
|||||||
#if ENABLE_GCODE_VIEWER_STATISTICS
|
#if ENABLE_GCODE_VIEWER_STATISTICS
|
||||||
std::chrono::time_point<std::chrono::high_resolution_clock> m_start_time;
|
std::chrono::time_point<std::chrono::high_resolution_clock> m_start_time;
|
||||||
#endif // ENABLE_GCODE_VIEWER_STATISTICS
|
#endif // ENABLE_GCODE_VIEWER_STATISTICS
|
||||||
|
bool m_single_extruder_multi_material;
|
||||||
|
|
||||||
enum class EProducer
|
enum class EProducer
|
||||||
{
|
{
|
||||||
|
@ -720,28 +720,26 @@ void Transformation::reset()
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if ENABLE_WORLD_COORDINATE
|
#if ENABLE_WORLD_COORDINATE
|
||||||
|
void Transformation::reset_rotation()
|
||||||
|
{
|
||||||
|
const Geometry::TransformationSVD svd(*this);
|
||||||
|
m_matrix = get_offset_matrix() * Transform3d(svd.v * svd.s * svd.v.transpose()) * svd.mirror_matrix();
|
||||||
|
}
|
||||||
|
|
||||||
|
void Transformation::reset_scaling_factor()
|
||||||
|
{
|
||||||
|
const Geometry::TransformationSVD svd(*this);
|
||||||
|
m_matrix = get_offset_matrix() * Transform3d(svd.u) * Transform3d(svd.v.transpose()) * svd.mirror_matrix();
|
||||||
|
}
|
||||||
|
|
||||||
void Transformation::reset_skew()
|
void Transformation::reset_skew()
|
||||||
{
|
{
|
||||||
Matrix3d rotation;
|
auto new_scale_factor = [](const Matrix3d& s) {
|
||||||
Matrix3d scale;
|
return pow(s(0, 0) * s(1, 1) * s(2, 2), 1. / 3.); // scale average
|
||||||
m_matrix.computeRotationScaling(&rotation, &scale);
|
};
|
||||||
|
|
||||||
const double average_scale = std::cbrt(scale(0, 0) * scale(1, 1) * scale(2, 2));
|
const Geometry::TransformationSVD svd(*this);
|
||||||
|
m_matrix = get_offset_matrix() * Transform3d(svd.u) * scale_transform(new_scale_factor(svd.s)) * Transform3d(svd.v.transpose()) * svd.mirror_matrix();
|
||||||
scale(0, 0) = is_left_handed() ? -average_scale : average_scale;
|
|
||||||
scale(1, 1) = average_scale;
|
|
||||||
scale(2, 2) = average_scale;
|
|
||||||
|
|
||||||
scale(0, 1) = 0.0;
|
|
||||||
scale(0, 2) = 0.0;
|
|
||||||
scale(1, 0) = 0.0;
|
|
||||||
scale(1, 2) = 0.0;
|
|
||||||
scale(2, 0) = 0.0;
|
|
||||||
scale(2, 1) = 0.0;
|
|
||||||
|
|
||||||
const Vec3d offset = get_offset();
|
|
||||||
m_matrix = rotation * scale;
|
|
||||||
m_matrix.translation() = offset;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Transform3d Transformation::get_matrix_no_offset() const
|
Transform3d Transformation::get_matrix_no_offset() const
|
||||||
@ -838,6 +836,43 @@ Transformation Transformation::volume_to_bed_transformation(const Transformation
|
|||||||
}
|
}
|
||||||
#endif // !ENABLE_WORLD_COORDINATE
|
#endif // !ENABLE_WORLD_COORDINATE
|
||||||
|
|
||||||
|
#if ENABLE_WORLD_COORDINATE
|
||||||
|
TransformationSVD::TransformationSVD(const Transform3d& trafo)
|
||||||
|
{
|
||||||
|
const auto &m0 = trafo.matrix().block<3, 3>(0, 0);
|
||||||
|
mirror = m0.determinant() < 0.0;
|
||||||
|
|
||||||
|
Matrix3d m;
|
||||||
|
if (mirror)
|
||||||
|
m = m0 * Eigen::DiagonalMatrix<double, 3, 3>(-1.0, 1.0, 1.0);
|
||||||
|
else
|
||||||
|
m = m0;
|
||||||
|
const Eigen::JacobiSVD<Matrix3d> svd(m, Eigen::ComputeFullU | Eigen::ComputeFullV);
|
||||||
|
u = svd.matrixU();
|
||||||
|
v = svd.matrixV();
|
||||||
|
s = svd.singularValues().asDiagonal();
|
||||||
|
|
||||||
|
scale = !s.isApprox(Matrix3d::Identity());
|
||||||
|
anisotropic_scale = ! is_approx(s(0, 0), s(1, 1)) || ! is_approx(s(1, 1), s(2, 2));
|
||||||
|
rotation = !v.isApprox(u);
|
||||||
|
|
||||||
|
if (anisotropic_scale) {
|
||||||
|
rotation_90_degrees = true;
|
||||||
|
for (int i = 0; i < 3; ++i) {
|
||||||
|
const Vec3d row = v.row(i).cwiseAbs();
|
||||||
|
size_t num_zeros = is_approx(row[0], 0.) + is_approx(row[1], 0.) + is_approx(row[2], 0.);
|
||||||
|
size_t num_ones = is_approx(row[0], 1.) + is_approx(row[1], 1.) + is_approx(row[2], 1.);
|
||||||
|
if (num_zeros != 2 || num_ones != 1) {
|
||||||
|
rotation_90_degrees = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
skew = ! rotation_90_degrees;
|
||||||
|
} else
|
||||||
|
skew = false;
|
||||||
|
}
|
||||||
|
#endif // ENABLE_WORLD_COORDINATE
|
||||||
|
|
||||||
// For parsing a transformation matrix from 3MF / AMF.
|
// For parsing a transformation matrix from 3MF / AMF.
|
||||||
Transform3d transform3d_from_string(const std::string& transform_str)
|
Transform3d transform3d_from_string(const std::string& transform_str)
|
||||||
{
|
{
|
||||||
|
@ -492,8 +492,8 @@ public:
|
|||||||
void reset();
|
void reset();
|
||||||
#if ENABLE_WORLD_COORDINATE
|
#if ENABLE_WORLD_COORDINATE
|
||||||
void reset_offset() { set_offset(Vec3d::Zero()); }
|
void reset_offset() { set_offset(Vec3d::Zero()); }
|
||||||
void reset_rotation() { set_rotation(Vec3d::Zero()); }
|
void reset_rotation();
|
||||||
void reset_scaling_factor() { set_scaling_factor(Vec3d::Ones()); }
|
void reset_scaling_factor();
|
||||||
void reset_mirror() { set_mirror(Vec3d::Ones()); }
|
void reset_mirror() { set_mirror(Vec3d::Ones()); }
|
||||||
void reset_skew();
|
void reset_skew();
|
||||||
|
|
||||||
@ -538,6 +538,27 @@ private:
|
|||||||
#endif // ENABLE_WORLD_COORDINATE
|
#endif // ENABLE_WORLD_COORDINATE
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#if ENABLE_WORLD_COORDINATE
|
||||||
|
struct TransformationSVD
|
||||||
|
{
|
||||||
|
Matrix3d u = Matrix3d::Identity();
|
||||||
|
Matrix3d s = Matrix3d::Identity();
|
||||||
|
Matrix3d v = Matrix3d::Identity();
|
||||||
|
|
||||||
|
bool mirror{ false };
|
||||||
|
bool scale{ false };
|
||||||
|
bool anisotropic_scale{ false };
|
||||||
|
bool rotation{ false };
|
||||||
|
bool rotation_90_degrees{ false };
|
||||||
|
bool skew{ false };
|
||||||
|
|
||||||
|
explicit TransformationSVD(const Transformation& trafo) : TransformationSVD(trafo.get_matrix()) {}
|
||||||
|
explicit TransformationSVD(const Transform3d& trafo);
|
||||||
|
|
||||||
|
Eigen::DiagonalMatrix<double, 3, 3> mirror_matrix() const { return Eigen::DiagonalMatrix<double, 3, 3>(this->mirror ? -1. : 1., 1., 1.); }
|
||||||
|
};
|
||||||
|
#endif // ENABLE_WORLD_COORDINATE
|
||||||
|
|
||||||
// For parsing a transformation matrix from 3MF / AMF.
|
// For parsing a transformation matrix from 3MF / AMF.
|
||||||
extern Transform3d transform3d_from_string(const std::string& transform_str);
|
extern Transform3d transform3d_from_string(const std::string& transform_str);
|
||||||
|
|
||||||
|
@ -398,7 +398,7 @@ bool inside_convex_polygon(const std::pair<std::vector<Vec2d>, std::vector<Vec2d
|
|||||||
// At min x.
|
// At min x.
|
||||||
assert(pt.x() == it_bottom->x());
|
assert(pt.x() == it_bottom->x());
|
||||||
assert(pt.x() == it_top->x());
|
assert(pt.x() == it_top->x());
|
||||||
assert(it_bottom->y() <= pt.y() <= it_top->y());
|
assert(it_bottom->y() <= pt.y() && pt.y() <= it_top->y());
|
||||||
return pt.y() >= it_bottom->y() && pt.y() <= it_top->y();
|
return pt.y() >= it_bottom->y() && pt.y() <= it_top->y();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -53,22 +53,7 @@ void Layer::make_slices()
|
|||||||
this->lslices = slices;
|
this->lslices = slices;
|
||||||
}
|
}
|
||||||
|
|
||||||
// prepare lslices ordered by print order
|
this->lslice_indices_sorted_by_print_order = chain_expolygons(this->lslices);
|
||||||
this->lslice_indices_sorted_by_print_order.clear();
|
|
||||||
this->lslice_indices_sorted_by_print_order.reserve(lslices.size());
|
|
||||||
// prepare ordering points
|
|
||||||
Points ordering_points;
|
|
||||||
ordering_points.reserve( this->lslices.size());
|
|
||||||
for (const ExPolygon &ex : this->lslices)
|
|
||||||
ordering_points.push_back(ex.contour.first_point());
|
|
||||||
|
|
||||||
// sort slices
|
|
||||||
std::vector<Points::size_type> order = chain_points(ordering_points);
|
|
||||||
|
|
||||||
// populate slices vector
|
|
||||||
for (size_t i : order) {
|
|
||||||
this->lslice_indices_sorted_by_print_order.emplace_back(i);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// used by Layer::build_up_down_graph()
|
// used by Layer::build_up_down_graph()
|
||||||
@ -105,7 +90,7 @@ static void connect_layer_slices(
|
|||||||
const coord_t offset_below,
|
const coord_t offset_below,
|
||||||
const coord_t offset_above
|
const coord_t offset_above
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
, const coord_t offset_end
|
, const coord_t offset_end
|
||||||
#endif // NDEBUG
|
#endif // NDEBUG
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
@ -127,9 +112,7 @@ static void connect_layer_slices(
|
|||||||
{
|
{
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
auto assert_intersection_valid = [this](int i, int j) {
|
auto assert_intersection_valid = [this](int i, int j) {
|
||||||
assert(i != j);
|
assert(i < j);
|
||||||
if (i > j)
|
|
||||||
std::swap(i, j);
|
|
||||||
assert(i >= m_offset_below);
|
assert(i >= m_offset_below);
|
||||||
assert(i < m_offset_above);
|
assert(i < m_offset_above);
|
||||||
assert(j >= m_offset_above);
|
assert(j >= m_offset_above);
|
||||||
@ -140,35 +123,47 @@ static void connect_layer_slices(
|
|||||||
if (polynode.Contour.size() >= 3) {
|
if (polynode.Contour.size() >= 3) {
|
||||||
// If there is an intersection point, it should indicate which contours (one from layer below, the other from layer above) intersect.
|
// If there is an intersection point, it should indicate which contours (one from layer below, the other from layer above) intersect.
|
||||||
// Otherwise the contour is fully inside another contour.
|
// Otherwise the contour is fully inside another contour.
|
||||||
int32_t i = 0, j = 0;
|
int32_t i = -1, j = -1;
|
||||||
for (int icontour = 0; icontour <= polynode.ChildCount(); ++ icontour) {
|
for (int icontour = 0; icontour <= polynode.ChildCount(); ++ icontour) {
|
||||||
const bool first = icontour == 0;
|
const ClipperLib_Z::Path &contour = icontour == 0 ? polynode.Contour : polynode.Childs[icontour - 1]->Contour;
|
||||||
const ClipperLib_Z::Path &contour = first ? polynode.Contour : polynode.Childs[icontour - 1]->Contour;
|
|
||||||
if (contour.size() >= 3) {
|
if (contour.size() >= 3) {
|
||||||
if (first) {
|
for (const ClipperLib_Z::IntPoint &pt : contour) {
|
||||||
i = contour.front().z();
|
|
||||||
j = i;
|
|
||||||
if (i < 0) {
|
|
||||||
std::tie(i, j) = m_intersections[-i - 1];
|
|
||||||
assert(assert_intersection_valid(i, j));
|
|
||||||
goto end;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (const ClipperLib_Z::IntPoint& pt : contour) {
|
|
||||||
j = pt.z();
|
j = pt.z();
|
||||||
if (j < 0) {
|
if (j < 0) {
|
||||||
std::tie(i, j) = m_intersections[-j - 1];
|
const auto &intersection = m_intersections[-j - 1];
|
||||||
|
assert(intersection.first <= intersection.second);
|
||||||
|
if (intersection.second < m_offset_above) {
|
||||||
|
// Ignore intersection of polygons on the 1st layer.
|
||||||
|
assert(intersection.first >= m_offset_below);
|
||||||
|
j = i;
|
||||||
|
} else if (intersection.first >= m_offset_above) {
|
||||||
|
// Ignore intersection of polygons on the 2nd layer
|
||||||
|
assert(intersection.second < m_offset_end);
|
||||||
|
j = i;
|
||||||
|
} else {
|
||||||
|
std::tie(i, j) = m_intersections[-j - 1];
|
||||||
|
assert(assert_intersection_valid(i, j));
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
} else if (i == -1) {
|
||||||
|
// First source contour of this expolygon was found.
|
||||||
|
i = j;
|
||||||
|
} else if (i != j) {
|
||||||
|
// Second source contour of this expolygon was found.
|
||||||
|
if (i > j)
|
||||||
|
std::swap(i, j);
|
||||||
assert(assert_intersection_valid(i, j));
|
assert(assert_intersection_valid(i, j));
|
||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
else if (i != j)
|
|
||||||
goto end;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
end:
|
end:
|
||||||
bool found = false;
|
bool found = false;
|
||||||
if (i == j) {
|
if (i == -1) {
|
||||||
|
// This should not happen. It may only happen if the source contours had just self intersections or intersections with contours at the same layer.
|
||||||
|
assert(false);
|
||||||
|
} else if (i == j) {
|
||||||
// The contour is completely inside another contour.
|
// The contour is completely inside another contour.
|
||||||
Point pt(polynode.Contour.front().x(), polynode.Contour.front().y());
|
Point pt(polynode.Contour.front().x(), polynode.Contour.front().y());
|
||||||
if (i < m_offset_above) {
|
if (i < m_offset_above) {
|
||||||
@ -202,8 +197,6 @@ static void connect_layer_slices(
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
assert(assert_intersection_valid(i, j));
|
assert(assert_intersection_valid(i, j));
|
||||||
if (i > j)
|
|
||||||
std::swap(i, j);
|
|
||||||
i -= m_offset_below;
|
i -= m_offset_below;
|
||||||
j -= m_offset_above;
|
j -= m_offset_above;
|
||||||
assert(i >= 0 && i < m_below.lslices_ex.size());
|
assert(i >= 0 && i < m_below.lslices_ex.size());
|
||||||
@ -524,6 +517,9 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
// If the current layer consists of multiple regions, then the fill_expolygons above are split by the source LayerRegion surfaces.
|
// If the current layer consists of multiple regions, then the fill_expolygons above are split by the source LayerRegion surfaces.
|
||||||
const std::vector<uint32_t> &layer_region_ids)
|
const std::vector<uint32_t> &layer_region_ids)
|
||||||
{
|
{
|
||||||
|
assert(perimeter_and_gapfill_ranges.size() == fill_expolygons_ranges.size());
|
||||||
|
assert(! layer_region_ids.empty());
|
||||||
|
|
||||||
LayerRegion &this_layer_region = *m_regions[region_id];
|
LayerRegion &this_layer_region = *m_regions[region_id];
|
||||||
|
|
||||||
// Bounding boxes of fill_expolygons.
|
// Bounding boxes of fill_expolygons.
|
||||||
@ -532,7 +528,6 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
for (const ExPolygon &expolygon : fill_expolygons)
|
for (const ExPolygon &expolygon : fill_expolygons)
|
||||||
fill_expolygons_bboxes.emplace_back(get_extents(expolygon));
|
fill_expolygons_bboxes.emplace_back(get_extents(expolygon));
|
||||||
|
|
||||||
|
|
||||||
// Take one sample point for each source slice, to be used to sort source slices into layer slices.
|
// Take one sample point for each source slice, to be used to sort source slices into layer slices.
|
||||||
// source slice index + its sample.
|
// source slice index + its sample.
|
||||||
std::vector<std::pair<uint32_t, Point>> perimeter_slices_queue;
|
std::vector<std::pair<uint32_t, Point>> perimeter_slices_queue;
|
||||||
@ -544,7 +539,7 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
// Take a sample deep inside its island if available. Infills are usually quite far from the island boundary.
|
// Take a sample deep inside its island if available. Infills are usually quite far from the island boundary.
|
||||||
for (uint32_t iexpoly : fill_expolygons_ranges[islice])
|
for (uint32_t iexpoly : fill_expolygons_ranges[islice])
|
||||||
if (const ExPolygon &expoly = fill_expolygons[iexpoly]; ! expoly.empty()) {
|
if (const ExPolygon &expoly = fill_expolygons[iexpoly]; ! expoly.empty()) {
|
||||||
sample = expoly.contour.points.front();
|
sample = expoly.contour.points[expoly.contour.points.size() / 2];
|
||||||
sample_set = true;
|
sample_set = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -555,12 +550,12 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
if (ee.is_collection()) {
|
if (ee.is_collection()) {
|
||||||
for (const ExtrusionEntity *ee2 : dynamic_cast<const ExtrusionEntityCollection&>(ee).entities)
|
for (const ExtrusionEntity *ee2 : dynamic_cast<const ExtrusionEntityCollection&>(ee).entities)
|
||||||
if (! ee2->role().is_external()) {
|
if (! ee2->role().is_external()) {
|
||||||
sample = ee2->first_point();
|
sample = ee2->middle_point();
|
||||||
sample_set = true;
|
sample_set = true;
|
||||||
goto loop_end;
|
goto loop_end;
|
||||||
}
|
}
|
||||||
} else if (! ee.role().is_external()) {
|
} else if (! ee.role().is_external()) {
|
||||||
sample = ee.first_point();
|
sample = ee.middle_point();
|
||||||
sample_set = true;
|
sample_set = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -569,12 +564,12 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
if (! sample_set) {
|
if (! sample_set) {
|
||||||
if (! extrusions.second.empty()) {
|
if (! extrusions.second.empty()) {
|
||||||
// If there is no inner perimeter, take a sample of some gap fill extrusion.
|
// If there is no inner perimeter, take a sample of some gap fill extrusion.
|
||||||
sample = this_layer_region.thin_fills().entities[*extrusions.second.begin()]->first_point();
|
sample = this_layer_region.thin_fills().entities[*extrusions.second.begin()]->middle_point();
|
||||||
sample_set = true;
|
sample_set = true;
|
||||||
}
|
}
|
||||||
if (! sample_set && ! extrusions.first.empty()) {
|
if (! sample_set && ! extrusions.first.empty()) {
|
||||||
// As a last resort, take a sample of some external perimeter.
|
// As a last resort, take a sample of some external perimeter.
|
||||||
sample = this_layer_region.perimeters().entities[*extrusions.first.begin()]->first_point();
|
sample = this_layer_region.perimeters().entities[*extrusions.first.begin()]->middle_point();
|
||||||
sample_set = true;
|
sample_set = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -587,7 +582,11 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
|
|
||||||
// Map of source fill_expolygon into region and fill_expolygon of that region.
|
// Map of source fill_expolygon into region and fill_expolygon of that region.
|
||||||
// -1: not set
|
// -1: not set
|
||||||
std::vector<std::pair<int, int>> map_expolygon_to_region_and_fill;
|
struct RegionWithFillIndex {
|
||||||
|
int region_id{ -1 };
|
||||||
|
int fill_in_region_id{ -1 };
|
||||||
|
};
|
||||||
|
std::vector<RegionWithFillIndex> map_expolygon_to_region_and_fill;
|
||||||
const bool has_multiple_regions = layer_region_ids.size() > 1;
|
const bool has_multiple_regions = layer_region_ids.size() > 1;
|
||||||
assert(has_multiple_regions || layer_region_ids.size() == 1);
|
assert(has_multiple_regions || layer_region_ids.size() == 1);
|
||||||
// assign fill_surfaces to each layer
|
// assign fill_surfaces to each layer
|
||||||
@ -601,7 +600,7 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
const BoundingBox &bbr = fill_expolygons_bboxes[rhs];
|
const BoundingBox &bbr = fill_expolygons_bboxes[rhs];
|
||||||
return bbl.min < bbr.min || (bbl.min == bbr.min && bbl.max < bbr.max);
|
return bbl.min < bbr.min || (bbl.min == bbr.min && bbl.max < bbr.max);
|
||||||
});
|
});
|
||||||
map_expolygon_to_region_and_fill.assign(fill_expolygons.size(), std::make_pair(-1, -1));
|
map_expolygon_to_region_and_fill.assign(fill_expolygons.size(), {});
|
||||||
for (uint32_t region_idx : layer_region_ids) {
|
for (uint32_t region_idx : layer_region_ids) {
|
||||||
LayerRegion &l = *m_regions[region_idx];
|
LayerRegion &l = *m_regions[region_idx];
|
||||||
l.m_fill_expolygons = intersection_ex(l.slices().surfaces, fill_expolygons);
|
l.m_fill_expolygons = intersection_ex(l.slices().surfaces, fill_expolygons);
|
||||||
@ -617,23 +616,80 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
if (uint32_t fill_id = *it_bbox; fill_expolygons_bboxes[fill_id] == bbox) {
|
if (uint32_t fill_id = *it_bbox; fill_expolygons_bboxes[fill_id] == bbox) {
|
||||||
// With a very high probability the two expolygons match exactly. Confirm that.
|
// With a very high probability the two expolygons match exactly. Confirm that.
|
||||||
if (expolygons_match(expolygon, fill_expolygons[fill_id])) {
|
if (expolygons_match(expolygon, fill_expolygons[fill_id])) {
|
||||||
std::pair<int, int> &ref = map_expolygon_to_region_and_fill[fill_id];
|
RegionWithFillIndex &ref = map_expolygon_to_region_and_fill[fill_id];
|
||||||
// Only one expolygon produced by intersection with LayerRegion surface may match an expolygon of fill_expolygons.
|
// Only one expolygon produced by intersection with LayerRegion surface may match an expolygon of fill_expolygons.
|
||||||
assert(ref.first == -1);
|
assert(ref.region_id == -1 && ref.fill_in_region_id == -1);
|
||||||
ref.first = region_idx;
|
ref.region_id = region_idx;
|
||||||
ref.second = int(&expolygon - l.fill_expolygons().data());
|
ref.fill_in_region_id = int(&expolygon - l.fill_expolygons().data());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// Check whether any island contains multiple fills that fall into the same region, but not they are not contiguous.
|
||||||
|
// If so, sort fills in that particular region so that fills of an island become contiguous.
|
||||||
|
// Index of a region to sort.
|
||||||
|
int sort_region_id = -1;
|
||||||
|
// Temporary vector of fills for reordering.
|
||||||
|
ExPolygons fills_temp;
|
||||||
|
// Vector of new positions of the above.
|
||||||
|
std::vector<int> new_positions;
|
||||||
|
do {
|
||||||
|
sort_region_id = -1;
|
||||||
|
for (size_t source_slice_idx = 0; source_slice_idx < fill_expolygons_ranges.size(); ++ source_slice_idx)
|
||||||
|
if (ExPolygonRange fill_range = fill_expolygons_ranges[source_slice_idx]; fill_range.size() > 1) {
|
||||||
|
// More than one expolygon exists for a single island. Check whether they are contiguous inside a single LayerRegion::fill_expolygons() vector.
|
||||||
|
uint32_t fill_idx = *fill_range.begin();
|
||||||
|
if (const int fill_regon_id = map_expolygon_to_region_and_fill[fill_idx].region_id; fill_regon_id != -1) {
|
||||||
|
int fill_in_region_id = map_expolygon_to_region_and_fill[fill_idx].fill_in_region_id;
|
||||||
|
bool needs_sorting = false;
|
||||||
|
for (++ fill_idx; fill_idx != *fill_range.end(); ++ fill_idx) {
|
||||||
|
if (const RegionWithFillIndex &ref = map_expolygon_to_region_and_fill[fill_idx]; ref.region_id != fill_regon_id) {
|
||||||
|
// This island has expolygons split among multiple regions.
|
||||||
|
needs_sorting = false;
|
||||||
|
break;
|
||||||
|
} else if (ref.fill_in_region_id != ++ fill_in_region_id) {
|
||||||
|
// This island has all expolygons stored inside the same region, but not sorted.
|
||||||
|
needs_sorting = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (needs_sorting) {
|
||||||
|
sort_region_id = fill_regon_id;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (sort_region_id != -1) {
|
||||||
|
// Reorder fills in region with sort_region index.
|
||||||
|
LayerRegion &layerm = *m_regions[sort_region_id];
|
||||||
|
new_positions.assign(layerm.fill_expolygons().size(), -1);
|
||||||
|
int last = 0;
|
||||||
|
for (RegionWithFillIndex &ref : map_expolygon_to_region_and_fill)
|
||||||
|
if (ref.region_id == sort_region_id) {
|
||||||
|
new_positions[ref.fill_in_region_id] = last;
|
||||||
|
ref.fill_in_region_id = last ++;
|
||||||
|
}
|
||||||
|
for (auto &new_pos : new_positions)
|
||||||
|
if (new_pos == -1)
|
||||||
|
// Not referenced by any map_expolygon_to_region_and_fill.
|
||||||
|
new_pos = last ++;
|
||||||
|
// Move just the content of m_fill_expolygons to fills_temp, but don't move the container vector.
|
||||||
|
auto &fills = layerm.m_fill_expolygons;
|
||||||
|
assert(last == int(fills.size()));
|
||||||
|
fills_temp.reserve(fills.size());
|
||||||
|
fills_temp.insert(fills_temp.end(), std::make_move_iterator(fills.begin()), std::make_move_iterator(fills.end()));
|
||||||
|
for (ExPolygon &ex : fills)
|
||||||
|
ex.clear();
|
||||||
|
// Move / reoder the expolygons back into m_fill_expolygons.
|
||||||
|
for (size_t old_pos = 0; old_pos < new_positions.size(); ++ old_pos)
|
||||||
|
fills[new_positions[old_pos]] = std::move(fills_temp[old_pos]);
|
||||||
|
}
|
||||||
|
} while (sort_region_id != -1);
|
||||||
} else {
|
} else {
|
||||||
this_layer_region.m_fill_expolygons = std::move(fill_expolygons);
|
this_layer_region.m_fill_expolygons = std::move(fill_expolygons);
|
||||||
this_layer_region.m_fill_expolygons_bboxes = std::move(fill_expolygons_bboxes);
|
this_layer_region.m_fill_expolygons_bboxes = std::move(fill_expolygons_bboxes);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Sort perimeter extrusions, thin fill extrusions and fill expolygons into islands.
|
|
||||||
std::vector<uint32_t> region_fill_sorted_last;
|
|
||||||
auto insert_into_island = [
|
auto insert_into_island = [
|
||||||
// Region where the perimeters, gap fills and fill expolygons are stored.
|
// Region where the perimeters, gap fills and fill expolygons are stored.
|
||||||
region_id,
|
region_id,
|
||||||
@ -646,10 +702,7 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
// Mapping of fill_expolygon to region and its infill.
|
// Mapping of fill_expolygon to region and its infill.
|
||||||
&map_expolygon_to_region_and_fill,
|
&map_expolygon_to_region_and_fill,
|
||||||
// Output
|
// Output
|
||||||
®ions = m_regions, &lslices_ex = this->lslices_ex,
|
®ions = m_regions, &lslices_ex = this->lslices_ex]
|
||||||
// fill_expolygons and fill_expolygons_bboxes need to be sorted into contiguous sequence by island,
|
|
||||||
// thus region_fill_sorted_last contains last fill_expolygon processed (meaning sorted).
|
|
||||||
®ion_fill_sorted_last]
|
|
||||||
(int lslice_idx, int source_slice_idx) {
|
(int lslice_idx, int source_slice_idx) {
|
||||||
lslices_ex[lslice_idx].islands.push_back({});
|
lslices_ex[lslice_idx].islands.push_back({});
|
||||||
LayerIsland &island = lslices_ex[lslice_idx].islands.back();
|
LayerIsland &island = lslices_ex[lslice_idx].islands.back();
|
||||||
@ -660,12 +713,12 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
// Check whether the fill expolygons of this island were split into multiple regions.
|
// Check whether the fill expolygons of this island were split into multiple regions.
|
||||||
island.fill_region_id = LayerIsland::fill_region_composite_id;
|
island.fill_region_id = LayerIsland::fill_region_composite_id;
|
||||||
for (uint32_t fill_idx : fill_range) {
|
for (uint32_t fill_idx : fill_range) {
|
||||||
const std::pair<int, int> &kvp = map_expolygon_to_region_and_fill[fill_idx];
|
if (const int fill_regon_id = map_expolygon_to_region_and_fill[fill_idx].region_id;
|
||||||
if (kvp.first == -1 || (island.fill_region_id != -1 && island.fill_region_id != kvp.second)) {
|
fill_regon_id == -1 || (island.fill_region_id != LayerIsland::fill_region_composite_id && island.fill_region_id != fill_regon_id)) {
|
||||||
island.fill_region_id = LayerIsland::fill_region_composite_id;
|
island.fill_region_id = LayerIsland::fill_region_composite_id;
|
||||||
break;
|
break;
|
||||||
} else
|
} else
|
||||||
island.fill_region_id = kvp.second;
|
island.fill_region_id = fill_regon_id;
|
||||||
}
|
}
|
||||||
if (island.fill_expolygons_composite()) {
|
if (island.fill_expolygons_composite()) {
|
||||||
// They were split, thus store the unsplit "composite" expolygons into the region of perimeters.
|
// They were split, thus store the unsplit "composite" expolygons into the region of perimeters.
|
||||||
@ -677,23 +730,10 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
fill_expolygons_bboxes.begin() + *fill_range.begin(), fill_expolygons_bboxes.begin() + *fill_range.end());
|
fill_expolygons_bboxes.begin() + *fill_range.begin(), fill_expolygons_bboxes.begin() + *fill_range.end());
|
||||||
island.fill_expolygons = ExPolygonRange(begin, uint32_t(this_layer_region.fill_expolygons_composite().size()));
|
island.fill_expolygons = ExPolygonRange(begin, uint32_t(this_layer_region.fill_expolygons_composite().size()));
|
||||||
} else {
|
} else {
|
||||||
if (region_fill_sorted_last.empty())
|
// All expolygons are stored inside a single LayerRegion in a contiguous range.
|
||||||
region_fill_sorted_last.assign(regions.size(), 0);
|
island.fill_expolygons = ExPolygonRange(
|
||||||
uint32_t &last = region_fill_sorted_last[island.fill_region_id];
|
map_expolygon_to_region_and_fill[*fill_range.begin()].fill_in_region_id,
|
||||||
// They were not split and they belong to the same region.
|
map_expolygon_to_region_and_fill[*fill_range.end() - 1].fill_in_region_id + 1);
|
||||||
// Sort the region m_fill_expolygons to a continuous span.
|
|
||||||
uint32_t begin = last;
|
|
||||||
LayerRegion &layerm = *regions[island.fill_region_id];
|
|
||||||
for (uint32_t fill_id : fill_range) {
|
|
||||||
uint32_t region_fill_id = map_expolygon_to_region_and_fill[fill_id].second;
|
|
||||||
assert(region_fill_id >= last);
|
|
||||||
if (region_fill_id > last) {
|
|
||||||
std::swap(layerm.m_fill_expolygons[region_fill_id], layerm.m_fill_expolygons[last]);
|
|
||||||
std::swap(layerm.m_fill_expolygons_bboxes[region_fill_id], layerm.m_fill_expolygons_bboxes[last]);
|
|
||||||
}
|
|
||||||
++ last;
|
|
||||||
}
|
|
||||||
island.fill_expolygons = ExPolygonRange(begin, last);
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Layer island is made of one fill region only.
|
// Layer island is made of one fill region only.
|
||||||
@ -756,6 +796,15 @@ void Layer::sort_perimeters_into_islands(
|
|||||||
d2min = d2;
|
d2min = d2;
|
||||||
lslice_idx_min = lslice_idx;
|
lslice_idx_min = lslice_idx;
|
||||||
}
|
}
|
||||||
|
if (lslice_idx_min == -1) {
|
||||||
|
// This should not happen, but Arachne seems to produce a perimeter point far outside its source contour.
|
||||||
|
// As a last resort, find the closest source contours to the sample point.
|
||||||
|
for (int lslice_idx = int(lslices_ex.size()) - 1; lslice_idx >= 0; -- lslice_idx)
|
||||||
|
if (double d2 = (lslices[lslice_idx].point_projection(it_source_slice->second) - it_source_slice->second).cast<double>().squaredNorm(); d2 < d2min) {
|
||||||
|
d2min = d2;
|
||||||
|
lslice_idx_min = lslice_idx;
|
||||||
|
}
|
||||||
|
}
|
||||||
assert(lslice_idx_min != -1);
|
assert(lslice_idx_min != -1);
|
||||||
insert_into_island(lslice_idx_min, it_source_slice->first);
|
insert_into_island(lslice_idx_min, it_source_slice->first);
|
||||||
}
|
}
|
||||||
|
@ -318,7 +318,7 @@ public:
|
|||||||
|
|
||||||
Layer *upper_layer;
|
Layer *upper_layer;
|
||||||
Layer *lower_layer;
|
Layer *lower_layer;
|
||||||
bool slicing_errors;
|
// bool slicing_errors;
|
||||||
coordf_t slice_z; // Z used for slicing in unscaled coordinates
|
coordf_t slice_z; // Z used for slicing in unscaled coordinates
|
||||||
coordf_t print_z; // Z used for printing in unscaled coordinates
|
coordf_t print_z; // Z used for printing in unscaled coordinates
|
||||||
coordf_t height; // layer height in unscaled coordinates
|
coordf_t height; // layer height in unscaled coordinates
|
||||||
@ -387,7 +387,8 @@ protected:
|
|||||||
friend std::string fix_slicing_errors(LayerPtrs&, const std::function<void()>&);
|
friend std::string fix_slicing_errors(LayerPtrs&, const std::function<void()>&);
|
||||||
|
|
||||||
Layer(size_t id, PrintObject *object, coordf_t height, coordf_t print_z, coordf_t slice_z) :
|
Layer(size_t id, PrintObject *object, coordf_t height, coordf_t print_z, coordf_t slice_z) :
|
||||||
upper_layer(nullptr), lower_layer(nullptr), slicing_errors(false),
|
upper_layer(nullptr), lower_layer(nullptr),
|
||||||
|
//slicing_errors(false),
|
||||||
slice_z(slice_z), print_z(print_z), height(height),
|
slice_z(slice_z), print_z(print_z), height(height),
|
||||||
m_id(id), m_object(object) {}
|
m_id(id), m_object(object) {}
|
||||||
virtual ~Layer();
|
virtual ~Layer();
|
||||||
|
@ -1305,7 +1305,9 @@ void ModelObject::synchronize_model_after_cut()
|
|||||||
void ModelObject::apply_cut_attributes(ModelObjectCutAttributes attributes)
|
void ModelObject::apply_cut_attributes(ModelObjectCutAttributes attributes)
|
||||||
{
|
{
|
||||||
// we don't save cut information, if result will not contains all parts of initial object
|
// we don't save cut information, if result will not contains all parts of initial object
|
||||||
if (!attributes.has(ModelObjectCutAttribute::KeepUpper) || !attributes.has(ModelObjectCutAttribute::KeepLower))
|
if (!attributes.has(ModelObjectCutAttribute::KeepUpper) ||
|
||||||
|
!attributes.has(ModelObjectCutAttribute::KeepLower) ||
|
||||||
|
attributes.has(ModelObjectCutAttribute::InvalidateCutInfo))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (cut_id.id().invalid())
|
if (cut_id.id().invalid())
|
||||||
@ -1341,7 +1343,7 @@ void ModelVolume::reset_extra_facets()
|
|||||||
void ModelVolume::apply_tolerance()
|
void ModelVolume::apply_tolerance()
|
||||||
{
|
{
|
||||||
assert(cut_info.is_connector);
|
assert(cut_info.is_connector);
|
||||||
if (cut_info.is_processed)
|
if (!cut_info.is_processed)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
Vec3d sf = get_scaling_factor();
|
Vec3d sf = get_scaling_factor();
|
||||||
@ -1352,11 +1354,11 @@ void ModelVolume::apply_tolerance()
|
|||||||
vol->set_offset(pos);
|
vol->set_offset(pos);
|
||||||
*/
|
*/
|
||||||
// make a "hole" wider
|
// make a "hole" wider
|
||||||
sf[X] *= 1. + double(cut_info.radius_tolerance);
|
sf[X] += double(cut_info.radius_tolerance);
|
||||||
sf[Y] *= 1. + double(cut_info.radius_tolerance);
|
sf[Y] += double(cut_info.radius_tolerance);
|
||||||
|
|
||||||
// make a "hole" dipper
|
// make a "hole" dipper
|
||||||
sf[Z] *= 1. + double(cut_info.height_tolerance);
|
sf[Z] += double(cut_info.height_tolerance);
|
||||||
|
|
||||||
set_scaling_factor(sf);
|
set_scaling_factor(sf);
|
||||||
}
|
}
|
||||||
@ -1425,7 +1427,7 @@ void ModelObject::process_modifier_cut(ModelVolume* volume, const Transform3d& i
|
|||||||
lower->add_volume(*volume);
|
lower->add_volume(*volume);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void add_cut_volume(TriangleMesh& mesh, ModelObject* object, const ModelVolume* src_volume, const Transform3d& cut_matrix)
|
static void add_cut_volume(TriangleMesh& mesh, ModelObject* object, const ModelVolume* src_volume, const Transform3d& cut_matrix, const std::string& suffix = {})
|
||||||
{
|
{
|
||||||
if (mesh.empty())
|
if (mesh.empty())
|
||||||
return;
|
return;
|
||||||
@ -1433,7 +1435,7 @@ static void add_cut_volume(TriangleMesh& mesh, ModelObject* object, const ModelV
|
|||||||
mesh.transform(cut_matrix);
|
mesh.transform(cut_matrix);
|
||||||
ModelVolume* vol = object->add_volume(mesh);
|
ModelVolume* vol = object->add_volume(mesh);
|
||||||
|
|
||||||
vol->name = src_volume->name;
|
vol->name = src_volume->name + suffix;
|
||||||
// Don't copy the config's ID.
|
// Don't copy the config's ID.
|
||||||
vol->config.assign_config(src_volume->config);
|
vol->config.assign_config(src_volume->config);
|
||||||
assert(vol->config.id().valid());
|
assert(vol->config.id().valid());
|
||||||
@ -1477,6 +1479,12 @@ void ModelObject::process_solid_part_cut(ModelVolume* volume, const Transform3d&
|
|||||||
|
|
||||||
// Add required cut parts to the objects
|
// Add required cut parts to the objects
|
||||||
|
|
||||||
|
if (attributes.has(ModelObjectCutAttribute::KeepAsParts)) {
|
||||||
|
add_cut_volume(upper_mesh, upper, volume, cut_matrix, "_A");
|
||||||
|
add_cut_volume(lower_mesh, upper, volume, cut_matrix, "_B");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (attributes.has(ModelObjectCutAttribute::KeepUpper))
|
if (attributes.has(ModelObjectCutAttribute::KeepUpper))
|
||||||
add_cut_volume(upper_mesh, upper, volume, cut_matrix);
|
add_cut_volume(upper_mesh, upper, volume, cut_matrix);
|
||||||
|
|
||||||
@ -1560,7 +1568,7 @@ ModelObjectPtrs ModelObject::cut(size_t instance, const Transform3d& cut_matrix,
|
|||||||
clone_for_cut(&upper);
|
clone_for_cut(&upper);
|
||||||
|
|
||||||
ModelObject* lower{ nullptr };
|
ModelObject* lower{ nullptr };
|
||||||
if (attributes.has(ModelObjectCutAttribute::KeepLower))
|
if (attributes.has(ModelObjectCutAttribute::KeepLower) && !attributes.has(ModelObjectCutAttribute::KeepAsParts))
|
||||||
clone_for_cut(&lower);
|
clone_for_cut(&lower);
|
||||||
|
|
||||||
std::vector<ModelObject*> dowels;
|
std::vector<ModelObject*> dowels;
|
||||||
@ -1608,34 +1616,40 @@ ModelObjectPtrs ModelObject::cut(size_t instance, const Transform3d& cut_matrix,
|
|||||||
|
|
||||||
ModelObjectPtrs res;
|
ModelObjectPtrs res;
|
||||||
|
|
||||||
if (attributes.has(ModelObjectCutAttribute::KeepUpper) && !upper->volumes.empty()) {
|
if (attributes.has(ModelObjectCutAttribute::KeepAsParts) && !upper->volumes.empty()) {
|
||||||
invalidate_translations(upper, instances[instance]);
|
reset_instance_transformation(upper, instance, cut_matrix);
|
||||||
|
|
||||||
reset_instance_transformation(upper, instance, cut_matrix,
|
|
||||||
attributes.has(ModelObjectCutAttribute::PlaceOnCutUpper),
|
|
||||||
attributes.has(ModelObjectCutAttribute::FlipUpper),
|
|
||||||
local_displace);
|
|
||||||
res.push_back(upper);
|
res.push_back(upper);
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
if (attributes.has(ModelObjectCutAttribute::KeepUpper) && !upper->volumes.empty()) {
|
||||||
|
invalidate_translations(upper, instances[instance]);
|
||||||
|
|
||||||
if (attributes.has(ModelObjectCutAttribute::KeepLower) && !lower->volumes.empty()) {
|
reset_instance_transformation(upper, instance, cut_matrix,
|
||||||
invalidate_translations(lower, instances[instance]);
|
attributes.has(ModelObjectCutAttribute::PlaceOnCutUpper),
|
||||||
|
attributes.has(ModelObjectCutAttribute::FlipUpper),
|
||||||
|
local_displace);
|
||||||
|
res.push_back(upper);
|
||||||
|
}
|
||||||
|
|
||||||
reset_instance_transformation(lower, instance, cut_matrix,
|
if (attributes.has(ModelObjectCutAttribute::KeepLower) && !lower->volumes.empty()) {
|
||||||
attributes.has(ModelObjectCutAttribute::PlaceOnCutLower),
|
invalidate_translations(lower, instances[instance]);
|
||||||
attributes.has(ModelObjectCutAttribute::PlaceOnCutLower) ? true : attributes.has(ModelObjectCutAttribute::FlipLower));
|
|
||||||
res.push_back(lower);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (attributes.has(ModelObjectCutAttribute::CreateDowels) && !dowels.empty()) {
|
reset_instance_transformation(lower, instance, cut_matrix,
|
||||||
for (auto dowel : dowels) {
|
attributes.has(ModelObjectCutAttribute::PlaceOnCutLower),
|
||||||
invalidate_translations(dowel, instances[instance]);
|
attributes.has(ModelObjectCutAttribute::PlaceOnCutLower) ? true : attributes.has(ModelObjectCutAttribute::FlipLower));
|
||||||
|
res.push_back(lower);
|
||||||
|
}
|
||||||
|
|
||||||
reset_instance_transformation(dowel, instance, Transform3d::Identity(), false, false, local_dowels_displace);
|
if (attributes.has(ModelObjectCutAttribute::CreateDowels) && !dowels.empty()) {
|
||||||
|
for (auto dowel : dowels) {
|
||||||
|
invalidate_translations(dowel, instances[instance]);
|
||||||
|
|
||||||
local_dowels_displace += dowel->full_raw_mesh_bounding_box().size().cwiseProduct(Vec3d(-1.5, -1.5, 0.0));
|
reset_instance_transformation(dowel, instance, Transform3d::Identity(), false, false, local_dowels_displace);
|
||||||
dowel->name += "-Dowel-" + dowel->volumes[0]->name;
|
|
||||||
res.push_back(dowel);
|
local_dowels_displace += dowel->full_raw_mesh_bounding_box().size().cwiseProduct(Vec3d(-1.5, -1.5, 0.0));
|
||||||
|
dowel->name += "-Dowel-" + dowel->volumes[0]->name;
|
||||||
|
res.push_back(dowel);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -316,7 +316,7 @@ enum class ModelVolumeType : int {
|
|||||||
SUPPORT_ENFORCER,
|
SUPPORT_ENFORCER,
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class ModelObjectCutAttribute : int { KeepUpper, KeepLower, FlipUpper, FlipLower, PlaceOnCutUpper, PlaceOnCutLower, CreateDowels };
|
enum class ModelObjectCutAttribute : int { KeepUpper, KeepLower, KeepAsParts, FlipUpper, FlipLower, PlaceOnCutUpper, PlaceOnCutLower, CreateDowels, InvalidateCutInfo };
|
||||||
using ModelObjectCutAttributes = enum_bitmask<ModelObjectCutAttribute>;
|
using ModelObjectCutAttributes = enum_bitmask<ModelObjectCutAttribute>;
|
||||||
ENABLE_ENUM_BITMASK_OPERATORS(ModelObjectCutAttribute);
|
ENABLE_ENUM_BITMASK_OPERATORS(ModelObjectCutAttribute);
|
||||||
|
|
||||||
@ -385,6 +385,10 @@ public:
|
|||||||
bool is_mm_painted() const;
|
bool is_mm_painted() const;
|
||||||
// Checks if object contains just one volume and it's a text
|
// Checks if object contains just one volume and it's a text
|
||||||
bool is_text() const;
|
bool is_text() const;
|
||||||
|
// This object may have a varying layer height by painting or by a table.
|
||||||
|
// Even if true is returned, the layer height profile may be "flat" with no difference to default layering.
|
||||||
|
bool has_custom_layering() const
|
||||||
|
{ return ! this->layer_config_ranges.empty() || ! this->layer_height_profile.empty(); }
|
||||||
|
|
||||||
ModelInstance* add_instance();
|
ModelInstance* add_instance();
|
||||||
ModelInstance* add_instance(const ModelInstance &instance);
|
ModelInstance* add_instance(const ModelInstance &instance);
|
||||||
|
@ -678,25 +678,62 @@ bool paths_touch(const ExtrusionPath &path_one, const ExtrusionPath &path_two, d
|
|||||||
|
|
||||||
ExtrusionPaths reconnect_extrusion_paths(const ExtrusionPaths& paths, double limit_distance) {
|
ExtrusionPaths reconnect_extrusion_paths(const ExtrusionPaths& paths, double limit_distance) {
|
||||||
if (paths.empty()) return paths;
|
if (paths.empty()) return paths;
|
||||||
ExtrusionPaths result;
|
|
||||||
result.push_back(paths.front());
|
std::unordered_map<size_t, ExtrusionPath> connected;
|
||||||
for (size_t pidx = 1; pidx < paths.size(); pidx++) {
|
connected.reserve(paths.size());
|
||||||
if ((result.back().last_point() - paths[pidx].first_point()).cast<double>().squaredNorm() < limit_distance * limit_distance) {
|
for (size_t i = 0; i < paths.size(); i++) {
|
||||||
result.back().polyline.points.insert(result.back().polyline.points.end(), paths[pidx].polyline.points.begin(),
|
if (!paths[i].empty()) {
|
||||||
paths[pidx].polyline.points.end());
|
connected.emplace(i, paths[i]);
|
||||||
} else {
|
|
||||||
result.push_back(paths[pidx]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (size_t a = 0; a < paths.size(); a++) {
|
||||||
|
if (connected.find(a) == connected.end()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
ExtrusionPath &base = connected.at(a);
|
||||||
|
for (size_t b = a + 1; b < paths.size(); b++) {
|
||||||
|
if (connected.find(b) == connected.end()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
ExtrusionPath &next = connected.at(b);
|
||||||
|
if ((base.last_point() - next.first_point()).cast<double>().squaredNorm() < limit_distance * limit_distance) {
|
||||||
|
base.polyline.append(std::move(next.polyline));
|
||||||
|
connected.erase(b);
|
||||||
|
} else if ((base.last_point() - next.last_point()).cast<double>().squaredNorm() < limit_distance * limit_distance) {
|
||||||
|
base.polyline.points.insert(base.polyline.points.end(), next.polyline.points.rbegin(), next.polyline.points.rend());
|
||||||
|
connected.erase(b);
|
||||||
|
} else if ((base.first_point() - next.last_point()).cast<double>().squaredNorm() < limit_distance * limit_distance) {
|
||||||
|
next.polyline.append(std::move(base.polyline));
|
||||||
|
base = std::move(next);
|
||||||
|
base.reverse();
|
||||||
|
connected.erase(b);
|
||||||
|
} else if ((base.first_point() - next.first_point()).cast<double>().squaredNorm() < limit_distance * limit_distance) {
|
||||||
|
base.reverse();
|
||||||
|
base.polyline.append(std::move(next.polyline));
|
||||||
|
base.reverse();
|
||||||
|
connected.erase(b);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
ExtrusionPaths result;
|
||||||
|
for (auto& ext : connected) {
|
||||||
|
result.push_back(std::move(ext.second));
|
||||||
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPaths> &extra_perims, double touch_distance)
|
ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPaths> &extra_perims, double extrusion_spacing)
|
||||||
{
|
{
|
||||||
std::vector<ExtrusionPaths> connected_shells;
|
std::vector<ExtrusionPaths> connected_shells;
|
||||||
for (const ExtrusionPaths& ps : extra_perims) {
|
connected_shells.reserve(extra_perims.size());
|
||||||
connected_shells.push_back(reconnect_extrusion_paths(ps, touch_distance));
|
for (const ExtrusionPaths &ps : extra_perims) {
|
||||||
|
// this will also filter away empty paths
|
||||||
|
connected_shells.push_back(reconnect_extrusion_paths(ps, 1.0 * extrusion_spacing));
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Pidx
|
struct Pidx
|
||||||
{
|
{
|
||||||
size_t shell;
|
size_t shell;
|
||||||
@ -710,8 +747,6 @@ ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPath
|
|||||||
|
|
||||||
auto get_path = [&](Pidx i) { return connected_shells[i.shell][i.path]; };
|
auto get_path = [&](Pidx i) { return connected_shells[i.shell][i.path]; };
|
||||||
|
|
||||||
Point current_point{};
|
|
||||||
bool any_point_found = false;
|
|
||||||
std::vector<std::unordered_map<Pidx, std::unordered_set<Pidx, PidxHash>, PidxHash>> dependencies;
|
std::vector<std::unordered_map<Pidx, std::unordered_set<Pidx, PidxHash>, PidxHash>> dependencies;
|
||||||
for (size_t shell = 0; shell < connected_shells.size(); shell++) {
|
for (size_t shell = 0; shell < connected_shells.size(); shell++) {
|
||||||
dependencies.push_back({});
|
dependencies.push_back({});
|
||||||
@ -721,29 +756,37 @@ ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPath
|
|||||||
std::unordered_set<Pidx, PidxHash> current_dependencies{};
|
std::unordered_set<Pidx, PidxHash> current_dependencies{};
|
||||||
if (shell > 0) {
|
if (shell > 0) {
|
||||||
for (const auto &prev_path : dependencies[shell - 1]) {
|
for (const auto &prev_path : dependencies[shell - 1]) {
|
||||||
if (paths_touch(get_path(current_path), get_path(prev_path.first), touch_distance)) {
|
if (paths_touch(get_path(current_path), get_path(prev_path.first), extrusion_spacing * 1.5f)) {
|
||||||
current_dependencies.insert(prev_path.first);
|
current_dependencies.insert(prev_path.first);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
current_shell[current_path] = current_dependencies;
|
|
||||||
if (!any_point_found) {
|
|
||||||
current_point = get_path(current_path).first_point();
|
|
||||||
any_point_found = true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
current_shell[current_path] = current_dependencies;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Point current_point{};
|
||||||
|
for (const ExtrusionPaths &ps : connected_shells) {
|
||||||
|
for (const ExtrusionPath &p : ps) {
|
||||||
|
if (!p.empty()) {
|
||||||
|
current_point = p.first_point();
|
||||||
|
goto first_point_found;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
first_point_found:
|
||||||
|
|
||||||
ExtrusionPaths sorted_paths{};
|
ExtrusionPaths sorted_paths{};
|
||||||
Pidx npidx = Pidx{size_t(-1), 0};
|
Pidx npidx = Pidx{size_t(-1), 0};
|
||||||
Pidx next_pidx = npidx;
|
Pidx next_pidx = npidx;
|
||||||
bool reverse = false;
|
bool reverse = false;
|
||||||
while (true) {
|
while (true) {
|
||||||
if (next_pidx == npidx) { // find next pidx to print
|
if (next_pidx == npidx) { // find next pidx to print
|
||||||
double dist = std::numeric_limits<double>::max();
|
double dist = std::numeric_limits<double>::max();
|
||||||
for (size_t shell = 0; shell < dependencies.size(); shell++) {
|
for (size_t shell = 0; shell < dependencies.size(); shell++) {
|
||||||
for (const auto &p : dependencies[shell]) {
|
for (const auto &p : dependencies[shell]) {
|
||||||
if (!p.second.empty()) continue;
|
if (!p.second.empty())
|
||||||
|
continue;
|
||||||
const auto &path = get_path(p.first);
|
const auto &path = get_path(p.first);
|
||||||
double dist_a = (path.first_point() - current_point).cast<double>().squaredNorm();
|
double dist_a = (path.first_point() - current_point).cast<double>().squaredNorm();
|
||||||
if (dist_a < dist) {
|
if (dist_a < dist) {
|
||||||
@ -759,14 +802,21 @@ ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPath
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (next_pidx == npidx) { break; }
|
if (next_pidx == npidx) {
|
||||||
} else { // we have valid next_pidx, add it to the sorted paths, update dependencies, update current point and potentialy set new next_pidx
|
break;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// we have valid next_pidx, add it to the sorted paths, update dependencies, update current point and potentialy set new next_pidx
|
||||||
ExtrusionPath path = get_path(next_pidx);
|
ExtrusionPath path = get_path(next_pidx);
|
||||||
if (reverse) { path.reverse(); }
|
if (reverse) {
|
||||||
|
path.reverse();
|
||||||
|
}
|
||||||
sorted_paths.push_back(path);
|
sorted_paths.push_back(path);
|
||||||
current_point = sorted_paths.back().last_point();
|
current_point = sorted_paths.back().last_point();
|
||||||
if (next_pidx.shell < dependencies.size() - 1) {
|
if (next_pidx.shell < dependencies.size() - 1) {
|
||||||
for (auto &p : dependencies[next_pidx.shell + 1]) { p.second.erase(next_pidx); }
|
for (auto &p : dependencies[next_pidx.shell + 1]) {
|
||||||
|
p.second.erase(next_pidx);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
dependencies[next_pidx.shell].erase(next_pidx);
|
dependencies[next_pidx.shell].erase(next_pidx);
|
||||||
// check current and next shell for next pidx
|
// check current and next shell for next pidx
|
||||||
@ -775,9 +825,10 @@ ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPath
|
|||||||
next_pidx = npidx;
|
next_pidx = npidx;
|
||||||
for (size_t shell = current_shell; shell < std::min(current_shell + 2, dependencies.size()); shell++) {
|
for (size_t shell = current_shell; shell < std::min(current_shell + 2, dependencies.size()); shell++) {
|
||||||
for (const auto &p : dependencies[shell]) {
|
for (const auto &p : dependencies[shell]) {
|
||||||
if (!p.second.empty()) continue;
|
if (!p.second.empty())
|
||||||
const ExtrusionPath &next_path = get_path(p.first);
|
continue;
|
||||||
double dist_a = (next_path.first_point() - current_point).cast<double>().squaredNorm();
|
const ExtrusionPath &next_path = get_path(p.first);
|
||||||
|
double dist_a = (next_path.first_point() - current_point).cast<double>().squaredNorm();
|
||||||
if (dist_a < dist) {
|
if (dist_a < dist) {
|
||||||
dist = dist_a;
|
dist = dist_a;
|
||||||
next_pidx = p.first;
|
next_pidx = p.first;
|
||||||
@ -791,17 +842,30 @@ ExtrusionPaths sort_and_connect_extra_perimeters(const std::vector<ExtrusionPath
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (dist > scaled(5.0)){
|
if (dist > scaled(5.0)) {
|
||||||
next_pidx = npidx;
|
next_pidx = npidx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ExtrusionPaths reconnected = reconnect_extrusion_paths(sorted_paths, touch_distance);
|
ExtrusionPaths reconnected;
|
||||||
|
reconnected.reserve(sorted_paths.size());
|
||||||
|
for (const ExtrusionPath &path : sorted_paths) {
|
||||||
|
if (!reconnected.empty() && (reconnected.back().last_point() - path.first_point()).cast<double>().squaredNorm() <
|
||||||
|
extrusion_spacing * extrusion_spacing * 4.0) {
|
||||||
|
reconnected.back().polyline.points.insert(reconnected.back().polyline.points.end(), path.polyline.points.begin(),
|
||||||
|
path.polyline.points.end());
|
||||||
|
} else {
|
||||||
|
reconnected.push_back(path);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ExtrusionPaths filtered;
|
ExtrusionPaths filtered;
|
||||||
filtered.reserve(reconnected.size());
|
filtered.reserve(reconnected.size());
|
||||||
for (ExtrusionPath &p : reconnected) {
|
for (ExtrusionPath &p : reconnected) {
|
||||||
if (p.length() > touch_distance) { filtered.push_back(p); }
|
if (p.length() > 3 * extrusion_spacing) {
|
||||||
|
filtered.push_back(p);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return filtered;
|
return filtered;
|
||||||
@ -938,7 +1002,7 @@ std::tuple<std::vector<ExtrusionPaths>, Polygons> generate_extra_perimeters_over
|
|||||||
perimeter_polygon = intersection(offset(perimeter_polygon, -overhang_flow.scaled_spacing()), expanded_overhang_to_cover);
|
perimeter_polygon = intersection(offset(perimeter_polygon, -overhang_flow.scaled_spacing()), expanded_overhang_to_cover);
|
||||||
|
|
||||||
if (perimeter_polygon.empty()) { // fill possible gaps of single extrusion width
|
if (perimeter_polygon.empty()) { // fill possible gaps of single extrusion width
|
||||||
Polygons shrinked = offset(prev, -0.4 * overhang_flow.scaled_spacing());
|
Polygons shrinked = intersection(offset(prev, -0.3 * overhang_flow.scaled_spacing()), expanded_overhang_to_cover);
|
||||||
if (!shrinked.empty()) {
|
if (!shrinked.empty()) {
|
||||||
overhang_region.emplace_back();
|
overhang_region.emplace_back();
|
||||||
extrusion_paths_append(overhang_region.back(), perimeter, ExtrusionRole::OverhangPerimeter, overhang_flow.mm3_per_mm(),
|
extrusion_paths_append(overhang_region.back(), perimeter, ExtrusionRole::OverhangPerimeter, overhang_flow.mm3_per_mm(),
|
||||||
@ -946,15 +1010,13 @@ std::tuple<std::vector<ExtrusionPaths>, Polygons> generate_extra_perimeters_over
|
|||||||
}
|
}
|
||||||
|
|
||||||
Polylines fills;
|
Polylines fills;
|
||||||
ExPolygons gap = shrinked.empty() ? offset_ex(prev, overhang_flow.scaled_spacing() * 0.5) :
|
ExPolygons gap = shrinked.empty() ? offset_ex(prev, overhang_flow.scaled_spacing() * 0.5) : to_expolygons(shrinked);
|
||||||
offset_ex(prev, -overhang_flow.scaled_spacing() * 0.5);
|
|
||||||
|
|
||||||
//gap = expolygons_simplify(gap, overhang_flow.scaled_spacing());
|
|
||||||
for (const ExPolygon &ep : gap) {
|
for (const ExPolygon &ep : gap) {
|
||||||
ep.medial_axis(0.3 * overhang_flow.scaled_width(), overhang_flow.scaled_spacing() * 2.0, &fills);
|
ep.medial_axis(0.75 * overhang_flow.scaled_width(), 3.0 * overhang_flow.scaled_spacing(), &fills);
|
||||||
}
|
}
|
||||||
if (!fills.empty()) {
|
if (!fills.empty()) {
|
||||||
fills = intersection_pl(fills, inset_overhang_area);
|
fills = intersection_pl(fills, shrinked_overhang_to_cover);
|
||||||
overhang_region.emplace_back();
|
overhang_region.emplace_back();
|
||||||
extrusion_paths_append(overhang_region.back(), fills, ExtrusionRole::OverhangPerimeter, overhang_flow.mm3_per_mm(),
|
extrusion_paths_append(overhang_region.back(), fills, ExtrusionRole::OverhangPerimeter, overhang_flow.mm3_per_mm(),
|
||||||
overhang_flow.width(), overhang_flow.height());
|
overhang_flow.width(), overhang_flow.height());
|
||||||
@ -982,10 +1044,6 @@ std::tuple<std::vector<ExtrusionPaths>, Polygons> generate_extra_perimeters_over
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Polylines perimeter = intersection_pl(to_polylines(perimeter_polygon), shrinked_overhang_to_cover);
|
|
||||||
overhang_region.emplace_back();
|
|
||||||
extrusion_paths_append(overhang_region.back(), perimeter, ExtrusionRole::OverhangPerimeter, overhang_flow.mm3_per_mm(),
|
|
||||||
overhang_flow.width(), overhang_flow.height());
|
|
||||||
|
|
||||||
perimeter_polygon = expand(perimeter_polygon, 0.5 * overhang_flow.scaled_spacing());
|
perimeter_polygon = expand(perimeter_polygon, 0.5 * overhang_flow.scaled_spacing());
|
||||||
perimeter_polygon = union_(perimeter_polygon, anchoring);
|
perimeter_polygon = union_(perimeter_polygon, anchoring);
|
||||||
@ -1008,7 +1066,7 @@ std::tuple<std::vector<ExtrusionPaths>, Polygons> generate_extra_perimeters_over
|
|||||||
|
|
||||||
std::vector<ExtrusionPaths> result{};
|
std::vector<ExtrusionPaths> result{};
|
||||||
for (const std::vector<ExtrusionPaths> &paths : extra_perims) {
|
for (const std::vector<ExtrusionPaths> &paths : extra_perims) {
|
||||||
result.push_back(sort_and_connect_extra_perimeters(paths, 2.0 * overhang_flow.scaled_spacing()));
|
result.push_back(sort_and_connect_extra_perimeters(paths, overhang_flow.scaled_spacing()));
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef EXTRA_PERIM_DEBUG_FILES
|
#ifdef EXTRA_PERIM_DEBUG_FILES
|
||||||
|
@ -185,6 +185,7 @@ struct ThickPolyline {
|
|||||||
|
|
||||||
const Point& first_point() const { return this->points.front(); }
|
const Point& first_point() const { return this->points.front(); }
|
||||||
const Point& last_point() const { return this->points.back(); }
|
const Point& last_point() const { return this->points.back(); }
|
||||||
|
size_t size() const { return this->points.size(); }
|
||||||
bool is_valid() const { return this->points.size() >= 2; }
|
bool is_valid() const { return this->points.size() >= 2; }
|
||||||
double length() const { return Slic3r::length(this->points); }
|
double length() const { return Slic3r::length(this->points); }
|
||||||
|
|
||||||
|
@ -443,6 +443,7 @@ static std::vector<std::string> s_Preset_print_options {
|
|||||||
"enable_dynamic_overhang_speeds", "dynamic_overhang_speeds", "overhang_overlap_levels",
|
"enable_dynamic_overhang_speeds", "dynamic_overhang_speeds", "overhang_overlap_levels",
|
||||||
"top_solid_infill_speed", "support_material_speed", "support_material_xy_spacing", "support_material_interface_speed",
|
"top_solid_infill_speed", "support_material_speed", "support_material_xy_spacing", "support_material_interface_speed",
|
||||||
"bridge_speed", "gap_fill_speed", "gap_fill_enabled", "travel_speed", "travel_speed_z", "first_layer_speed", "first_layer_speed_over_raft", "perimeter_acceleration", "infill_acceleration",
|
"bridge_speed", "gap_fill_speed", "gap_fill_enabled", "travel_speed", "travel_speed_z", "first_layer_speed", "first_layer_speed_over_raft", "perimeter_acceleration", "infill_acceleration",
|
||||||
|
"external_perimeter_acceleration", "top_solid_infill_acceleration", "solid_infill_acceleration",
|
||||||
"bridge_acceleration", "first_layer_acceleration", "first_layer_acceleration_over_raft", "default_acceleration", "skirts", "skirt_distance", "skirt_height", "draft_shield",
|
"bridge_acceleration", "first_layer_acceleration", "first_layer_acceleration_over_raft", "default_acceleration", "skirts", "skirt_distance", "skirt_height", "draft_shield",
|
||||||
"min_skirt_length", "brim_width", "brim_separation", "brim_type", "support_material", "support_material_auto", "support_material_threshold", "support_material_enforce_layers",
|
"min_skirt_length", "brim_width", "brim_separation", "brim_type", "support_material", "support_material_auto", "support_material_threshold", "support_material_enforce_layers",
|
||||||
"raft_layers", "raft_first_layer_density", "raft_first_layer_expansion", "raft_contact_distance", "raft_expansion",
|
"raft_layers", "raft_first_layer_density", "raft_first_layer_expansion", "raft_contact_distance", "raft_expansion",
|
||||||
@ -457,7 +458,7 @@ static std::vector<std::string> s_Preset_print_options {
|
|||||||
"infill_extruder", "solid_infill_extruder", "support_material_extruder", "support_material_interface_extruder",
|
"infill_extruder", "solid_infill_extruder", "support_material_extruder", "support_material_interface_extruder",
|
||||||
"ooze_prevention", "standby_temperature_delta", "interface_shells", "extrusion_width", "first_layer_extrusion_width",
|
"ooze_prevention", "standby_temperature_delta", "interface_shells", "extrusion_width", "first_layer_extrusion_width",
|
||||||
"perimeter_extrusion_width", "external_perimeter_extrusion_width", "infill_extrusion_width", "solid_infill_extrusion_width",
|
"perimeter_extrusion_width", "external_perimeter_extrusion_width", "infill_extrusion_width", "solid_infill_extrusion_width",
|
||||||
"top_infill_extrusion_width", "support_material_extrusion_width", "infill_overlap", "infill_anchor", "infill_anchor_max", "bridge_flow_ratio", "clip_multipart_objects",
|
"top_infill_extrusion_width", "support_material_extrusion_width", "infill_overlap", "infill_anchor", "infill_anchor_max", "bridge_flow_ratio",
|
||||||
"elefant_foot_compensation", "xy_size_compensation", "threads", "resolution", "gcode_resolution", "wipe_tower", "wipe_tower_x", "wipe_tower_y",
|
"elefant_foot_compensation", "xy_size_compensation", "threads", "resolution", "gcode_resolution", "wipe_tower", "wipe_tower_x", "wipe_tower_y",
|
||||||
"wipe_tower_width", "wipe_tower_rotation_angle", "wipe_tower_brim_width", "wipe_tower_bridging", "single_extruder_multi_material_priming", "mmu_segmented_region_max_width",
|
"wipe_tower_width", "wipe_tower_rotation_angle", "wipe_tower_brim_width", "wipe_tower_bridging", "single_extruder_multi_material_priming", "mmu_segmented_region_max_width",
|
||||||
"wipe_tower_no_sparse_layers", "compatible_printers", "compatible_printers_condition", "inherits",
|
"wipe_tower_no_sparse_layers", "compatible_printers", "compatible_printers_condition", "inherits",
|
||||||
|
@ -74,6 +74,7 @@ bool Print::invalidate_state_by_config_options(const ConfigOptionResolver & /* n
|
|||||||
"duplicate_distance",
|
"duplicate_distance",
|
||||||
"end_gcode",
|
"end_gcode",
|
||||||
"end_filament_gcode",
|
"end_filament_gcode",
|
||||||
|
"external_perimeter_acceleration",
|
||||||
"extrusion_axis",
|
"extrusion_axis",
|
||||||
"extruder_clearance_height",
|
"extruder_clearance_height",
|
||||||
"extruder_clearance_radius",
|
"extruder_clearance_radius",
|
||||||
@ -125,10 +126,12 @@ bool Print::invalidate_state_by_config_options(const ConfigOptionResolver & /* n
|
|||||||
"retract_speed",
|
"retract_speed",
|
||||||
"single_extruder_multi_material_priming",
|
"single_extruder_multi_material_priming",
|
||||||
"slowdown_below_layer_time",
|
"slowdown_below_layer_time",
|
||||||
|
"solid_infill_acceleration",
|
||||||
"standby_temperature_delta",
|
"standby_temperature_delta",
|
||||||
"start_gcode",
|
"start_gcode",
|
||||||
"start_filament_gcode",
|
"start_filament_gcode",
|
||||||
"toolchange_gcode",
|
"toolchange_gcode",
|
||||||
|
"top_solid_infill_acceleration",
|
||||||
"thumbnails",
|
"thumbnails",
|
||||||
"thumbnails_format",
|
"thumbnails_format",
|
||||||
"use_firmware_retraction",
|
"use_firmware_retraction",
|
||||||
@ -474,6 +477,10 @@ std::string Print::validate(std::string* warning) const
|
|||||||
return L("Some objects are too tall and cannot be printed without extruder collisions.");
|
return L("Some objects are too tall and cannot be printed without extruder collisions.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (m_config.avoid_crossing_perimeters && m_config.avoid_crossing_curled_overhangs) {
|
||||||
|
return L("Avoid crossing perimeters option and avoid crossing curled overhangs option cannot be both enabled together.");
|
||||||
|
}
|
||||||
|
|
||||||
if (m_config.spiral_vase) {
|
if (m_config.spiral_vase) {
|
||||||
size_t total_copies_count = 0;
|
size_t total_copies_count = 0;
|
||||||
for (const PrintObject *object : m_objects)
|
for (const PrintObject *object : m_objects)
|
||||||
@ -487,6 +494,47 @@ std::string Print::validate(std::string* warning) const
|
|||||||
return L("The Spiral Vase option can only be used when printing single material objects.");
|
return L("The Spiral Vase option can only be used when printing single material objects.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Cache of layer height profiles for checking:
|
||||||
|
// 1) Whether all layers are synchronized if printing with wipe tower and / or unsynchronized supports.
|
||||||
|
// 2) Whether layer height is constant for Organic supports.
|
||||||
|
// 3) Whether build volume Z is not violated.
|
||||||
|
std::vector<std::vector<coordf_t>> layer_height_profiles;
|
||||||
|
auto layer_height_profile = [this, &layer_height_profiles](const size_t print_object_idx) -> const std::vector<coordf_t>& {
|
||||||
|
const PrintObject &print_object = *m_objects[print_object_idx];
|
||||||
|
if (layer_height_profiles.empty())
|
||||||
|
layer_height_profiles.assign(m_objects.size(), std::vector<coordf_t>());
|
||||||
|
std::vector<coordf_t> &profile = layer_height_profiles[print_object_idx];
|
||||||
|
if (profile.empty())
|
||||||
|
PrintObject::update_layer_height_profile(*print_object.model_object(), print_object.slicing_parameters(), profile);
|
||||||
|
return profile;
|
||||||
|
};
|
||||||
|
|
||||||
|
// Checks that the print does not exceed the max print height
|
||||||
|
for (size_t print_object_idx = 0; print_object_idx < m_objects.size(); ++ print_object_idx) {
|
||||||
|
const PrintObject &print_object = *m_objects[print_object_idx];
|
||||||
|
//FIXME It is quite expensive to generate object layers just to get the print height!
|
||||||
|
if (auto layers = generate_object_layers(print_object.slicing_parameters(), layer_height_profile(print_object_idx));
|
||||||
|
! layers.empty() && layers.back() > this->config().max_print_height) {
|
||||||
|
return L("The print is taller than the maximum allowed height. You might want to reduce the size of your model"
|
||||||
|
" or change current print settings and retry.");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Some of the objects has variable layer height applied by painting or by a table.
|
||||||
|
bool has_custom_layering = std::find_if(m_objects.begin(), m_objects.end(),
|
||||||
|
[](const PrintObject *object) { return object->model_object()->has_custom_layering(); })
|
||||||
|
!= m_objects.end();
|
||||||
|
|
||||||
|
// Custom layering is not allowed for tree supports as of now.
|
||||||
|
for (size_t print_object_idx = 0; print_object_idx < m_objects.size(); ++ print_object_idx)
|
||||||
|
if (const PrintObject &print_object = *m_objects[print_object_idx];
|
||||||
|
print_object.has_support_material() && print_object.config().support_material_style.value == smsOrganic &&
|
||||||
|
print_object.model_object()->has_custom_layering()) {
|
||||||
|
if (const std::vector<coordf_t> &layers = layer_height_profile(print_object_idx); ! layers.empty())
|
||||||
|
if (! check_object_layers_fixed(print_object.slicing_parameters(), layers))
|
||||||
|
return L("Variable layer height is not supported with Organic supports.");
|
||||||
|
}
|
||||||
|
|
||||||
if (this->has_wipe_tower() && ! m_objects.empty()) {
|
if (this->has_wipe_tower() && ! m_objects.empty()) {
|
||||||
// Make sure all extruders use same diameter filament and have the same nozzle diameter
|
// Make sure all extruders use same diameter filament and have the same nozzle diameter
|
||||||
// EPSILON comparison is used for nozzles and 10 % tolerance is used for filaments
|
// EPSILON comparison is used for nozzles and 10 % tolerance is used for filaments
|
||||||
@ -514,19 +562,8 @@ std::string Print::validate(std::string* warning) const
|
|||||||
return L("The Wipe Tower is currently not supported for multimaterial sequential prints.");
|
return L("The Wipe Tower is currently not supported for multimaterial sequential prints.");
|
||||||
|
|
||||||
if (m_objects.size() > 1) {
|
if (m_objects.size() > 1) {
|
||||||
bool has_custom_layering = false;
|
const SlicingParameters &slicing_params0 = m_objects.front()->slicing_parameters();
|
||||||
std::vector<std::vector<coordf_t>> layer_height_profiles;
|
size_t tallest_object_idx = 0;
|
||||||
for (const PrintObject *object : m_objects) {
|
|
||||||
has_custom_layering = ! object->model_object()->layer_config_ranges.empty() || ! object->model_object()->layer_height_profile.empty();
|
|
||||||
if (has_custom_layering) {
|
|
||||||
layer_height_profiles.assign(m_objects.size(), std::vector<coordf_t>());
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const SlicingParameters &slicing_params0 = m_objects.front()->slicing_parameters();
|
|
||||||
size_t tallest_object_idx = 0;
|
|
||||||
if (has_custom_layering)
|
|
||||||
PrintObject::update_layer_height_profile(*m_objects.front()->model_object(), slicing_params0, layer_height_profiles.front());
|
|
||||||
for (size_t i = 1; i < m_objects.size(); ++ i) {
|
for (size_t i = 1; i < m_objects.size(); ++ i) {
|
||||||
const PrintObject *object = m_objects[i];
|
const PrintObject *object = m_objects[i];
|
||||||
const SlicingParameters &slicing_params = object->slicing_parameters();
|
const SlicingParameters &slicing_params = object->slicing_parameters();
|
||||||
@ -541,8 +578,9 @@ std::string Print::validate(std::string* warning) const
|
|||||||
if (! equal_layering(slicing_params, slicing_params0))
|
if (! equal_layering(slicing_params, slicing_params0))
|
||||||
return L("The Wipe Tower is only supported for multiple objects if they are sliced equally.");
|
return L("The Wipe Tower is only supported for multiple objects if they are sliced equally.");
|
||||||
if (has_custom_layering) {
|
if (has_custom_layering) {
|
||||||
PrintObject::update_layer_height_profile(*object->model_object(), slicing_params, layer_height_profiles[i]);
|
auto &lh = layer_height_profile(i);
|
||||||
if (*(layer_height_profiles[i].end()-2) > *(layer_height_profiles[tallest_object_idx].end()-2))
|
auto &lh_tallest = layer_height_profile(tallest_object_idx);
|
||||||
|
if (*(lh.end()-2) > *(lh_tallest.end()-2))
|
||||||
tallest_object_idx = i;
|
tallest_object_idx = i;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -618,10 +656,10 @@ std::string Print::validate(std::string* warning) const
|
|||||||
"If support is to be printed with the current extruder (support_material_extruder == 0 or support_material_interface_extruder == 0), "
|
"If support is to be printed with the current extruder (support_material_extruder == 0 or support_material_interface_extruder == 0), "
|
||||||
"all nozzles have to be of the same diameter.");
|
"all nozzles have to be of the same diameter.");
|
||||||
}
|
}
|
||||||
if (this->has_wipe_tower()) {
|
if (this->has_wipe_tower() && object->config().support_material_style != smsOrganic) {
|
||||||
if (object->config().support_material_contact_distance == 0) {
|
if (object->config().support_material_contact_distance == 0) {
|
||||||
// Soluble interface
|
// Soluble interface
|
||||||
if (object->config().support_material_contact_distance == 0 && ! object->config().support_material_synchronize_layers)
|
if (! object->config().support_material_synchronize_layers)
|
||||||
return L("For the Wipe Tower to work with the soluble supports, the support layers need to be synchronized with the object layers.");
|
return L("For the Wipe Tower to work with the soluble supports, the support layers need to be synchronized with the object layers.");
|
||||||
} else {
|
} else {
|
||||||
// Non-soluble interface
|
// Non-soluble interface
|
||||||
@ -1169,7 +1207,7 @@ void Print::alert_when_supports_needed()
|
|||||||
for (const auto &obj : objects_isssues) {
|
for (const auto &obj : objects_isssues) {
|
||||||
for (const auto &issue : obj.second) {
|
for (const auto &issue : obj.second) {
|
||||||
po_by_support_issues[issue].push_back(obj.first);
|
po_by_support_issues[issue].push_back(obj.first);
|
||||||
if (issue.first == SupportSpotsGenerator::SupportPointCause::SeparationFromBed){
|
if (issue.first == SupportSpotsGenerator::SupportPointCause::SeparationFromBed && !obj.first->has_brim()){
|
||||||
recommend_brim = true;
|
recommend_brim = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1200,7 +1238,9 @@ void Print::alert_when_supports_needed()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
message += "\n" + L("Consider enabling supports") + (recommend_brim ? (" " + L("and/or brim")) : "") + ".";
|
bool brim_or_supp = recommend_brim && po_by_support_issues.size() < 2;
|
||||||
|
auto brim_part = " " + (brim_or_supp ? L("or") : L("and")) + " " + L("brim");
|
||||||
|
message += "\n" + L("Consider enabling supports") + (recommend_brim ? brim_part : "") + ".";
|
||||||
|
|
||||||
if (objects_isssues.size() > 0) {
|
if (objects_isssues.size() > 0) {
|
||||||
this->active_step_add_warning(PrintStateBase::WarningLevel::NON_CRITICAL, message);
|
this->active_step_add_warning(PrintStateBase::WarningLevel::NON_CRITICAL, message);
|
||||||
|
@ -249,6 +249,7 @@ PrintConfigDef::PrintConfigDef()
|
|||||||
assign_printer_technology_to_unknown(this->options, ptFFF);
|
assign_printer_technology_to_unknown(this->options, ptFFF);
|
||||||
this->init_sla_params();
|
this->init_sla_params();
|
||||||
assign_printer_technology_to_unknown(this->options, ptSLA);
|
assign_printer_technology_to_unknown(this->options, ptSLA);
|
||||||
|
this->finalize();
|
||||||
}
|
}
|
||||||
|
|
||||||
void PrintConfigDef::init_common_params()
|
void PrintConfigDef::init_common_params()
|
||||||
@ -258,9 +259,7 @@ void PrintConfigDef::init_common_params()
|
|||||||
def = this->add("printer_technology", coEnum);
|
def = this->add("printer_technology", coEnum);
|
||||||
def->label = L("Printer technology");
|
def->label = L("Printer technology");
|
||||||
def->tooltip = L("Printer technology");
|
def->tooltip = L("Printer technology");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<PrinterTechnology>::get_enum_values();
|
def->set_enum<PrinterTechnology>({ "FFF", "SLA" });
|
||||||
def->enum_values.push_back("FFF");
|
|
||||||
def->enum_values.push_back("SLA");
|
|
||||||
def->set_default_value(new ConfigOptionEnum<PrinterTechnology>(ptFFF));
|
def->set_default_value(new ConfigOptionEnum<PrinterTechnology>(ptFFF));
|
||||||
|
|
||||||
def = this->add("bed_shape", coPoints);
|
def = this->add("bed_shape", coPoints);
|
||||||
@ -299,10 +298,7 @@ void PrintConfigDef::init_common_params()
|
|||||||
def->label = L("Format of G-code thumbnails");
|
def->label = L("Format of G-code thumbnails");
|
||||||
def->tooltip = L("Format of G-code thumbnails: PNG for best quality, JPG for smallest size, QOI for low memory firmware");
|
def->tooltip = L("Format of G-code thumbnails: PNG for best quality, JPG for smallest size, QOI for low memory firmware");
|
||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->enum_keys_map = &ConfigOptionEnum<GCodeThumbnailsFormat>::get_enum_values();
|
def->set_enum<GCodeThumbnailsFormat>({ "PNG", "JPG", "QOI" });
|
||||||
def->enum_values.push_back("PNG");
|
|
||||||
def->enum_values.push_back("JPG");
|
|
||||||
def->enum_values.push_back("QOI");
|
|
||||||
def->set_default_value(new ConfigOptionEnum<GCodeThumbnailsFormat>(GCodeThumbnailsFormat::PNG));
|
def->set_default_value(new ConfigOptionEnum<GCodeThumbnailsFormat>(GCodeThumbnailsFormat::PNG));
|
||||||
|
|
||||||
def = this->add("layer_height", coFloat);
|
def = this->add("layer_height", coFloat);
|
||||||
@ -344,7 +340,7 @@ void PrintConfigDef::init_common_params()
|
|||||||
def = this->add("printhost_port", coString);
|
def = this->add("printhost_port", coString);
|
||||||
def->label = L("Printer");
|
def->label = L("Printer");
|
||||||
def->tooltip = L("Name of the printer");
|
def->tooltip = L("Name of the printer");
|
||||||
def->gui_type = ConfigOptionDef::GUIType::select_open;
|
def->gui_type = ConfigOptionDef::GUIType::select_close;
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->cli = ConfigOptionDef::nocli;
|
def->cli = ConfigOptionDef::nocli;
|
||||||
def->set_default_value(new ConfigOptionString(""));
|
def->set_default_value(new ConfigOptionString(""));
|
||||||
@ -391,11 +387,10 @@ void PrintConfigDef::init_common_params()
|
|||||||
def = this->add("printhost_authorization_type", coEnum);
|
def = this->add("printhost_authorization_type", coEnum);
|
||||||
def->label = L("Authorization Type");
|
def->label = L("Authorization Type");
|
||||||
// def->tooltip = L("");
|
// def->tooltip = L("");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<AuthorizationType>::get_enum_values();
|
def->set_enum<AuthorizationType>({
|
||||||
def->enum_values.push_back("key");
|
{ "key", L("API key") },
|
||||||
def->enum_values.push_back("user");
|
{ "user", L("HTTP digest") }
|
||||||
def->enum_labels.push_back(L("API key"));
|
});
|
||||||
def->enum_labels.push_back(L("HTTP digest"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->cli = ConfigOptionDef::nocli;
|
def->cli = ConfigOptionDef::nocli;
|
||||||
def->set_default_value(new ConfigOptionEnum<AuthorizationType>(atKeyPassword));
|
def->set_default_value(new ConfigOptionEnum<AuthorizationType>(atKeyPassword));
|
||||||
@ -591,15 +586,12 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Brim type");
|
def->label = L("Brim type");
|
||||||
def->category = L("Skirt and brim");
|
def->category = L("Skirt and brim");
|
||||||
def->tooltip = L("The places where the brim will be printed around each object on the first layer.");
|
def->tooltip = L("The places where the brim will be printed around each object on the first layer.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<BrimType>::get_enum_values();
|
def->set_enum<BrimType>({
|
||||||
def->enum_values.emplace_back("no_brim");
|
{ "no_brim", L("No brim") },
|
||||||
def->enum_values.emplace_back("outer_only");
|
{ "outer_only", L("Outer brim only") },
|
||||||
def->enum_values.emplace_back("inner_only");
|
{ "inner_only", L("Inner brim only") },
|
||||||
def->enum_values.emplace_back("outer_and_inner");
|
{ "outer_and_inner", L("Outer and inner brim") }
|
||||||
def->enum_labels.emplace_back(L("No brim"));
|
});
|
||||||
def->enum_labels.emplace_back(L("Outer brim only"));
|
|
||||||
def->enum_labels.emplace_back(L("Inner brim only"));
|
|
||||||
def->enum_labels.emplace_back(L("Outer and inner brim"));
|
|
||||||
def->mode = comSimple;
|
def->mode = comSimple;
|
||||||
def->set_default_value(new ConfigOptionEnum<BrimType>(btOuterOnly));
|
def->set_default_value(new ConfigOptionEnum<BrimType>(btOuterOnly));
|
||||||
|
|
||||||
@ -612,14 +604,6 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionFloat(0.f));
|
def->set_default_value(new ConfigOptionFloat(0.f));
|
||||||
|
|
||||||
def = this->add("clip_multipart_objects", coBool);
|
|
||||||
def->label = L("Clip multi-part objects");
|
|
||||||
def->tooltip = L("When printing multi-material objects, this settings will make Slic3r "
|
|
||||||
"to clip the overlapping object parts one by the other "
|
|
||||||
"(2nd part will be clipped by the 1st, 3rd part will be clipped by the 1st and 2nd etc).");
|
|
||||||
def->mode = comExpert;
|
|
||||||
def->set_default_value(new ConfigOptionBool(true));
|
|
||||||
|
|
||||||
def = this->add("colorprint_heights", coFloats);
|
def = this->add("colorprint_heights", coFloats);
|
||||||
def->label = L("Colorprint height");
|
def->label = L("Colorprint height");
|
||||||
def->tooltip = L("Heights at which a filament change is to occur.");
|
def->tooltip = L("Heights at which a filament change is to occur.");
|
||||||
@ -780,8 +764,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->category = L("Infill");
|
def->category = L("Infill");
|
||||||
def->tooltip = L("Fill pattern for top infill. This only affects the top visible layer, and not its adjacent solid shells.");
|
def->tooltip = L("Fill pattern for top infill. This only affects the top visible layer, and not its adjacent solid shells.");
|
||||||
def->cli = "top-fill-pattern|external-fill-pattern|solid-fill-pattern";
|
def->cli = "top-fill-pattern|external-fill-pattern|solid-fill-pattern";
|
||||||
def->enum_keys_map = &ConfigOptionEnum<InfillPattern>::get_enum_values();
|
def->set_enum<InfillPattern>({
|
||||||
def->set_enum_values({
|
|
||||||
{ "rectilinear", L("Rectilinear") },
|
{ "rectilinear", L("Rectilinear") },
|
||||||
{ "monotonic", L("Monotonic") },
|
{ "monotonic", L("Monotonic") },
|
||||||
{ "monotoniclines", L("Monotonic Lines") },
|
{ "monotoniclines", L("Monotonic Lines") },
|
||||||
@ -801,9 +784,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->category = L("Infill");
|
def->category = L("Infill");
|
||||||
def->tooltip = L("Fill pattern for bottom infill. This only affects the bottom external visible layer, and not its adjacent solid shells.");
|
def->tooltip = L("Fill pattern for bottom infill. This only affects the bottom external visible layer, and not its adjacent solid shells.");
|
||||||
def->cli = "bottom-fill-pattern|external-fill-pattern|solid-fill-pattern";
|
def->cli = "bottom-fill-pattern|external-fill-pattern|solid-fill-pattern";
|
||||||
def->enum_keys_map = &ConfigOptionEnum<InfillPattern>::get_enum_values();
|
def->enum_def = Slic3r::clonable_ptr<Slic3r::ConfigOptionEnumDef>(def_top_fill_pattern->enum_def->clone());
|
||||||
def->enum_values = def_top_fill_pattern->enum_values;
|
|
||||||
def->enum_labels = def_top_fill_pattern->enum_labels;
|
|
||||||
def->aliases = def_top_fill_pattern->aliases;
|
def->aliases = def_top_fill_pattern->aliases;
|
||||||
def->set_default_value(new ConfigOptionEnum<InfillPattern>(ipMonotonic));
|
def->set_default_value(new ConfigOptionEnum<InfillPattern>(ipMonotonic));
|
||||||
|
|
||||||
@ -857,18 +838,13 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionBool(false));
|
def->set_default_value(new ConfigOptionBool(false));
|
||||||
|
|
||||||
def = this->add("extruder", coInt);
|
def = this->add("extruder", coInt);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::i_enum_open;
|
|
||||||
def->label = L("Extruder");
|
def->label = L("Extruder");
|
||||||
def->category = L("Extruders");
|
def->category = L("Extruders");
|
||||||
def->tooltip = L("The extruder to use (unless more specific extruder settings are specified). "
|
def->tooltip = L("The extruder to use (unless more specific extruder settings are specified). "
|
||||||
"This value overrides perimeter and infill extruders, but not the support extruders.");
|
"This value overrides perimeter and infill extruders, but not the support extruders.");
|
||||||
def->min = 0; // 0 = inherit defaults
|
def->min = 0; // 0 = inherit defaults
|
||||||
def->enum_labels.push_back(L("default")); // override label for item 0
|
def->set_enum_labels(ConfigOptionDef::GUIType::i_enum_open,
|
||||||
def->enum_labels.push_back("1");
|
{ L("default"), "1", "2", "3", "4", "5" }); // override label for item 0
|
||||||
def->enum_labels.push_back("2");
|
|
||||||
def->enum_labels.push_back("3");
|
|
||||||
def->enum_labels.push_back("4");
|
|
||||||
def->enum_labels.push_back("5");
|
|
||||||
|
|
||||||
def = this->add("extruder_clearance_height", coFloat);
|
def = this->add("extruder_clearance_height", coFloat);
|
||||||
def->label = L("Height");
|
def->label = L("Height");
|
||||||
@ -1102,29 +1078,29 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def = this->add("filament_type", coStrings);
|
def = this->add("filament_type", coStrings);
|
||||||
def->label = L("Filament type");
|
def->label = L("Filament type");
|
||||||
def->tooltip = L("The filament material type for use in custom G-codes.");
|
def->tooltip = L("The filament material type for use in custom G-codes.");
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
|
||||||
def->gui_flags = "show_value";
|
def->gui_flags = "show_value";
|
||||||
def->enum_values.push_back("PLA");
|
def->set_enum_values(ConfigOptionDef::GUIType::select_open, {
|
||||||
def->enum_values.push_back("PET");
|
"PLA",
|
||||||
def->enum_values.push_back("ABS");
|
"PET",
|
||||||
def->enum_values.push_back("ASA");
|
"ABS",
|
||||||
def->enum_values.push_back("FLEX");
|
"ASA",
|
||||||
def->enum_values.push_back("HIPS");
|
"FLEX",
|
||||||
def->enum_values.push_back("EDGE");
|
"HIPS",
|
||||||
def->enum_values.push_back("NGEN");
|
"EDGE",
|
||||||
def->enum_values.push_back("PA");
|
"NGEN",
|
||||||
def->enum_values.push_back("NYLON");
|
"PA",
|
||||||
def->enum_values.push_back("PVA");
|
"NYLON",
|
||||||
def->enum_values.push_back("PC");
|
"PVA",
|
||||||
def->enum_values.push_back("PP");
|
"PC",
|
||||||
def->enum_values.push_back("PEI");
|
"PP",
|
||||||
def->enum_values.push_back("PEEK");
|
"PEI",
|
||||||
def->enum_values.push_back("PEKK");
|
"PEEK",
|
||||||
def->enum_values.push_back("POM");
|
"PEKK",
|
||||||
def->enum_values.push_back("PSU");
|
"POM",
|
||||||
def->enum_values.push_back("PVDF");
|
"PSU",
|
||||||
def->enum_values.push_back("SCAFF");
|
"PVDF",
|
||||||
|
"SCAFF"
|
||||||
|
});
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionStrings { "PLA" });
|
def->set_default_value(new ConfigOptionStrings { "PLA" });
|
||||||
|
|
||||||
@ -1172,7 +1148,6 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionFloat(45));
|
def->set_default_value(new ConfigOptionFloat(45));
|
||||||
|
|
||||||
def = this->add("fill_density", coPercent);
|
def = this->add("fill_density", coPercent);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
|
||||||
def->gui_flags = "show_value";
|
def->gui_flags = "show_value";
|
||||||
def->label = L("Fill density");
|
def->label = L("Fill density");
|
||||||
def->category = L("Infill");
|
def->category = L("Infill");
|
||||||
@ -1180,75 +1155,47 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->sidetext = L("%");
|
def->sidetext = L("%");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
def->max = 100;
|
def->max = 100;
|
||||||
def->enum_values.push_back("0");
|
def->set_enum_values(ConfigOptionDef::GUIType::f_enum_open, {
|
||||||
def->enum_values.push_back("5");
|
{ "0", "0%" },
|
||||||
def->enum_values.push_back("10");
|
{ "5", "5%" },
|
||||||
def->enum_values.push_back("15");
|
{ "10", "10%" },
|
||||||
def->enum_values.push_back("20");
|
{ "15", "15%" },
|
||||||
def->enum_values.push_back("25");
|
{ "20", "20%" },
|
||||||
def->enum_values.push_back("30");
|
{ "25", "25%" },
|
||||||
def->enum_values.push_back("40");
|
{ "30", "30%" },
|
||||||
def->enum_values.push_back("50");
|
{ "40", "40%" },
|
||||||
def->enum_values.push_back("60");
|
{ "50", "50%" },
|
||||||
def->enum_values.push_back("70");
|
{ "60", "60%" },
|
||||||
def->enum_values.push_back("80");
|
{ "70", "70%" },
|
||||||
def->enum_values.push_back("90");
|
{ "80", "80%" },
|
||||||
def->enum_values.push_back("100");
|
{ "90", "90%" },
|
||||||
def->enum_labels.push_back("0%");
|
{ "100", "100%" }
|
||||||
def->enum_labels.push_back("5%");
|
});
|
||||||
def->enum_labels.push_back("10%");
|
|
||||||
def->enum_labels.push_back("15%");
|
|
||||||
def->enum_labels.push_back("20%");
|
|
||||||
def->enum_labels.push_back("25%");
|
|
||||||
def->enum_labels.push_back("30%");
|
|
||||||
def->enum_labels.push_back("40%");
|
|
||||||
def->enum_labels.push_back("50%");
|
|
||||||
def->enum_labels.push_back("60%");
|
|
||||||
def->enum_labels.push_back("70%");
|
|
||||||
def->enum_labels.push_back("80%");
|
|
||||||
def->enum_labels.push_back("90%");
|
|
||||||
def->enum_labels.push_back("100%");
|
|
||||||
def->set_default_value(new ConfigOptionPercent(20));
|
def->set_default_value(new ConfigOptionPercent(20));
|
||||||
|
|
||||||
def = this->add("fill_pattern", coEnum);
|
def = this->add("fill_pattern", coEnum);
|
||||||
def->label = L("Fill pattern");
|
def->label = L("Fill pattern");
|
||||||
def->category = L("Infill");
|
def->category = L("Infill");
|
||||||
def->tooltip = L("Fill pattern for general low-density infill.");
|
def->tooltip = L("Fill pattern for general low-density infill.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<InfillPattern>::get_enum_values();
|
def->set_enum<InfillPattern>({
|
||||||
def->enum_values.push_back("rectilinear");
|
{ "rectilinear", L("Rectilinear") },
|
||||||
def->enum_values.push_back("alignedrectilinear");
|
{ "alignedrectilinear", L("Aligned Rectilinear") },
|
||||||
def->enum_values.push_back("grid");
|
{ "grid", L("Grid") },
|
||||||
def->enum_values.push_back("triangles");
|
{ "triangles", L("Triangles")},
|
||||||
def->enum_values.push_back("stars");
|
{ "stars", L("Stars")},
|
||||||
def->enum_values.push_back("cubic");
|
{ "cubic", L("Cubic")},
|
||||||
def->enum_values.push_back("line");
|
{ "line", L("Line")},
|
||||||
def->enum_values.push_back("concentric");
|
{ "concentric", L("Concentric")},
|
||||||
def->enum_values.push_back("honeycomb");
|
{ "honeycomb", L("Honeycomb")},
|
||||||
def->enum_values.push_back("3dhoneycomb");
|
{ "3dhoneycomb", L("3D Honeycomb")},
|
||||||
def->enum_values.push_back("gyroid");
|
{ "gyroid", L("Gyroid")},
|
||||||
def->enum_values.push_back("hilbertcurve");
|
{ "hilbertcurve", L("Hilbert Curve")},
|
||||||
def->enum_values.push_back("archimedeanchords");
|
{ "archimedeanchords", L("Archimedean Chords")},
|
||||||
def->enum_values.push_back("octagramspiral");
|
{ "octagramspiral", L("Octagram Spiral")},
|
||||||
def->enum_values.push_back("adaptivecubic");
|
{ "adaptivecubic", L("Adaptive Cubic")},
|
||||||
def->enum_values.push_back("supportcubic");
|
{ "supportcubic", L("Support Cubic")},
|
||||||
def->enum_values.push_back("lightning");
|
{ "lightning", L("Lightning")}
|
||||||
def->enum_labels.push_back(L("Rectilinear"));
|
});
|
||||||
def->enum_labels.push_back(L("Aligned Rectilinear"));
|
|
||||||
def->enum_labels.push_back(L("Grid"));
|
|
||||||
def->enum_labels.push_back(L("Triangles"));
|
|
||||||
def->enum_labels.push_back(L("Stars"));
|
|
||||||
def->enum_labels.push_back(L("Cubic"));
|
|
||||||
def->enum_labels.push_back(L("Line"));
|
|
||||||
def->enum_labels.push_back(L("Concentric"));
|
|
||||||
def->enum_labels.push_back(L("Honeycomb"));
|
|
||||||
def->enum_labels.push_back(L("3D Honeycomb"));
|
|
||||||
def->enum_labels.push_back(L("Gyroid"));
|
|
||||||
def->enum_labels.push_back(L("Hilbert Curve"));
|
|
||||||
def->enum_labels.push_back(L("Archimedean Chords"));
|
|
||||||
def->enum_labels.push_back(L("Octagram Spiral"));
|
|
||||||
def->enum_labels.push_back(L("Adaptive Cubic"));
|
|
||||||
def->enum_labels.push_back(L("Support Cubic"));
|
|
||||||
def->enum_labels.push_back(L("Lightning"));
|
|
||||||
def->set_default_value(new ConfigOptionEnum<InfillPattern>(ipStars));
|
def->set_default_value(new ConfigOptionEnum<InfillPattern>(ipStars));
|
||||||
|
|
||||||
def = this->add("first_layer_acceleration", coFloat);
|
def = this->add("first_layer_acceleration", coFloat);
|
||||||
@ -1349,14 +1296,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Fuzzy Skin");
|
def->label = L("Fuzzy Skin");
|
||||||
def->category = L("Fuzzy Skin");
|
def->category = L("Fuzzy Skin");
|
||||||
def->tooltip = L("Fuzzy skin type.");
|
def->tooltip = L("Fuzzy skin type.");
|
||||||
|
def->set_enum<FuzzySkinType>({
|
||||||
def->enum_keys_map = &ConfigOptionEnum<FuzzySkinType>::get_enum_values();
|
{ "none", L("None") },
|
||||||
def->enum_values.push_back("none");
|
{ "external", L("Outside walls") },
|
||||||
def->enum_values.push_back("external");
|
{ "all", L("All walls") }
|
||||||
def->enum_values.push_back("all");
|
});
|
||||||
def->enum_labels.push_back(L("None"));
|
|
||||||
def->enum_labels.push_back(L("Outside walls"));
|
|
||||||
def->enum_labels.push_back(L("All walls"));
|
|
||||||
def->mode = comSimple;
|
def->mode = comSimple;
|
||||||
def->set_default_value(new ConfigOptionEnum<FuzzySkinType>(FuzzySkinType::None));
|
def->set_default_value(new ConfigOptionEnum<FuzzySkinType>(FuzzySkinType::None));
|
||||||
|
|
||||||
@ -1410,31 +1354,20 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->tooltip = L("Some G/M-code commands, including temperature control and others, are not universal. "
|
def->tooltip = L("Some G/M-code commands, including temperature control and others, are not universal. "
|
||||||
"Set this option to your printer's firmware to get a compatible output. "
|
"Set this option to your printer's firmware to get a compatible output. "
|
||||||
"The \"No extrusion\" flavor prevents PrusaSlicer from exporting any extrusion value at all.");
|
"The \"No extrusion\" flavor prevents PrusaSlicer from exporting any extrusion value at all.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<GCodeFlavor>::get_enum_values();
|
def->set_enum<GCodeFlavor>({
|
||||||
def->enum_values.push_back("reprap");
|
{ "reprap", "RepRap/Sprinter" },
|
||||||
def->enum_values.push_back("reprapfirmware");
|
{ "reprapfirmware", "RepRapFirmware" },
|
||||||
def->enum_values.push_back("repetier");
|
{ "repetier", "Repetier" },
|
||||||
def->enum_values.push_back("teacup");
|
{ "teacup", "Teacup" },
|
||||||
def->enum_values.push_back("makerware");
|
{ "makerware", "MakerWare (MakerBot)" },
|
||||||
def->enum_values.push_back("marlin");
|
{ "marlin", "Marlin (legacy)" },
|
||||||
def->enum_values.push_back("marlin2");
|
{ "marlin2", "Marlin 2" },
|
||||||
def->enum_values.push_back("sailfish");
|
{ "sailfish", "Sailfish (MakerBot)" },
|
||||||
def->enum_values.push_back("mach3");
|
{ "mach3", "Mach3/LinuxCNC" },
|
||||||
def->enum_values.push_back("machinekit");
|
{ "machinekit", "Machinekit" },
|
||||||
def->enum_values.push_back("smoothie");
|
{ "smoothie", "Smoothie" },
|
||||||
def->enum_values.push_back("no-extrusion");
|
{ "no-extrusion", L("No extrusion") }
|
||||||
def->enum_labels.push_back("RepRap/Sprinter");
|
});
|
||||||
def->enum_labels.push_back("RepRapFirmware");
|
|
||||||
def->enum_labels.push_back("Repetier");
|
|
||||||
def->enum_labels.push_back("Teacup");
|
|
||||||
def->enum_labels.push_back("MakerWare (MakerBot)");
|
|
||||||
def->enum_labels.push_back("Marlin (legacy)");
|
|
||||||
def->enum_labels.push_back("Marlin 2");
|
|
||||||
def->enum_labels.push_back("Sailfish (MakerBot)");
|
|
||||||
def->enum_labels.push_back("Mach3/LinuxCNC");
|
|
||||||
def->enum_labels.push_back("Machinekit");
|
|
||||||
def->enum_labels.push_back("Smoothie");
|
|
||||||
def->enum_labels.push_back(L("No extrusion"));
|
|
||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->set_default_value(new ConfigOptionEnum<GCodeFlavor>(gcfRepRapSprinter));
|
def->set_default_value(new ConfigOptionEnum<GCodeFlavor>(gcfRepRapSprinter));
|
||||||
|
|
||||||
@ -1463,12 +1396,31 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def = this->add("infill_acceleration", coFloat);
|
def = this->add("infill_acceleration", coFloat);
|
||||||
def->label = L("Infill");
|
def->label = L("Infill");
|
||||||
def->tooltip = L("This is the acceleration your printer will use for infill. Set zero to disable "
|
def->tooltip = L("This is the acceleration your printer will use for infill. Set zero to disable "
|
||||||
"acceleration control for infill.");
|
"acceleration control for infill.");
|
||||||
def->sidetext = L("mm/s²");
|
def->sidetext = L("mm/s²");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->set_default_value(new ConfigOptionFloat(0));
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
|
def = this->add("solid_infill_acceleration", coFloat);
|
||||||
|
def->label = L("Solid infill");
|
||||||
|
def->tooltip = L("This is the acceleration your printer will use for solid infill. Set zero to use "
|
||||||
|
"the value for infill.");
|
||||||
|
def->sidetext = L("mm/s²");
|
||||||
|
def->min = 0;
|
||||||
|
def->mode = comExpert;
|
||||||
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
|
def = this->add("top_solid_infill_acceleration", coFloat);
|
||||||
|
def->label = L("Top solid infill");
|
||||||
|
def->tooltip = L("This is the acceleration your printer will use for top solid infill. Set zero to use "
|
||||||
|
"the value for solid infill.");
|
||||||
|
def->sidetext = L("mm/s²");
|
||||||
|
def->min = 0;
|
||||||
|
def->mode = comExpert;
|
||||||
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
|
|
||||||
def = this->add("infill_every_layers", coInt);
|
def = this->add("infill_every_layers", coInt);
|
||||||
def->label = L("Combine infill every");
|
def->label = L("Combine infill every");
|
||||||
def->category = L("Infill");
|
def->category = L("Infill");
|
||||||
@ -1492,19 +1444,14 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->sidetext = L("mm or %");
|
def->sidetext = L("mm or %");
|
||||||
def->ratio_over = "infill_extrusion_width";
|
def->ratio_over = "infill_extrusion_width";
|
||||||
def->max_literal = 1000;
|
def->max_literal = 1000;
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
def->set_enum_values(ConfigOptionDef::GUIType::f_enum_open, {
|
||||||
def->enum_values.push_back("0");
|
{ "0", L("0 (no open anchors)") },
|
||||||
def->enum_values.push_back("1");
|
{ "1", L("1 mm") },
|
||||||
def->enum_values.push_back("2");
|
{ "2", L("2 mm") },
|
||||||
def->enum_values.push_back("5");
|
{ "5", L("5 mm") },
|
||||||
def->enum_values.push_back("10");
|
{ "10", L("10 mm") },
|
||||||
def->enum_values.push_back("1000");
|
{ "1000", L("1000 (unlimited)") }
|
||||||
def->enum_labels.push_back(L("0 (no open anchors)"));
|
});
|
||||||
def->enum_labels.push_back(L("1 mm"));
|
|
||||||
def->enum_labels.push_back(L("2 mm"));
|
|
||||||
def->enum_labels.push_back(L("5 mm"));
|
|
||||||
def->enum_labels.push_back(L("10 mm"));
|
|
||||||
def->enum_labels.push_back(L("1000 (unlimited)"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionFloatOrPercent(600, true));
|
def->set_default_value(new ConfigOptionFloatOrPercent(600, true));
|
||||||
|
|
||||||
@ -1520,14 +1467,14 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->sidetext = def_infill_anchor_min->sidetext;
|
def->sidetext = def_infill_anchor_min->sidetext;
|
||||||
def->ratio_over = def_infill_anchor_min->ratio_over;
|
def->ratio_over = def_infill_anchor_min->ratio_over;
|
||||||
def->max_literal = def_infill_anchor_min->max_literal;
|
def->max_literal = def_infill_anchor_min->max_literal;
|
||||||
def->gui_type = def_infill_anchor_min->gui_type;
|
def->set_enum_values(ConfigOptionDef::GUIType::f_enum_open, {
|
||||||
def->enum_values = def_infill_anchor_min->enum_values;
|
{ "0", L("0 (not anchored)") },
|
||||||
def->enum_labels.push_back(L("0 (not anchored)"));
|
{ "1", L("1 mm") },
|
||||||
def->enum_labels.push_back(L("1 mm"));
|
{ "2", L("2 mm") },
|
||||||
def->enum_labels.push_back(L("2 mm"));
|
{ "5", L("5 mm") },
|
||||||
def->enum_labels.push_back(L("5 mm"));
|
{ "10", L("10 mm") },
|
||||||
def->enum_labels.push_back(L("10 mm"));
|
{ "1000", L("1000 (unlimited)") }
|
||||||
def->enum_labels.push_back(L("1000 (unlimited)"));
|
});
|
||||||
def->mode = def_infill_anchor_min->mode;
|
def->mode = def_infill_anchor_min->mode;
|
||||||
def->set_default_value(new ConfigOptionFloatOrPercent(50, false));
|
def->set_default_value(new ConfigOptionFloatOrPercent(50, false));
|
||||||
|
|
||||||
@ -1631,13 +1578,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Ironing Type");
|
def->label = L("Ironing Type");
|
||||||
def->category = L("Ironing");
|
def->category = L("Ironing");
|
||||||
def->tooltip = L("Ironing Type");
|
def->tooltip = L("Ironing Type");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<IroningType>::get_enum_values();
|
def->set_enum<IroningType>({
|
||||||
def->enum_values.push_back("top");
|
{ "top", L("All top surfaces") },
|
||||||
def->enum_values.push_back("topmost");
|
{ "topmost", L("Topmost surface only") },
|
||||||
def->enum_values.push_back("solid");
|
{ "solid", L("All solid surfaces") }
|
||||||
def->enum_labels.push_back(L("All top surfaces"));
|
});
|
||||||
def->enum_labels.push_back(L("Topmost surface only"));
|
|
||||||
def->enum_labels.push_back(L("All solid surfaces"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<IroningType>(IroningType::TopSurfaces));
|
def->set_default_value(new ConfigOptionEnum<IroningType>(IroningType::TopSurfaces));
|
||||||
|
|
||||||
@ -1701,13 +1646,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->full_label = L("Purpose of Machine Limits");
|
def->full_label = L("Purpose of Machine Limits");
|
||||||
def->category = L("Machine limits");
|
def->category = L("Machine limits");
|
||||||
def->tooltip = L("How to apply the Machine Limits");
|
def->tooltip = L("How to apply the Machine Limits");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<MachineLimitsUsage>::get_enum_values();
|
def->set_enum<MachineLimitsUsage>({
|
||||||
def->enum_values.push_back("emit_to_gcode");
|
{ "emit_to_gcode", L("Emit to G-code") },
|
||||||
def->enum_values.push_back("time_estimate_only");
|
{ "time_estimate_only", L("Use for time estimate") },
|
||||||
def->enum_values.push_back("ignore");
|
{ "ignore", L("Ignore") }
|
||||||
def->enum_labels.push_back(L("Emit to G-code"));
|
});
|
||||||
def->enum_labels.push_back(L("Use for time estimate"));
|
|
||||||
def->enum_labels.push_back(L("Ignore"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<MachineLimitsUsage>(MachineLimitsUsage::TimeEstimateOnly));
|
def->set_default_value(new ConfigOptionEnum<MachineLimitsUsage>(MachineLimitsUsage::TimeEstimateOnly));
|
||||||
|
|
||||||
@ -1953,23 +1896,16 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Host Type");
|
def->label = L("Host Type");
|
||||||
def->tooltip = L("Slic3r can upload G-code files to a printer host. This field must contain "
|
def->tooltip = L("Slic3r can upload G-code files to a printer host. This field must contain "
|
||||||
"the kind of the host.");
|
"the kind of the host.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<PrintHostType>::get_enum_values();
|
def->set_enum<PrintHostType>({
|
||||||
def->enum_values.push_back("prusalink");
|
{ "prusalink", "PrusaLink" },
|
||||||
def->enum_values.push_back("prusaconnect");
|
{ "prusaconnect", "PrusaConnect" },
|
||||||
def->enum_values.push_back("octoprint");
|
{ "octoprint", "OctoPrint" },
|
||||||
def->enum_values.push_back("duet");
|
{ "duet", "Duet" },
|
||||||
def->enum_values.push_back("flashair");
|
{ "flashair", "FlashAir" },
|
||||||
def->enum_values.push_back("astrobox");
|
{ "astrobox", "AstroBox" },
|
||||||
def->enum_values.push_back("repetier");
|
{ "repetier", "Repetier" },
|
||||||
def->enum_values.push_back("mks");
|
{ "mks", "MKS" }
|
||||||
def->enum_labels.push_back("PrusaLink");
|
});
|
||||||
def->enum_labels.push_back("PrusaConnect");
|
|
||||||
def->enum_labels.push_back("OctoPrint");
|
|
||||||
def->enum_labels.push_back("Duet");
|
|
||||||
def->enum_labels.push_back("FlashAir");
|
|
||||||
def->enum_labels.push_back("AstroBox");
|
|
||||||
def->enum_labels.push_back("Repetier");
|
|
||||||
def->enum_labels.push_back("MKS");
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->cli = ConfigOptionDef::nocli;
|
def->cli = ConfigOptionDef::nocli;
|
||||||
def->set_default_value(new ConfigOptionEnum<PrintHostType>(htPrusaLink));
|
def->set_default_value(new ConfigOptionEnum<PrintHostType>(htPrusaLink));
|
||||||
@ -2031,6 +1967,14 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->set_default_value(new ConfigOptionFloat(0));
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
|
def = this->add("external_perimeter_acceleration", coFloat);
|
||||||
|
def->label = L("External perimeters");
|
||||||
|
def->tooltip = L("This is the acceleration your printer will use for external perimeters. "
|
||||||
|
"Set zero to use the value for perimeters.");
|
||||||
|
def->sidetext = L("mm/s²");
|
||||||
|
def->mode = comExpert;
|
||||||
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
def = this->add("perimeter_extruder", coInt);
|
def = this->add("perimeter_extruder", coInt);
|
||||||
def->label = L("Perimeter extruder");
|
def->label = L("Perimeter extruder");
|
||||||
def->category = L("Extruders");
|
def->category = L("Extruders");
|
||||||
@ -2302,15 +2246,12 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Seam position");
|
def->label = L("Seam position");
|
||||||
def->category = L("Layers and Perimeters");
|
def->category = L("Layers and Perimeters");
|
||||||
def->tooltip = L("Position of perimeters starting points.");
|
def->tooltip = L("Position of perimeters starting points.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SeamPosition>::get_enum_values();
|
def->set_enum<SeamPosition>({
|
||||||
def->enum_values.push_back("random");
|
{ "random", L("Random") },
|
||||||
def->enum_values.push_back("nearest");
|
{ "nearest", L("Nearest") },
|
||||||
def->enum_values.push_back("aligned");
|
{ "aligned", L("Aligned") },
|
||||||
def->enum_values.push_back("rear");
|
{ "rear", L("Rear") }
|
||||||
def->enum_labels.push_back(L("Random"));
|
});
|
||||||
def->enum_labels.push_back(L("Nearest"));
|
|
||||||
def->enum_labels.push_back(L("Aligned"));
|
|
||||||
def->enum_labels.push_back(L("Rear"));
|
|
||||||
def->mode = comSimple;
|
def->mode = comSimple;
|
||||||
def->set_default_value(new ConfigOptionEnum<SeamPosition>(spAligned));
|
def->set_default_value(new ConfigOptionEnum<SeamPosition>(spAligned));
|
||||||
|
|
||||||
@ -2362,13 +2303,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
"Enabled = skirt is as tall as the highest printed object.\n"
|
"Enabled = skirt is as tall as the highest printed object.\n"
|
||||||
"Limited = skirt is as tall as specified by skirt_height.\n"
|
"Limited = skirt is as tall as specified by skirt_height.\n"
|
||||||
"This is useful to protect an ABS or ASA print from warping and detaching from print bed due to wind draft.");
|
"This is useful to protect an ABS or ASA print from warping and detaching from print bed due to wind draft.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<DraftShield>::get_enum_values();
|
def->set_enum<DraftShield>({
|
||||||
def->enum_values.push_back("disabled");
|
{ "disabled", L("Disabled") },
|
||||||
def->enum_values.push_back("limited");
|
{ "limited", L("Limited") },
|
||||||
def->enum_values.push_back("enabled");
|
{ "enabled", L("Enabled") }
|
||||||
def->enum_labels.push_back(L("Disabled"));
|
});
|
||||||
def->enum_labels.push_back(L("Limited"));
|
|
||||||
def->enum_labels.push_back(L("Enabled"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<DraftShield>(dsDisabled));
|
def->set_default_value(new ConfigOptionEnum<DraftShield>(dsDisabled));
|
||||||
|
|
||||||
@ -2585,13 +2524,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Slicing Mode");
|
def->label = L("Slicing Mode");
|
||||||
def->category = L("Advanced");
|
def->category = L("Advanced");
|
||||||
def->tooltip = L("Use \"Even-odd\" for 3DLabPrint airplane models. Use \"Close holes\" to close all holes in the model.");
|
def->tooltip = L("Use \"Even-odd\" for 3DLabPrint airplane models. Use \"Close holes\" to close all holes in the model.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SlicingMode>::get_enum_values();
|
def->set_enum<SlicingMode>({
|
||||||
def->enum_values.push_back("regular");
|
{ "regular", L("Regular") },
|
||||||
def->enum_values.push_back("even_odd");
|
{ "even_odd", L("Even-odd") },
|
||||||
def->enum_values.push_back("close_holes");
|
{ "close_holes", L("Close holes") }
|
||||||
def->enum_labels.push_back(L("Regular"));
|
});
|
||||||
def->enum_labels.push_back(L("Even-odd"));
|
|
||||||
def->enum_labels.push_back(L("Close holes"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<SlicingMode>(SlicingMode::Regular));
|
def->set_default_value(new ConfigOptionEnum<SlicingMode>(SlicingMode::Regular));
|
||||||
|
|
||||||
@ -2640,7 +2577,6 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionBool(false));
|
def->set_default_value(new ConfigOptionBool(false));
|
||||||
|
|
||||||
def = this->add("support_material_contact_distance", coFloat);
|
def = this->add("support_material_contact_distance", coFloat);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
|
||||||
def->label = L("Top contact Z distance");
|
def->label = L("Top contact Z distance");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The vertical distance between object and support material interface. "
|
def->tooltip = L("The vertical distance between object and support material interface. "
|
||||||
@ -2648,30 +2584,27 @@ void PrintConfigDef::init_fff_params()
|
|||||||
"for the first object layer.");
|
"for the first object layer.");
|
||||||
def->sidetext = L("mm");
|
def->sidetext = L("mm");
|
||||||
// def->min = 0;
|
// def->min = 0;
|
||||||
def->enum_values.push_back("0");
|
def->set_enum_values(ConfigOptionDef::GUIType::f_enum_open, {
|
||||||
def->enum_values.push_back("0.1");
|
{ "0", L("0 (soluble)") },
|
||||||
def->enum_values.push_back("0.2");
|
{ "0.1", L("0.1 (detachable)") },
|
||||||
def->enum_labels.push_back(L("0 (soluble)"));
|
{ "0.2", L("0.2 (detachable)") }
|
||||||
def->enum_labels.push_back(L("0.1 (detachable)"));
|
});
|
||||||
def->enum_labels.push_back(L("0.2 (detachable)"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionFloat(0.2));
|
def->set_default_value(new ConfigOptionFloat(0.2));
|
||||||
|
|
||||||
def = this->add("support_material_bottom_contact_distance", coFloat);
|
def = this->add("support_material_bottom_contact_distance", coFloat);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open;
|
|
||||||
def->label = L("Bottom contact Z distance");
|
def->label = L("Bottom contact Z distance");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The vertical distance between the object top surface and the support material interface. "
|
def->tooltip = L("The vertical distance between the object top surface and the support material interface. "
|
||||||
"If set to zero, support_material_contact_distance will be used for both top and bottom contact Z distances.");
|
"If set to zero, support_material_contact_distance will be used for both top and bottom contact Z distances.");
|
||||||
def->sidetext = L("mm");
|
def->sidetext = L("mm");
|
||||||
// def->min = 0;
|
// def->min = 0;
|
||||||
def->enum_values.push_back("0");
|
|
||||||
def->enum_values.push_back("0.1");
|
|
||||||
def->enum_values.push_back("0.2");
|
|
||||||
//TRN To be shown in Print Settings "Bottom contact Z distance". Have to be as short as possible
|
//TRN To be shown in Print Settings "Bottom contact Z distance". Have to be as short as possible
|
||||||
def->enum_labels.push_back(L("Same as top"));
|
def->set_enum_values(ConfigOptionDef::GUIType::f_enum_open, {
|
||||||
def->enum_labels.push_back("0.1");
|
{ "0", L("Same as top") },
|
||||||
def->enum_labels.push_back("0.2");
|
{ "0.1", "0.1" },
|
||||||
|
{ "0.2", "0.2" }
|
||||||
|
});
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionFloat(0));
|
def->set_default_value(new ConfigOptionFloat(0));
|
||||||
|
|
||||||
@ -2726,36 +2659,35 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionInt(1));
|
def->set_default_value(new ConfigOptionInt(1));
|
||||||
|
|
||||||
auto support_material_interface_layers = def = this->add("support_material_interface_layers", coInt);
|
auto support_material_interface_layers = def = this->add("support_material_interface_layers", coInt);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::i_enum_open;
|
|
||||||
def->label = L("Top interface layers");
|
def->label = L("Top interface layers");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("Number of interface layers to insert between the object(s) and support material.");
|
def->tooltip = L("Number of interface layers to insert between the object(s) and support material.");
|
||||||
def->sidetext = L("layers");
|
def->sidetext = L("layers");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
def->enum_values.push_back("0");
|
def->set_enum_values(ConfigOptionDef::GUIType::i_enum_open, {
|
||||||
def->enum_values.push_back("1");
|
{ "0", L("0 (off)") },
|
||||||
def->enum_values.push_back("2");
|
{ "1", L("1 (light)") },
|
||||||
def->enum_values.push_back("3");
|
{ "2", L("2 (default)") },
|
||||||
def->enum_labels.push_back(L("0 (off)"));
|
{ "3", L("3 (heavy)") }
|
||||||
def->enum_labels.push_back(L("1 (light)"));
|
});
|
||||||
def->enum_labels.push_back(L("2 (default)"));
|
|
||||||
def->enum_labels.push_back(L("3 (heavy)"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionInt(3));
|
def->set_default_value(new ConfigOptionInt(3));
|
||||||
|
|
||||||
def = this->add("support_material_bottom_interface_layers", coInt);
|
def = this->add("support_material_bottom_interface_layers", coInt);
|
||||||
def->gui_type = ConfigOptionDef::GUIType::i_enum_open;
|
|
||||||
def->label = L("Bottom interface layers");
|
def->label = L("Bottom interface layers");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("Number of interface layers to insert between the object(s) and support material. "
|
def->tooltip = L("Number of interface layers to insert between the object(s) and support material. "
|
||||||
"Set to -1 to use support_material_interface_layers");
|
"Set to -1 to use support_material_interface_layers");
|
||||||
def->sidetext = L("layers");
|
def->sidetext = L("layers");
|
||||||
def->min = -1;
|
def->min = -1;
|
||||||
def->enum_values.push_back("-1");
|
|
||||||
append(def->enum_values, support_material_interface_layers->enum_values);
|
|
||||||
//TRN To be shown in Print Settings "Bottom interface layers". Have to be as short as possible
|
//TRN To be shown in Print Settings "Bottom interface layers". Have to be as short as possible
|
||||||
def->enum_labels.push_back(L("Same as top"));
|
def->set_enum_values(ConfigOptionDef::GUIType::i_enum_open, {
|
||||||
append(def->enum_labels, support_material_interface_layers->enum_labels);
|
{ "-1", L("Same as top") },
|
||||||
|
{ "0", L("0 (off)") },
|
||||||
|
{ "1", L("1 (light)") },
|
||||||
|
{ "2", L("2 (default)") },
|
||||||
|
{ "3", L("3 (heavy)") }
|
||||||
|
});
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionInt(-1));
|
def->set_default_value(new ConfigOptionInt(-1));
|
||||||
|
|
||||||
@ -2793,13 +2725,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Pattern");
|
def->label = L("Pattern");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("Pattern used to generate support material.");
|
def->tooltip = L("Pattern used to generate support material.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SupportMaterialPattern>::get_enum_values();
|
def->set_enum<SupportMaterialPattern>({
|
||||||
def->enum_values.push_back("rectilinear");
|
{ "rectilinear", L("Rectilinear") },
|
||||||
def->enum_values.push_back("rectilinear-grid");
|
{ "rectilinear-grid", L("Rectilinear grid") },
|
||||||
def->enum_values.push_back("honeycomb");
|
{ "honeycomb", L("Honeycomb") }
|
||||||
def->enum_labels.push_back(L("Rectilinear"));
|
});
|
||||||
def->enum_labels.push_back(L("Rectilinear grid"));
|
|
||||||
def->enum_labels.push_back(L("Honeycomb"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<SupportMaterialPattern>(smpRectilinear));
|
def->set_default_value(new ConfigOptionEnum<SupportMaterialPattern>(smpRectilinear));
|
||||||
|
|
||||||
@ -2809,13 +2739,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->tooltip = L("Pattern used to generate support material interface. "
|
def->tooltip = L("Pattern used to generate support material interface. "
|
||||||
"Default pattern for non-soluble support interface is Rectilinear, "
|
"Default pattern for non-soluble support interface is Rectilinear, "
|
||||||
"while default pattern for soluble support interface is Concentric.");
|
"while default pattern for soluble support interface is Concentric.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SupportMaterialInterfacePattern>::get_enum_values();
|
def->set_enum<SupportMaterialInterfacePattern>({
|
||||||
def->enum_values.push_back("auto");
|
{ "auto", L("Default") },
|
||||||
def->enum_values.push_back("rectilinear");
|
{ "rectilinear", L("Rectilinear") },
|
||||||
def->enum_values.push_back("concentric");
|
{ "concentric", L("Concentric") }
|
||||||
def->enum_labels.push_back(L("Default"));
|
});
|
||||||
def->enum_labels.push_back(L("Rectilinear"));
|
|
||||||
def->enum_labels.push_back(L("Concentric"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<SupportMaterialInterfacePattern>(smipRectilinear));
|
def->set_default_value(new ConfigOptionEnum<SupportMaterialInterfacePattern>(smipRectilinear));
|
||||||
|
|
||||||
@ -2843,8 +2771,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->tooltip = L("Style and shape of the support towers. Projecting the supports into a regular grid "
|
def->tooltip = L("Style and shape of the support towers. Projecting the supports into a regular grid "
|
||||||
"will create more stable supports, while snug support towers will save material and reduce "
|
"will create more stable supports, while snug support towers will save material and reduce "
|
||||||
"object scarring.");
|
"object scarring.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SupportMaterialStyle>::get_enum_values();
|
def->set_enum<SupportMaterialStyle>({
|
||||||
def->set_enum_values({
|
|
||||||
{ "grid", L("Grid") },
|
{ "grid", L("Grid") },
|
||||||
{ "snug", L("Snug") },
|
{ "snug", L("Snug") },
|
||||||
{ "organic", L("Organic") }
|
{ "organic", L("Organic") }
|
||||||
@ -2884,7 +2811,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionBool(true));
|
def->set_default_value(new ConfigOptionBool(true));
|
||||||
|
|
||||||
def = this->add("support_tree_angle", coFloat);
|
def = this->add("support_tree_angle", coFloat);
|
||||||
def->label = L("Tree Support Maximum Branch Angle");
|
def->label = L("Maximum Branch Angle");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The maximum angle of the branches, when the branches have to avoid the model. "
|
def->tooltip = L("The maximum angle of the branches, when the branches have to avoid the model. "
|
||||||
"Use a lower angle to make them more vertical and more stable. Use a higher angle to be able to have more reach.");
|
"Use a lower angle to make them more vertical and more stable. Use a higher angle to be able to have more reach.");
|
||||||
@ -2895,7 +2822,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionFloat(40));
|
def->set_default_value(new ConfigOptionFloat(40));
|
||||||
|
|
||||||
def = this->add("support_tree_angle_slow", coFloat);
|
def = this->add("support_tree_angle_slow", coFloat);
|
||||||
def->label = L("Tree Support Preferred Branch Angle");
|
def->label = L("Preferred Branch Angle");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The preferred angle of the branches, when they do not have to avoid the model. "
|
def->tooltip = L("The preferred angle of the branches, when they do not have to avoid the model. "
|
||||||
"Use a lower angle to make them more vertical and more stable. Use a higher angle for branches to merge faster.");
|
"Use a lower angle to make them more vertical and more stable. Use a higher angle for branches to merge faster.");
|
||||||
@ -2906,18 +2833,18 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionFloat(25));
|
def->set_default_value(new ConfigOptionFloat(25));
|
||||||
|
|
||||||
def = this->add("support_tree_tip_diameter", coFloat);
|
def = this->add("support_tree_tip_diameter", coFloat);
|
||||||
def->label = L("Tree Support Tip Diameter");
|
def->label = L("Tip Diameter");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The diameter of the top of the tip of the branches of tree support.");
|
def->tooltip = L("The diameter of the top of the tip of the branches of organic support.");
|
||||||
def->sidetext = L("mm");
|
def->sidetext = L("mm");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionFloat(0.8));
|
def->set_default_value(new ConfigOptionFloat(0.8));
|
||||||
|
|
||||||
def = this->add("support_tree_branch_diameter", coFloat);
|
def = this->add("support_tree_branch_diameter", coFloat);
|
||||||
def->label = L("Tree Support Branch Diameter");
|
def->label = L("Branch Diameter");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The diameter of the thinnest branches of tree support. Thicker branches are more sturdy. "
|
def->tooltip = L("The diameter of the thinnest branches of organic support. Thicker branches are more sturdy. "
|
||||||
"Branches towards the base will be thicker than this.");
|
"Branches towards the base will be thicker than this.");
|
||||||
def->sidetext = L("mm");
|
def->sidetext = L("mm");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
@ -2925,11 +2852,11 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionFloat(2));
|
def->set_default_value(new ConfigOptionFloat(2));
|
||||||
|
|
||||||
def = this->add("support_tree_branch_diameter_angle", coFloat);
|
def = this->add("support_tree_branch_diameter_angle", coFloat);
|
||||||
def->label = L("Tree Support Branch Diameter Angle");
|
def->label = L("Branch Diameter Angle");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("The angle of the branches' diameter as they gradually become thicker towards the bottom. "
|
def->tooltip = L("The angle of the branches' diameter as they gradually become thicker towards the bottom. "
|
||||||
"An angle of 0 will cause the branches to have uniform thickness over their length. "
|
"An angle of 0 will cause the branches to have uniform thickness over their length. "
|
||||||
"A bit of an angle can increase stability of the tree support.");
|
"A bit of an angle can increase stability of the organic support.");
|
||||||
def->sidetext = L("°");
|
def->sidetext = L("°");
|
||||||
def->min = 0;
|
def->min = 0;
|
||||||
def->max = 15;
|
def->max = 15;
|
||||||
@ -2937,7 +2864,7 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->set_default_value(new ConfigOptionFloat(5));
|
def->set_default_value(new ConfigOptionFloat(5));
|
||||||
|
|
||||||
def = this->add("support_tree_top_rate", coPercent);
|
def = this->add("support_tree_top_rate", coPercent);
|
||||||
def->label = L("Tree Support Branch Density");
|
def->label = L("Branch Density");
|
||||||
def->category = L("Support material");
|
def->category = L("Support material");
|
||||||
def->tooltip = L("Adjusts the density of the support structure used to generate the tips of the branches. "
|
def->tooltip = L("Adjusts the density of the support structure used to generate the tips of the branches. "
|
||||||
"A higher value results in better overhangs, but the supports are harder to remove. "
|
"A higher value results in better overhangs, but the supports are harder to remove. "
|
||||||
@ -3213,11 +3140,10 @@ void PrintConfigDef::init_fff_params()
|
|||||||
"very thin areas is used gap-fill. "
|
"very thin areas is used gap-fill. "
|
||||||
"Arachne engine produces perimeters with variable extrusion width. "
|
"Arachne engine produces perimeters with variable extrusion width. "
|
||||||
"This setting also affects the Concentric infill.");
|
"This setting also affects the Concentric infill.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<PerimeterGeneratorType>::get_enum_values();
|
def->set_enum<PerimeterGeneratorType>({
|
||||||
def->enum_values.push_back("classic");
|
{ "classic", L("Classic") },
|
||||||
def->enum_values.push_back("arachne");
|
{ "arachne", L("Arachne") }
|
||||||
def->enum_labels.push_back(L("Classic"));
|
});
|
||||||
def->enum_labels.push_back(L("Arachne"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<PerimeterGeneratorType>(PerimeterGeneratorType::Arachne));
|
def->set_default_value(new ConfigOptionEnum<PerimeterGeneratorType>(PerimeterGeneratorType::Arachne));
|
||||||
|
|
||||||
@ -3297,11 +3223,10 @@ void PrintConfigDef::init_fff_params()
|
|||||||
def->label = L("Ensure vertical shell infill");
|
def->label = L("Ensure vertical shell infill");
|
||||||
def->category = L("Layers and Perimeters");
|
def->category = L("Layers and Perimeters");
|
||||||
def->tooltip = L("Ensure vertical shell infill.");
|
def->tooltip = L("Ensure vertical shell infill.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<EnsuringInfillPattern>::get_enum_values();
|
def->set_enum<EnsuringInfillPattern>({
|
||||||
def->enum_values.push_back("bounded_rectilinear");
|
{ "bounded_rectilinear", L("Bounded Rectilinear") },
|
||||||
def->enum_values.push_back("concentric");
|
{ "concentric", L("Concentric") }
|
||||||
def->enum_labels.push_back(L("Bounded Rectilinear"));
|
});
|
||||||
def->enum_labels.push_back(L("Concentric"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<EnsuringInfillPattern>(EnsuringInfillPattern::eipBoundedRectilinear));
|
def->set_default_value(new ConfigOptionEnum<EnsuringInfillPattern>(EnsuringInfillPattern::eipBoundedRectilinear));
|
||||||
|
|
||||||
@ -3452,13 +3377,9 @@ void PrintConfigDef::init_sla_support_params(const std::string &prefix)
|
|||||||
" Can be zig-zag, cross (double zig-zag) or dynamic which"
|
" Can be zig-zag, cross (double zig-zag) or dynamic which"
|
||||||
" will automatically switch between the first two depending"
|
" will automatically switch between the first two depending"
|
||||||
" on the distance of the two pillars.");
|
" on the distance of the two pillars.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SLAPillarConnectionMode>::get_enum_values();
|
def->set_enum<SLAPillarConnectionMode>(
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SLAPillarConnectionMode>::get_enum_values();
|
ConfigOptionEnum<SLAPillarConnectionMode>::get_enum_names(),
|
||||||
def->enum_values = ConfigOptionEnum<SLAPillarConnectionMode>::get_enum_names();
|
{ L("Zig-Zag"), L("Cross"), L("Dynamic") });
|
||||||
def->enum_labels = ConfigOptionEnum<SLAPillarConnectionMode>::get_enum_names();
|
|
||||||
def->enum_labels[0] = L("Zig-Zag");
|
|
||||||
def->enum_labels[1] = L("Cross");
|
|
||||||
def->enum_labels[2] = L("Dynamic");
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum(SLAPillarConnectionMode::dynamic));
|
def->set_default_value(new ConfigOptionEnum(SLAPillarConnectionMode::dynamic));
|
||||||
|
|
||||||
@ -3620,11 +3541,10 @@ void PrintConfigDef::init_sla_params()
|
|||||||
def->tooltip = L("Set the actual LCD display orientation inside the SLA printer."
|
def->tooltip = L("Set the actual LCD display orientation inside the SLA printer."
|
||||||
" Portrait mode will flip the meaning of display width and height parameters"
|
" Portrait mode will flip the meaning of display width and height parameters"
|
||||||
" and the output images will be rotated by 90 degrees.");
|
" and the output images will be rotated by 90 degrees.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SLADisplayOrientation>::get_enum_values();
|
def->set_enum<SLADisplayOrientation>({
|
||||||
def->enum_values.push_back("landscape");
|
{ "landscape", L("Landscape") },
|
||||||
def->enum_values.push_back("portrait");
|
{ "portrait", L("Portrait") }
|
||||||
def->enum_labels.push_back(L("Landscape"));
|
});
|
||||||
def->enum_labels.push_back(L("Portrait"));
|
|
||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->set_default_value(new ConfigOptionEnum<SLADisplayOrientation>(sladoPortrait));
|
def->set_default_value(new ConfigOptionEnum<SLADisplayOrientation>(sladoPortrait));
|
||||||
|
|
||||||
@ -3736,13 +3656,9 @@ void PrintConfigDef::init_sla_params()
|
|||||||
def = this->add("material_type", coString);
|
def = this->add("material_type", coString);
|
||||||
def->label = L("SLA material type");
|
def->label = L("SLA material type");
|
||||||
def->tooltip = L("SLA material type");
|
def->tooltip = L("SLA material type");
|
||||||
def->gui_type = ConfigOptionDef::GUIType::f_enum_open; // TODO: ???
|
|
||||||
def->gui_flags = "show_value";
|
def->gui_flags = "show_value";
|
||||||
def->enum_values.push_back("Tough");
|
def->set_enum_values(ConfigOptionDef::GUIType::select_open,
|
||||||
def->enum_values.push_back("Flexible");
|
{ "Tough", "Flexible", "Casting", "Dental", "Heat-resistant" });
|
||||||
def->enum_values.push_back("Casting");
|
|
||||||
def->enum_values.push_back("Dental");
|
|
||||||
def->enum_values.push_back("Heat-resistant");
|
|
||||||
def->set_default_value(new ConfigOptionString("Tough"));
|
def->set_default_value(new ConfigOptionString("Tough"));
|
||||||
|
|
||||||
def = this->add("initial_layer_height", coFloat);
|
def = this->add("initial_layer_height", coFloat);
|
||||||
@ -3916,12 +3832,10 @@ void PrintConfigDef::init_sla_params()
|
|||||||
def = this->add("support_tree_type", coEnum);
|
def = this->add("support_tree_type", coEnum);
|
||||||
def->label = L("Support tree type");
|
def->label = L("Support tree type");
|
||||||
def->tooltip = L("Support tree building strategy");
|
def->tooltip = L("Support tree building strategy");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<sla::SupportTreeType>::get_enum_values();
|
def->set_enum<sla::SupportTreeType>(
|
||||||
def->enum_values = ConfigOptionEnum<sla::SupportTreeType>::get_enum_names();
|
ConfigOptionEnum<sla::SupportTreeType>::get_enum_names(),
|
||||||
def->enum_labels = ConfigOptionEnum<sla::SupportTreeType>::get_enum_names();
|
{ L("Default"), L("Branching (experimental)") });
|
||||||
def->enum_labels[0] = L("Default");
|
// TODO: def->enum_def->labels[2] = L("Organic");
|
||||||
def->enum_labels[1] = L("Branching (experimental)");
|
|
||||||
// TODO: def->enum_labels[2] = L("Organic");
|
|
||||||
def->mode = comSimple;
|
def->mode = comSimple;
|
||||||
def->set_default_value(new ConfigOptionEnum(sla::SupportTreeType::Default));
|
def->set_default_value(new ConfigOptionEnum(sla::SupportTreeType::Default));
|
||||||
|
|
||||||
@ -4125,13 +4039,11 @@ void PrintConfigDef::init_sla_params()
|
|||||||
def->tooltip = L(
|
def->tooltip = L(
|
||||||
"A slower printing profile might be necessary when using materials with higher viscosity "
|
"A slower printing profile might be necessary when using materials with higher viscosity "
|
||||||
"or with some hollowed parts. It slows down the tilt movement and adds a delay before exposure.");
|
"or with some hollowed parts. It slows down the tilt movement and adds a delay before exposure.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<SLAMaterialSpeed>::get_enum_values();
|
def->set_enum<SLAMaterialSpeed>({
|
||||||
def->enum_values.push_back("slow");
|
{ "slow", L("Slow") },
|
||||||
def->enum_values.push_back("fast");
|
{ "fast", L("Fast") },
|
||||||
def->enum_values.push_back("high_viscosity");
|
{ "high_viscosity", L("High viscosity") }
|
||||||
def->enum_labels.push_back(L("Slow"));
|
});
|
||||||
def->enum_labels.push_back(L("Fast"));
|
|
||||||
def->enum_labels.push_back(L("High viscosity"));
|
|
||||||
def->mode = comAdvanced;
|
def->mode = comAdvanced;
|
||||||
def->set_default_value(new ConfigOptionEnum<SLAMaterialSpeed>(slamsFast));
|
def->set_default_value(new ConfigOptionEnum<SLAMaterialSpeed>(slamsFast));
|
||||||
|
|
||||||
@ -4144,11 +4056,27 @@ void PrintConfigDef::init_sla_params()
|
|||||||
def->label = L("SLA output precision");
|
def->label = L("SLA output precision");
|
||||||
def->tooltip = L("Minimum resolution in nanometers");
|
def->tooltip = L("Minimum resolution in nanometers");
|
||||||
def->sidetext = L("mm");
|
def->sidetext = L("mm");
|
||||||
def->min = SCALING_FACTOR;
|
def->min = float(SCALING_FACTOR);
|
||||||
def->mode = comExpert;
|
def->mode = comExpert;
|
||||||
def->set_default_value(new ConfigOptionFloat(0.001));
|
def->set_default_value(new ConfigOptionFloat(0.001));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Ignore the following obsolete configuration keys:
|
||||||
|
static std::set<std::string> PrintConfigDef_ignore = {
|
||||||
|
"clip_multipart_objects",
|
||||||
|
"duplicate_x", "duplicate_y", "gcode_arcs", "multiply_x", "multiply_y",
|
||||||
|
"support_material_tool", "acceleration", "adjust_overhang_flow",
|
||||||
|
"standby_temperature", "scale", "rotate", "duplicate", "duplicate_grid",
|
||||||
|
"start_perimeters_at_concave_points", "start_perimeters_at_non_overhang", "randomize_start",
|
||||||
|
"seal_position", "vibration_limit", "bed_size",
|
||||||
|
"print_center", "g0", "threads", "pressure_advance", "wipe_tower_per_color_wipe",
|
||||||
|
"serial_port", "serial_speed",
|
||||||
|
// Introduced in some PrusaSlicer 2.3.1 alpha, later renamed or removed.
|
||||||
|
"fuzzy_skin_perimeter_mode", "fuzzy_skin_shape",
|
||||||
|
// Introduced in PrusaSlicer 2.3.0-alpha2, later replaced by automatic calculation based on extrusion width.
|
||||||
|
"wall_add_middle_threshold", "wall_split_middle_threshold",
|
||||||
|
};
|
||||||
|
|
||||||
void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &value)
|
void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &value)
|
||||||
{
|
{
|
||||||
// handle legacy options
|
// handle legacy options
|
||||||
@ -4222,32 +4150,17 @@ void PrintConfigDef::handle_legacy(t_config_option_key &opt_key, std::string &va
|
|||||||
}
|
}
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
// Ignore the following obsolete configuration keys:
|
|
||||||
static std::set<std::string> ignore = {
|
|
||||||
"duplicate_x", "duplicate_y", "gcode_arcs", "multiply_x", "multiply_y",
|
|
||||||
"support_material_tool", "acceleration", "adjust_overhang_flow",
|
|
||||||
"standby_temperature", "scale", "rotate", "duplicate", "duplicate_grid",
|
|
||||||
"start_perimeters_at_concave_points", "start_perimeters_at_non_overhang", "randomize_start",
|
|
||||||
"seal_position", "vibration_limit", "bed_size",
|
|
||||||
"print_center", "g0", "threads", "pressure_advance", "wipe_tower_per_color_wipe",
|
|
||||||
"serial_port", "serial_speed",
|
|
||||||
// Introduced in some PrusaSlicer 2.3.1 alpha, later renamed or removed.
|
|
||||||
"fuzzy_skin_perimeter_mode", "fuzzy_skin_shape",
|
|
||||||
// Introduced in PrusaSlicer 2.3.0-alpha2, later replaced by automatic calculation based on extrusion width.
|
|
||||||
"wall_add_middle_threshold", "wall_split_middle_threshold",
|
|
||||||
};
|
|
||||||
|
|
||||||
// In PrusaSlicer 2.3.0-alpha0 the "monotonous" infill was introduced, which was later renamed to "monotonic".
|
// In PrusaSlicer 2.3.0-alpha0 the "monotonous" infill was introduced, which was later renamed to "monotonic".
|
||||||
if (value == "monotonous" && (opt_key == "top_fill_pattern" || opt_key == "bottom_fill_pattern" || opt_key == "fill_pattern"))
|
if (value == "monotonous" && (opt_key == "top_fill_pattern" || opt_key == "bottom_fill_pattern" || opt_key == "fill_pattern"))
|
||||||
value = "monotonic";
|
value = "monotonic";
|
||||||
|
|
||||||
if (ignore.find(opt_key) != ignore.end()) {
|
if (PrintConfigDef_ignore.find(opt_key) != PrintConfigDef_ignore.end()) {
|
||||||
opt_key = "";
|
opt_key = {};
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! print_config_def.has(opt_key)) {
|
if (! print_config_def.has(opt_key)) {
|
||||||
opt_key = "";
|
opt_key = {};
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -4812,13 +4725,11 @@ CLIMiscConfigDef::CLIMiscConfigDef()
|
|||||||
def->tooltip = L("This version of PrusaSlicer may not understand configurations produced by the newest PrusaSlicer versions. "
|
def->tooltip = L("This version of PrusaSlicer may not understand configurations produced by the newest PrusaSlicer versions. "
|
||||||
"For example, newer PrusaSlicer may extend the list of supported firmware flavors. One may decide to "
|
"For example, newer PrusaSlicer may extend the list of supported firmware flavors. One may decide to "
|
||||||
"bail out or to substitute an unknown value with a default silently or verbosely.");
|
"bail out or to substitute an unknown value with a default silently or verbosely.");
|
||||||
def->enum_keys_map = &ConfigOptionEnum<ForwardCompatibilitySubstitutionRule>::get_enum_values();
|
def->set_enum<ForwardCompatibilitySubstitutionRule>({
|
||||||
def->enum_values.push_back("disable");
|
{ "disable", L("Bail out on unknown configuration values") },
|
||||||
def->enum_values.push_back("enable");
|
{ "enable", L("Enable reading unknown configuration values by verbosely substituting them with defaults.") },
|
||||||
def->enum_values.push_back("enable_silent");
|
{ "enable_silent", L("Enable reading unknown configuration values by silently substituting them with defaults.") }
|
||||||
def->enum_labels.push_back(L("Bail out on unknown configuration values"));
|
});
|
||||||
def->enum_labels.push_back(L("Enable reading unknown configuration values by verbosely substituting them with defaults."));
|
|
||||||
def->enum_labels.push_back(L("Enable reading unknown configuration values by silently substituting them with defaults."));
|
|
||||||
def->set_default_value(new ConfigOptionEnum<ForwardCompatibilitySubstitutionRule>(ForwardCompatibilitySubstitutionRule::Enable));
|
def->set_default_value(new ConfigOptionEnum<ForwardCompatibilitySubstitutionRule>(ForwardCompatibilitySubstitutionRule::Enable));
|
||||||
|
|
||||||
def = this->add("load", coStrings);
|
def = this->add("load", coStrings);
|
||||||
@ -4836,12 +4747,6 @@ CLIMiscConfigDef::CLIMiscConfigDef()
|
|||||||
"or an existing PrusaSlicer window is activated. "
|
"or an existing PrusaSlicer window is activated. "
|
||||||
"Overrides the \"single_instance\" configuration value from application preferences.");
|
"Overrides the \"single_instance\" configuration value from application preferences.");
|
||||||
|
|
||||||
/*
|
|
||||||
def = this->add("autosave", coString);
|
|
||||||
def->label = L("Autosave");
|
|
||||||
def->tooltip = L("Automatically export current configuration to the specified file.");
|
|
||||||
*/
|
|
||||||
|
|
||||||
def = this->add("datadir", coString);
|
def = this->add("datadir", coString);
|
||||||
def->label = L("Data directory");
|
def->label = L("Data directory");
|
||||||
def->tooltip = L("Load and store settings at the given directory. This is useful for maintaining different profiles or including configurations from a network storage.");
|
def->tooltip = L("Load and store settings at the given directory. This is useful for maintaining different profiles or including configurations from a network storage.");
|
||||||
|
@ -495,7 +495,6 @@ PRINT_CONFIG_CLASS_DEFINE(
|
|||||||
((ConfigOptionFloat, brim_separation))
|
((ConfigOptionFloat, brim_separation))
|
||||||
((ConfigOptionEnum<BrimType>, brim_type))
|
((ConfigOptionEnum<BrimType>, brim_type))
|
||||||
((ConfigOptionFloat, brim_width))
|
((ConfigOptionFloat, brim_width))
|
||||||
((ConfigOptionBool, clip_multipart_objects))
|
|
||||||
((ConfigOptionBool, dont_support_bridges))
|
((ConfigOptionBool, dont_support_bridges))
|
||||||
((ConfigOptionFloat, elefant_foot_compensation))
|
((ConfigOptionFloat, elefant_foot_compensation))
|
||||||
((ConfigOptionEnum<EnsuringInfillPattern>, ensure_vertical_shell_infill))
|
((ConfigOptionEnum<EnsuringInfillPattern>, ensure_vertical_shell_infill))
|
||||||
@ -764,6 +763,7 @@ PRINT_CONFIG_CLASS_DERIVED_DEFINE(
|
|||||||
((ConfigOptionInts, disable_fan_first_layers))
|
((ConfigOptionInts, disable_fan_first_layers))
|
||||||
((ConfigOptionEnum<DraftShield>, draft_shield))
|
((ConfigOptionEnum<DraftShield>, draft_shield))
|
||||||
((ConfigOptionFloat, duplicate_distance))
|
((ConfigOptionFloat, duplicate_distance))
|
||||||
|
((ConfigOptionFloat, external_perimeter_acceleration))
|
||||||
((ConfigOptionFloat, extruder_clearance_height))
|
((ConfigOptionFloat, extruder_clearance_height))
|
||||||
((ConfigOptionFloat, extruder_clearance_radius))
|
((ConfigOptionFloat, extruder_clearance_radius))
|
||||||
((ConfigOptionStrings, extruder_colour))
|
((ConfigOptionStrings, extruder_colour))
|
||||||
@ -806,12 +806,14 @@ PRINT_CONFIG_CLASS_DERIVED_DEFINE(
|
|||||||
((ConfigOptionInt, skirt_height))
|
((ConfigOptionInt, skirt_height))
|
||||||
((ConfigOptionInt, skirts))
|
((ConfigOptionInt, skirts))
|
||||||
((ConfigOptionInts, slowdown_below_layer_time))
|
((ConfigOptionInts, slowdown_below_layer_time))
|
||||||
|
((ConfigOptionFloat, solid_infill_acceleration))
|
||||||
((ConfigOptionBool, spiral_vase))
|
((ConfigOptionBool, spiral_vase))
|
||||||
((ConfigOptionInt, standby_temperature_delta))
|
((ConfigOptionInt, standby_temperature_delta))
|
||||||
((ConfigOptionInts, temperature))
|
((ConfigOptionInts, temperature))
|
||||||
((ConfigOptionInt, threads))
|
((ConfigOptionInt, threads))
|
||||||
((ConfigOptionPoints, thumbnails))
|
((ConfigOptionPoints, thumbnails))
|
||||||
((ConfigOptionEnum<GCodeThumbnailsFormat>, thumbnails_format))
|
((ConfigOptionEnum<GCodeThumbnailsFormat>, thumbnails_format))
|
||||||
|
((ConfigOptionFloat, top_solid_infill_acceleration))
|
||||||
((ConfigOptionBools, wipe))
|
((ConfigOptionBools, wipe))
|
||||||
((ConfigOptionBool, wipe_tower))
|
((ConfigOptionBool, wipe_tower))
|
||||||
((ConfigOptionFloat, wipe_tower_x))
|
((ConfigOptionFloat, wipe_tower_x))
|
||||||
|
@ -436,8 +436,12 @@ void PrintObject::generate_support_spots()
|
|||||||
float(this->print()->m_config.perimeter_acceleration.getFloat()),
|
float(this->print()->m_config.perimeter_acceleration.getFloat()),
|
||||||
this->config().raft_layers.getInt(), this->config().brim_type.value,
|
this->config().raft_layers.getInt(), this->config().brim_type.value,
|
||||||
float(this->config().brim_width.getFloat())};
|
float(this->config().brim_width.getFloat())};
|
||||||
auto [supp_points, partial_objects] = SupportSpotsGenerator::full_search(this, cancel_func, params);
|
auto [supp_points, partial_objects] = SupportSpotsGenerator::full_search(this, cancel_func, params);
|
||||||
this->m_shared_regions->generated_support_points = {this->trafo_centered(), supp_points, partial_objects};
|
Transform3d po_transform = this->trafo_centered();
|
||||||
|
if (this->layer_count() > 0) {
|
||||||
|
po_transform = Geometry::translation_transform(Vec3d{0, 0, this->layers().front()->bottom_z()}) * po_transform;
|
||||||
|
}
|
||||||
|
this->m_shared_regions->generated_support_points = {po_transform, supp_points, partial_objects};
|
||||||
m_print->throw_if_canceled();
|
m_print->throw_if_canceled();
|
||||||
}
|
}
|
||||||
BOOST_LOG_TRIVIAL(debug) << "Searching support spots - end";
|
BOOST_LOG_TRIVIAL(debug) << "Searching support spots - end";
|
||||||
@ -632,8 +636,7 @@ bool PrintObject::invalidate_state_by_config_options(
|
|||||||
|| opt_key == "slicing_mode") {
|
|| opt_key == "slicing_mode") {
|
||||||
steps.emplace_back(posSlice);
|
steps.emplace_back(posSlice);
|
||||||
} else if (
|
} else if (
|
||||||
opt_key == "clip_multipart_objects"
|
opt_key == "elefant_foot_compensation"
|
||||||
|| opt_key == "elefant_foot_compensation"
|
|
||||||
|| opt_key == "support_material_contact_distance"
|
|| opt_key == "support_material_contact_distance"
|
||||||
|| opt_key == "xy_size_compensation") {
|
|| opt_key == "xy_size_compensation") {
|
||||||
steps.emplace_back(posSlice);
|
steps.emplace_back(posSlice);
|
||||||
@ -1787,6 +1790,8 @@ bool PrintObject::update_layer_height_profile(const ModelObject &model_object, c
|
|||||||
// use the constructor because the assignement is crashing on ASAN OsX
|
// use the constructor because the assignement is crashing on ASAN OsX
|
||||||
layer_height_profile = std::vector<coordf_t>(model_object.layer_height_profile.get());
|
layer_height_profile = std::vector<coordf_t>(model_object.layer_height_profile.get());
|
||||||
// layer_height_profile = model_object.layer_height_profile;
|
// layer_height_profile = model_object.layer_height_profile;
|
||||||
|
// The layer height returned is sampled with high density for the UI layer height painting
|
||||||
|
// and smoothing tool to work.
|
||||||
updated = true;
|
updated = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1801,6 +1806,7 @@ bool PrintObject::update_layer_height_profile(const ModelObject &model_object, c
|
|||||||
if (layer_height_profile.empty()) {
|
if (layer_height_profile.empty()) {
|
||||||
//layer_height_profile = layer_height_profile_adaptive(slicing_parameters, model_object.layer_config_ranges, model_object.volumes);
|
//layer_height_profile = layer_height_profile_adaptive(slicing_parameters, model_object.layer_config_ranges, model_object.volumes);
|
||||||
layer_height_profile = layer_height_profile_from_ranges(slicing_parameters, model_object.layer_config_ranges);
|
layer_height_profile = layer_height_profile_from_ranges(slicing_parameters, model_object.layer_config_ranges);
|
||||||
|
// The layer height profile is already compressed.
|
||||||
updated = true;
|
updated = true;
|
||||||
}
|
}
|
||||||
return updated;
|
return updated;
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
|
#include "ClipperUtils.hpp"
|
||||||
#include "ElephantFootCompensation.hpp"
|
#include "ElephantFootCompensation.hpp"
|
||||||
#include "I18N.hpp"
|
#include "I18N.hpp"
|
||||||
#include "Layer.hpp"
|
#include "Layer.hpp"
|
||||||
#include "MultiMaterialSegmentation.hpp"
|
#include "MultiMaterialSegmentation.hpp"
|
||||||
#include "Print.hpp"
|
#include "Print.hpp"
|
||||||
#include "ClipperUtils.hpp"
|
#include "ShortestPath.hpp"
|
||||||
|
|
||||||
#include <boost/log/trivial.hpp>
|
#include <boost/log/trivial.hpp>
|
||||||
|
|
||||||
@ -237,9 +238,6 @@ static std::vector<std::vector<ExPolygons>> slices_to_regions(
|
|||||||
const PrintObjectRegions &print_object_regions,
|
const PrintObjectRegions &print_object_regions,
|
||||||
const std::vector<float> &zs,
|
const std::vector<float> &zs,
|
||||||
std::vector<VolumeSlices> &&volume_slices,
|
std::vector<VolumeSlices> &&volume_slices,
|
||||||
// If clipping is disabled, then ExPolygons produced by different volumes will never be merged, thus they will be allowed to overlap.
|
|
||||||
// It is up to the model designer to handle these overlaps.
|
|
||||||
const bool clip_multipart_objects,
|
|
||||||
const std::function<void()> &throw_on_cancel_callback)
|
const std::function<void()> &throw_on_cancel_callback)
|
||||||
{
|
{
|
||||||
model_volumes_sort_by_id(model_volumes);
|
model_volumes_sort_by_id(model_volumes);
|
||||||
@ -308,7 +306,7 @@ static std::vector<std::vector<ExPolygons>> slices_to_regions(
|
|||||||
}
|
}
|
||||||
tbb::parallel_for(
|
tbb::parallel_for(
|
||||||
tbb::blocked_range<size_t>(0, zs_complex.size()),
|
tbb::blocked_range<size_t>(0, zs_complex.size()),
|
||||||
[&slices_by_region, &print_object_regions, &zs_complex, &layer_ranges_regions_to_slices, clip_multipart_objects, &throw_on_cancel_callback]
|
[&slices_by_region, &print_object_regions, &zs_complex, &layer_ranges_regions_to_slices, &throw_on_cancel_callback]
|
||||||
(const tbb::blocked_range<size_t> &range) {
|
(const tbb::blocked_range<size_t> &range) {
|
||||||
float z = zs_complex[range.begin()].second;
|
float z = zs_complex[range.begin()].second;
|
||||||
auto it_layer_range = layer_range_first(print_object_regions.layer_ranges, z);
|
auto it_layer_range = layer_range_first(print_object_regions.layer_ranges, z);
|
||||||
@ -359,7 +357,7 @@ static std::vector<std::vector<ExPolygons>> slices_to_regions(
|
|||||||
if (next_region_same_modifier)
|
if (next_region_same_modifier)
|
||||||
// To be used in the following iteration.
|
// To be used in the following iteration.
|
||||||
temp_slices[idx_region + 1].expolygons = std::move(source);
|
temp_slices[idx_region + 1].expolygons = std::move(source);
|
||||||
} else if ((region.model_volume->is_model_part() && clip_multipart_objects) || region.model_volume->is_negative_volume()) {
|
} else if (region.model_volume->is_model_part() || region.model_volume->is_negative_volume()) {
|
||||||
// Clip every non-zero region preceding it.
|
// Clip every non-zero region preceding it.
|
||||||
for (int idx_region2 = 0; idx_region2 < idx_region; ++ idx_region2)
|
for (int idx_region2 = 0; idx_region2 < idx_region; ++ idx_region2)
|
||||||
if (! temp_slices[idx_region2].expolygons.empty()) {
|
if (! temp_slices[idx_region2].expolygons.empty()) {
|
||||||
@ -388,10 +386,7 @@ static std::vector<std::vector<ExPolygons>> slices_to_regions(
|
|||||||
merged = true;
|
merged = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Don't unite the regions if ! clip_multipart_objects. In that case it is user's responsibility
|
if (merged)
|
||||||
// to handle region overlaps. Indeed, one may intentionally let the regions overlap to produce crossing perimeters
|
|
||||||
// for example.
|
|
||||||
if (merged && clip_multipart_objects)
|
|
||||||
expolygons = closing_ex(expolygons, float(scale_(EPSILON)));
|
expolygons = closing_ex(expolygons, float(scale_(EPSILON)));
|
||||||
slices_by_region[temp_slices[i].region_id][z_idx] = std::move(expolygons);
|
slices_by_region[temp_slices[i].region_id][z_idx] = std::move(expolygons);
|
||||||
i = j;
|
i = j;
|
||||||
@ -404,6 +399,10 @@ static std::vector<std::vector<ExPolygons>> slices_to_regions(
|
|||||||
return slices_by_region;
|
return slices_by_region;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Layer::slicing_errors is no more set since 1.41.1 or possibly earlier, thus this code
|
||||||
|
// was not really functional for a long day and nobody missed it.
|
||||||
|
// Could we reuse this fixing code one day?
|
||||||
|
/*
|
||||||
std::string fix_slicing_errors(LayerPtrs &layers, const std::function<void()> &throw_if_canceled)
|
std::string fix_slicing_errors(LayerPtrs &layers, const std::function<void()> &throw_if_canceled)
|
||||||
{
|
{
|
||||||
// Collect layers with slicing errors.
|
// Collect layers with slicing errors.
|
||||||
@ -486,6 +485,7 @@ std::string fix_slicing_errors(LayerPtrs &layers, const std::function<void()> &t
|
|||||||
"The model has overlapping or self-intersecting facets. I tried to repair it, "
|
"The model has overlapping or self-intersecting facets. I tried to repair it, "
|
||||||
"however you might want to check the results or repair the input file and retry.\n";
|
"however you might want to check the results or repair the input file and retry.\n";
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
// Called by make_perimeters()
|
// Called by make_perimeters()
|
||||||
// 1) Decides Z positions of the layers,
|
// 1) Decides Z positions of the layers,
|
||||||
@ -508,12 +508,18 @@ void PrintObject::slice()
|
|||||||
m_layers = new_layers(this, generate_object_layers(m_slicing_params, layer_height_profile));
|
m_layers = new_layers(this, generate_object_layers(m_slicing_params, layer_height_profile));
|
||||||
this->slice_volumes();
|
this->slice_volumes();
|
||||||
m_print->throw_if_canceled();
|
m_print->throw_if_canceled();
|
||||||
|
#if 0
|
||||||
|
// Layer::slicing_errors is no more set since 1.41.1 or possibly earlier, thus this code
|
||||||
|
// was not really functional for a long day and nobody missed it.
|
||||||
|
// Could we reuse this fixing code one day?
|
||||||
|
|
||||||
// Fix the model.
|
// Fix the model.
|
||||||
//FIXME is this the right place to do? It is done repeateadly at the UI and now here at the backend.
|
//FIXME is this the right place to do? It is done repeateadly at the UI and now here at the backend.
|
||||||
std::string warning = fix_slicing_errors(m_layers, [this](){ m_print->throw_if_canceled(); });
|
std::string warning = fix_slicing_errors(m_layers, [this](){ m_print->throw_if_canceled(); });
|
||||||
m_print->throw_if_canceled();
|
m_print->throw_if_canceled();
|
||||||
if (! warning.empty())
|
if (! warning.empty())
|
||||||
BOOST_LOG_TRIVIAL(info) << warning;
|
BOOST_LOG_TRIVIAL(info) << warning;
|
||||||
|
#endif
|
||||||
// Update bounding boxes, back up raw slices of complex models.
|
// Update bounding boxes, back up raw slices of complex models.
|
||||||
tbb::parallel_for(
|
tbb::parallel_for(
|
||||||
tbb::blocked_range<size_t>(0, m_layers.size()),
|
tbb::blocked_range<size_t>(0, m_layers.size()),
|
||||||
@ -696,7 +702,6 @@ void PrintObject::slice_volumes()
|
|||||||
slice_volumes_inner(
|
slice_volumes_inner(
|
||||||
print->config(), this->config(), this->trafo_centered(),
|
print->config(), this->config(), this->trafo_centered(),
|
||||||
this->model_object()->volumes, m_shared_regions->layer_ranges, slice_zs, throw_on_cancel_callback),
|
this->model_object()->volumes, m_shared_regions->layer_ranges, slice_zs, throw_on_cancel_callback),
|
||||||
m_config.clip_multipart_objects,
|
|
||||||
throw_on_cancel_callback);
|
throw_on_cancel_callback);
|
||||||
|
|
||||||
for (size_t region_id = 0; region_id < region_slices.size(); ++ region_id) {
|
for (size_t region_id = 0; region_id < region_slices.size(); ++ region_id) {
|
||||||
@ -806,8 +811,12 @@ void PrintObject::slice_volumes()
|
|||||||
if (elephant_foot_compensation_scaled > 0.f && ! m_layers.empty()) {
|
if (elephant_foot_compensation_scaled > 0.f && ! m_layers.empty()) {
|
||||||
// The Elephant foot has been compensated, therefore the 1st layer's lslices are shrank with the Elephant foot compensation value.
|
// The Elephant foot has been compensated, therefore the 1st layer's lslices are shrank with the Elephant foot compensation value.
|
||||||
// Store the uncompensated value there.
|
// Store the uncompensated value there.
|
||||||
assert(m_layers.front()->id() == 0);
|
//FIXME is this operation needed? MMU painting and brim now have to do work arounds to work with compensated layer, not with the uncompensated layer.
|
||||||
m_layers.front()->lslices = std::move(lslices_1st_layer);
|
// There may be subtle issues removing this block such as support raft sticking too well with the first object layer.
|
||||||
|
Layer &layer = *m_layers.front();
|
||||||
|
assert(layer.id() == 0);
|
||||||
|
layer.lslices = std::move(lslices_1st_layer);
|
||||||
|
layer.lslice_indices_sorted_by_print_order = chain_expolygons(layer.lslices);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1076,6 +1076,15 @@ std::vector<size_t> chain_points(const Points &points, Point *start_near)
|
|||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::vector<size_t> chain_expolygons(const ExPolygons &expolygons, Point *start_near)
|
||||||
|
{
|
||||||
|
Points ordering_points;
|
||||||
|
ordering_points.reserve(expolygons.size());
|
||||||
|
for (const ExPolygon &ex : expolygons)
|
||||||
|
ordering_points.push_back(ex.contour.first_point());
|
||||||
|
return chain_points(ordering_points);
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
// #define DEBUG_SVG_OUTPUT
|
// #define DEBUG_SVG_OUTPUT
|
||||||
#endif /* NDEBUG */
|
#endif /* NDEBUG */
|
||||||
|
@ -12,7 +12,11 @@ namespace ClipperLib { class PolyNode; }
|
|||||||
|
|
||||||
namespace Slic3r {
|
namespace Slic3r {
|
||||||
|
|
||||||
|
class ExPolygon;
|
||||||
|
using ExPolygons = std::vector<ExPolygon>;
|
||||||
|
|
||||||
std::vector<size_t> chain_points(const Points &points, Point *start_near = nullptr);
|
std::vector<size_t> chain_points(const Points &points, Point *start_near = nullptr);
|
||||||
|
std::vector<size_t> chain_expolygons(const ExPolygons &expolygons, Point *start_near = nullptr);
|
||||||
|
|
||||||
std::vector<std::pair<size_t, bool>> chain_extrusion_entities(std::vector<ExtrusionEntity*> &entities, const Point *start_near = nullptr);
|
std::vector<std::pair<size_t, bool>> chain_extrusion_entities(std::vector<ExtrusionEntity*> &entities, const Point *start_near = nullptr);
|
||||||
void reorder_extrusion_entities(std::vector<ExtrusionEntity*> &entities, const std::vector<std::pair<size_t, bool>> &chain);
|
void reorder_extrusion_entities(std::vector<ExtrusionEntity*> &entities, const std::vector<std::pair<size_t, bool>> &chain);
|
||||||
|
@ -183,32 +183,47 @@ std::vector<coordf_t> layer_height_profile_from_ranges(
|
|||||||
// 2) Convert the trimmed ranges to a height profile, fill in the undefined intervals between z=0 and z=slicing_params.object_print_z_max()
|
// 2) Convert the trimmed ranges to a height profile, fill in the undefined intervals between z=0 and z=slicing_params.object_print_z_max()
|
||||||
// with slicing_params.layer_height
|
// with slicing_params.layer_height
|
||||||
std::vector<coordf_t> layer_height_profile;
|
std::vector<coordf_t> layer_height_profile;
|
||||||
for (std::vector<std::pair<t_layer_height_range,coordf_t>>::const_iterator it_range = ranges_non_overlapping.begin(); it_range != ranges_non_overlapping.end(); ++ it_range) {
|
auto last_z = [&layer_height_profile]() {
|
||||||
coordf_t lo = it_range->first.first;
|
return layer_height_profile.empty() ? 0. : *(layer_height_profile.end() - 2);
|
||||||
coordf_t hi = it_range->first.second;
|
};
|
||||||
coordf_t height = it_range->second;
|
auto lh_append = [&layer_height_profile, last_z](coordf_t z, coordf_t layer_height) {
|
||||||
coordf_t last_z = layer_height_profile.empty() ? 0. : layer_height_profile[layer_height_profile.size() - 2];
|
if (! layer_height_profile.empty()) {
|
||||||
if (lo > last_z + EPSILON) {
|
bool last_z_matches = is_approx(*(layer_height_profile.end() - 2), z);
|
||||||
|
bool last_h_matches = is_approx(layer_height_profile.back(), layer_height);
|
||||||
|
if (last_h_matches) {
|
||||||
|
if (last_z_matches) {
|
||||||
|
// Drop a duplicate.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (layer_height_profile.size() >= 4 && is_approx(*(layer_height_profile.end() - 3), layer_height)) {
|
||||||
|
// Third repetition of the same layer_height. Update z of the last entry.
|
||||||
|
*(layer_height_profile.end() - 2) = z;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
layer_height_profile.push_back(z);
|
||||||
|
layer_height_profile.push_back(layer_height);
|
||||||
|
};
|
||||||
|
|
||||||
|
for (const std::pair<t_layer_height_range,coordf_t> &non_overlapping_range : ranges_non_overlapping) {
|
||||||
|
coordf_t lo = non_overlapping_range.first.first;
|
||||||
|
coordf_t hi = non_overlapping_range.first.second;
|
||||||
|
coordf_t height = non_overlapping_range.second;
|
||||||
|
if (coordf_t z = last_z(); lo > z + EPSILON) {
|
||||||
// Insert a step of normal layer height.
|
// Insert a step of normal layer height.
|
||||||
layer_height_profile.push_back(last_z);
|
lh_append(z, slicing_params.layer_height);
|
||||||
layer_height_profile.push_back(slicing_params.layer_height);
|
lh_append(lo, slicing_params.layer_height);
|
||||||
layer_height_profile.push_back(lo);
|
|
||||||
layer_height_profile.push_back(slicing_params.layer_height);
|
|
||||||
}
|
}
|
||||||
// Insert a step of the overriden layer height.
|
// Insert a step of the overriden layer height.
|
||||||
layer_height_profile.push_back(lo);
|
lh_append(lo, height);
|
||||||
layer_height_profile.push_back(height);
|
lh_append(hi, height);
|
||||||
layer_height_profile.push_back(hi);
|
|
||||||
layer_height_profile.push_back(height);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
coordf_t last_z = layer_height_profile.empty() ? 0. : layer_height_profile[layer_height_profile.size() - 2];
|
if (coordf_t z = last_z(); z < slicing_params.object_print_z_height()) {
|
||||||
if (last_z < slicing_params.object_print_z_height()) {
|
|
||||||
// Insert a step of normal layer height up to the object top.
|
// Insert a step of normal layer height up to the object top.
|
||||||
layer_height_profile.push_back(last_z);
|
lh_append(z, slicing_params.layer_height);
|
||||||
layer_height_profile.push_back(slicing_params.layer_height);
|
lh_append(slicing_params.object_print_z_height(), slicing_params.layer_height);
|
||||||
layer_height_profile.push_back(slicing_params.object_print_z_height());
|
|
||||||
layer_height_profile.push_back(slicing_params.layer_height);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return layer_height_profile;
|
return layer_height_profile;
|
||||||
@ -294,7 +309,7 @@ std::vector<double> layer_height_profile_adaptive(const SlicingParameters& slici
|
|||||||
print_z += height;
|
print_z += height;
|
||||||
}
|
}
|
||||||
|
|
||||||
double z_gap = slicing_params.object_print_z_height() - layer_height_profile[layer_height_profile.size() - 2];
|
double z_gap = slicing_params.object_print_z_height() - *(layer_height_profile.end() - 2);
|
||||||
if (z_gap > 0.0)
|
if (z_gap > 0.0)
|
||||||
{
|
{
|
||||||
layer_height_profile.push_back(slicing_params.object_print_z_height());
|
layer_height_profile.push_back(slicing_params.object_print_z_height());
|
||||||
@ -632,6 +647,40 @@ std::vector<coordf_t> generate_object_layers(
|
|||||||
return out;
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check whether the layer height profile describes a fixed layer height profile.
|
||||||
|
bool check_object_layers_fixed(
|
||||||
|
const SlicingParameters &slicing_params,
|
||||||
|
const std::vector<coordf_t> &layer_height_profile)
|
||||||
|
{
|
||||||
|
assert(layer_height_profile.size() >= 4);
|
||||||
|
assert(layer_height_profile.size() % 2 == 0);
|
||||||
|
assert(layer_height_profile[0] == 0);
|
||||||
|
|
||||||
|
if (layer_height_profile.size() != 4 && layer_height_profile.size() != 8)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
bool fixed_step1 = is_approx(layer_height_profile[1], layer_height_profile[3]);
|
||||||
|
bool fixed_step2 = layer_height_profile.size() == 4 ||
|
||||||
|
(layer_height_profile[2] == layer_height_profile[4] && is_approx(layer_height_profile[5], layer_height_profile[7]));
|
||||||
|
|
||||||
|
if (! fixed_step1 || ! fixed_step2)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
if (layer_height_profile[2] < 0.5 * slicing_params.first_object_layer_height + EPSILON ||
|
||||||
|
! is_approx(layer_height_profile[3], slicing_params.first_object_layer_height))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
double z_max = layer_height_profile[layer_height_profile.size() - 2];
|
||||||
|
double z_2nd = slicing_params.first_object_layer_height + 0.5 * slicing_params.layer_height;
|
||||||
|
if (z_2nd > z_max)
|
||||||
|
return true;
|
||||||
|
if (z_2nd < *(layer_height_profile.end() - 4) + EPSILON ||
|
||||||
|
! is_approx(layer_height_profile.back(), slicing_params.layer_height))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
int generate_layer_height_texture(
|
int generate_layer_height_texture(
|
||||||
const SlicingParameters &slicing_params,
|
const SlicingParameters &slicing_params,
|
||||||
const std::vector<coordf_t> &layers,
|
const std::vector<coordf_t> &layers,
|
||||||
|
@ -129,11 +129,11 @@ inline bool equal_layering(const SlicingParameters &sp1, const SlicingParameters
|
|||||||
typedef std::pair<coordf_t,coordf_t> t_layer_height_range;
|
typedef std::pair<coordf_t,coordf_t> t_layer_height_range;
|
||||||
typedef std::map<t_layer_height_range, ModelConfig> t_layer_config_ranges;
|
typedef std::map<t_layer_height_range, ModelConfig> t_layer_config_ranges;
|
||||||
|
|
||||||
extern std::vector<coordf_t> layer_height_profile_from_ranges(
|
std::vector<coordf_t> layer_height_profile_from_ranges(
|
||||||
const SlicingParameters &slicing_params,
|
const SlicingParameters &slicing_params,
|
||||||
const t_layer_config_ranges &layer_config_ranges);
|
const t_layer_config_ranges &layer_config_ranges);
|
||||||
|
|
||||||
extern std::vector<double> layer_height_profile_adaptive(
|
std::vector<double> layer_height_profile_adaptive(
|
||||||
const SlicingParameters& slicing_params,
|
const SlicingParameters& slicing_params,
|
||||||
const ModelObject& object, float quality_factor);
|
const ModelObject& object, float quality_factor);
|
||||||
|
|
||||||
@ -146,7 +146,7 @@ struct HeightProfileSmoothingParams
|
|||||||
HeightProfileSmoothingParams(unsigned int radius, bool keep_min) : radius(radius), keep_min(keep_min) {}
|
HeightProfileSmoothingParams(unsigned int radius, bool keep_min) : radius(radius), keep_min(keep_min) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
extern std::vector<double> smooth_height_profile(
|
std::vector<double> smooth_height_profile(
|
||||||
const std::vector<double>& profile, const SlicingParameters& slicing_params,
|
const std::vector<double>& profile, const SlicingParameters& slicing_params,
|
||||||
const HeightProfileSmoothingParams& smoothing_params);
|
const HeightProfileSmoothingParams& smoothing_params);
|
||||||
|
|
||||||
@ -157,7 +157,7 @@ enum LayerHeightEditActionType : unsigned int {
|
|||||||
LAYER_HEIGHT_EDIT_ACTION_SMOOTH = 3
|
LAYER_HEIGHT_EDIT_ACTION_SMOOTH = 3
|
||||||
};
|
};
|
||||||
|
|
||||||
extern void adjust_layer_height_profile(
|
void adjust_layer_height_profile(
|
||||||
const SlicingParameters &slicing_params,
|
const SlicingParameters &slicing_params,
|
||||||
std::vector<coordf_t> &layer_height_profile,
|
std::vector<coordf_t> &layer_height_profile,
|
||||||
coordf_t z,
|
coordf_t z,
|
||||||
@ -167,14 +167,19 @@ extern void adjust_layer_height_profile(
|
|||||||
|
|
||||||
// Produce object layers as pairs of low / high layer boundaries, stored into a linear vector.
|
// Produce object layers as pairs of low / high layer boundaries, stored into a linear vector.
|
||||||
// The object layers are based at z=0, ignoring the raft layers.
|
// The object layers are based at z=0, ignoring the raft layers.
|
||||||
extern std::vector<coordf_t> generate_object_layers(
|
std::vector<coordf_t> generate_object_layers(
|
||||||
|
const SlicingParameters &slicing_params,
|
||||||
|
const std::vector<coordf_t> &layer_height_profile);
|
||||||
|
|
||||||
|
// Check whether the layer height profile describes a fixed layer height profile.
|
||||||
|
bool check_object_layers_fixed(
|
||||||
const SlicingParameters &slicing_params,
|
const SlicingParameters &slicing_params,
|
||||||
const std::vector<coordf_t> &layer_height_profile);
|
const std::vector<coordf_t> &layer_height_profile);
|
||||||
|
|
||||||
// Produce a 1D texture packed into a 2D texture describing in the RGBA format
|
// Produce a 1D texture packed into a 2D texture describing in the RGBA format
|
||||||
// the planned object layers.
|
// the planned object layers.
|
||||||
// Returns number of cells used by the texture of the 0th LOD level.
|
// Returns number of cells used by the texture of the 0th LOD level.
|
||||||
extern int generate_layer_height_texture(
|
int generate_layer_height_texture(
|
||||||
const SlicingParameters &slicing_params,
|
const SlicingParameters &slicing_params,
|
||||||
const std::vector<coordf_t> &layers,
|
const std::vector<coordf_t> &layers,
|
||||||
void *data, int rows, int cols, bool level_of_detail_2nd_level);
|
void *data, int rows, int cols, bool level_of_detail_2nd_level);
|
||||||
|
@ -1260,87 +1260,86 @@ namespace SupportMaterialInternal {
|
|||||||
collect_bridging_perimeter_areas(*static_cast<const ExtrusionLoop*>(ee), expansion_scaled, out);
|
collect_bridging_perimeter_areas(*static_cast<const ExtrusionLoop*>(ee), expansion_scaled, out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static void remove_bridges_from_contacts(
|
void remove_bridges_from_contacts(
|
||||||
const PrintConfig &print_config,
|
const PrintConfig &print_config,
|
||||||
const Layer &lower_layer,
|
const Layer &lower_layer,
|
||||||
const Polygons &lower_layer_polygons,
|
const LayerRegion &layerm,
|
||||||
const LayerRegion &layerm,
|
float fw,
|
||||||
float fw,
|
Polygons &contact_polygons)
|
||||||
Polygons &contact_polygons)
|
{
|
||||||
|
// compute the area of bridging perimeters
|
||||||
|
Polygons bridges;
|
||||||
{
|
{
|
||||||
// compute the area of bridging perimeters
|
// Surface supporting this layer, expanded by 0.5 * nozzle_diameter, as we consider this kind of overhang to be sufficiently supported.
|
||||||
Polygons bridges;
|
Polygons lower_grown_slices = expand(lower_layer.lslices,
|
||||||
{
|
//FIXME to mimic the decision in the perimeter generator, we should use half the external perimeter width.
|
||||||
// Surface supporting this layer, expanded by 0.5 * nozzle_diameter, as we consider this kind of overhang to be sufficiently supported.
|
0.5f * float(scale_(print_config.nozzle_diameter.get_at(layerm.region().config().perimeter_extruder-1))),
|
||||||
Polygons lower_grown_slices = expand(lower_layer_polygons,
|
SUPPORT_SURFACES_OFFSET_PARAMETERS);
|
||||||
//FIXME to mimic the decision in the perimeter generator, we should use half the external perimeter width.
|
// Collect perimeters of this layer.
|
||||||
0.5f * float(scale_(print_config.nozzle_diameter.get_at(layerm.region().config().perimeter_extruder-1))),
|
//FIXME split_at_first_point() could split a bridge mid-way
|
||||||
SUPPORT_SURFACES_OFFSET_PARAMETERS);
|
#if 0
|
||||||
// Collect perimeters of this layer.
|
Polylines overhang_perimeters = layerm.perimeters.as_polylines();
|
||||||
//FIXME split_at_first_point() could split a bridge mid-way
|
// workaround for Clipper bug, see Slic3r::Polygon::clip_as_polyline()
|
||||||
#if 0
|
for (Polyline &polyline : overhang_perimeters)
|
||||||
Polylines overhang_perimeters = layerm.perimeters.as_polylines();
|
polyline.points[0].x += 1;
|
||||||
// workaround for Clipper bug, see Slic3r::Polygon::clip_as_polyline()
|
// Trim the perimeters of this layer by the lower layer to get the unsupported pieces of perimeters.
|
||||||
for (Polyline &polyline : overhang_perimeters)
|
overhang_perimeters = diff_pl(overhang_perimeters, lower_grown_slices);
|
||||||
polyline.points[0].x += 1;
|
#else
|
||||||
// Trim the perimeters of this layer by the lower layer to get the unsupported pieces of perimeters.
|
Polylines overhang_perimeters = diff_pl(layerm.perimeters().as_polylines(), lower_grown_slices);
|
||||||
overhang_perimeters = diff_pl(overhang_perimeters, lower_grown_slices);
|
#endif
|
||||||
#else
|
|
||||||
Polylines overhang_perimeters = diff_pl(layerm.perimeters().as_polylines(), lower_grown_slices);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// only consider straight overhangs
|
// only consider straight overhangs
|
||||||
// only consider overhangs having endpoints inside layer's slices
|
// only consider overhangs having endpoints inside layer's slices
|
||||||
// convert bridging polylines into polygons by inflating them with their thickness
|
// convert bridging polylines into polygons by inflating them with their thickness
|
||||||
// since we're dealing with bridges, we can't assume width is larger than spacing,
|
// since we're dealing with bridges, we can't assume width is larger than spacing,
|
||||||
// so we take the largest value and also apply safety offset to be ensure no gaps
|
// so we take the largest value and also apply safety offset to be ensure no gaps
|
||||||
// are left in between
|
// are left in between
|
||||||
Flow perimeter_bridge_flow = layerm.bridging_flow(frPerimeter);
|
Flow perimeter_bridge_flow = layerm.bridging_flow(frPerimeter);
|
||||||
//FIXME one may want to use a maximum of bridging flow width and normal flow width, as the perimeters are calculated using the normal flow
|
//FIXME one may want to use a maximum of bridging flow width and normal flow width, as the perimeters are calculated using the normal flow
|
||||||
// and then turned to bridging flow, thus their centerlines are derived from non-bridging flow and expanding them by a bridging flow
|
// and then turned to bridging flow, thus their centerlines are derived from non-bridging flow and expanding them by a bridging flow
|
||||||
// may not expand them to the edge of their respective islands.
|
// may not expand them to the edge of their respective islands.
|
||||||
const float w = float(0.5 * std::max(perimeter_bridge_flow.scaled_width(), perimeter_bridge_flow.scaled_spacing())) + scaled<float>(0.001);
|
const float w = float(0.5 * std::max(perimeter_bridge_flow.scaled_width(), perimeter_bridge_flow.scaled_spacing())) + scaled<float>(0.001);
|
||||||
for (Polyline &polyline : overhang_perimeters)
|
for (Polyline &polyline : overhang_perimeters)
|
||||||
if (polyline.is_straight()) {
|
if (polyline.is_straight()) {
|
||||||
// This is a bridge
|
// This is a bridge
|
||||||
polyline.extend_start(fw);
|
polyline.extend_start(fw);
|
||||||
polyline.extend_end(fw);
|
polyline.extend_end(fw);
|
||||||
// Is the straight perimeter segment supported at both sides?
|
// Is the straight perimeter segment supported at both sides?
|
||||||
Point pts[2] = { polyline.first_point(), polyline.last_point() };
|
Point pts[2] = { polyline.first_point(), polyline.last_point() };
|
||||||
bool supported[2] = { false, false };
|
bool supported[2] = { false, false };
|
||||||
for (size_t i = 0; i < lower_layer.lslices.size() && ! (supported[0] && supported[1]); ++ i)
|
for (size_t i = 0; i < lower_layer.lslices.size() && ! (supported[0] && supported[1]); ++ i)
|
||||||
for (int j = 0; j < 2; ++ j)
|
for (int j = 0; j < 2; ++ j)
|
||||||
if (! supported[j] && lower_layer.lslices_ex[i].bbox.contains(pts[j]) && lower_layer.lslices[i].contains(pts[j]))
|
if (! supported[j] && lower_layer.lslices_ex[i].bbox.contains(pts[j]) && lower_layer.lslices[i].contains(pts[j]))
|
||||||
supported[j] = true;
|
supported[j] = true;
|
||||||
if (supported[0] && supported[1])
|
if (supported[0] && supported[1])
|
||||||
// Offset a polyline into a thick line.
|
// Offset a polyline into a thick line.
|
||||||
polygons_append(bridges, offset(polyline, w));
|
polygons_append(bridges, offset(polyline, w));
|
||||||
}
|
}
|
||||||
bridges = union_(bridges);
|
bridges = union_(bridges);
|
||||||
}
|
|
||||||
// remove the entire bridges and only support the unsupported edges
|
|
||||||
//FIXME the bridged regions are already collected as layerm.bridged. Use it?
|
|
||||||
for (const Surface &surface : layerm.fill_surfaces())
|
|
||||||
if (surface.surface_type == stBottomBridge && surface.bridge_angle >= 0.0)
|
|
||||||
polygons_append(bridges, surface.expolygon);
|
|
||||||
//FIXME add the gap filled areas. Extrude the gaps with a bridge flow?
|
|
||||||
// Remove the unsupported ends of the bridges from the bridged areas.
|
|
||||||
//FIXME add supports at regular intervals to support long bridges!
|
|
||||||
bridges = diff(bridges,
|
|
||||||
// Offset unsupported edges into polygons.
|
|
||||||
offset(layerm.unsupported_bridge_edges(), scale_(SUPPORT_MATERIAL_MARGIN), SUPPORT_SURFACES_OFFSET_PARAMETERS));
|
|
||||||
// Remove bridged areas from the supported areas.
|
|
||||||
contact_polygons = diff(contact_polygons, bridges, ApplySafetyOffset::Yes);
|
|
||||||
|
|
||||||
#ifdef SLIC3R_DEBUG
|
|
||||||
static int iRun = 0;
|
|
||||||
SVG::export_expolygons(debug_out_path("support-top-contacts-remove-bridges-run%d.svg", iRun ++),
|
|
||||||
{ { { union_ex(offset(layerm.unsupported_bridge_edges(), scale_(SUPPORT_MATERIAL_MARGIN), SUPPORT_SURFACES_OFFSET_PARAMETERS)) }, { "unsupported_bridge_edges", "orange", 0.5f } },
|
|
||||||
{ { union_ex(contact_polygons) }, { "contact_polygons", "blue", 0.5f } },
|
|
||||||
{ { union_ex(bridges) }, { "bridges", "red", "black", "", scaled<coord_t>(0.1f), 0.5f } } });
|
|
||||||
#endif /* SLIC3R_DEBUG */
|
|
||||||
}
|
}
|
||||||
|
// remove the entire bridges and only support the unsupported edges
|
||||||
|
//FIXME the bridged regions are already collected as layerm.bridged. Use it?
|
||||||
|
for (const Surface &surface : layerm.fill_surfaces())
|
||||||
|
if (surface.surface_type == stBottomBridge && surface.bridge_angle >= 0.0)
|
||||||
|
polygons_append(bridges, surface.expolygon);
|
||||||
|
//FIXME add the gap filled areas. Extrude the gaps with a bridge flow?
|
||||||
|
// Remove the unsupported ends of the bridges from the bridged areas.
|
||||||
|
//FIXME add supports at regular intervals to support long bridges!
|
||||||
|
bridges = diff(bridges,
|
||||||
|
// Offset unsupported edges into polygons.
|
||||||
|
offset(layerm.unsupported_bridge_edges(), scale_(SUPPORT_MATERIAL_MARGIN), SUPPORT_SURFACES_OFFSET_PARAMETERS));
|
||||||
|
// Remove bridged areas from the supported areas.
|
||||||
|
contact_polygons = diff(contact_polygons, bridges, ApplySafetyOffset::Yes);
|
||||||
|
|
||||||
|
#ifdef SLIC3R_DEBUG
|
||||||
|
static int iRun = 0;
|
||||||
|
SVG::export_expolygons(debug_out_path("support-top-contacts-remove-bridges-run%d.svg", iRun ++),
|
||||||
|
{ { { union_ex(offset(layerm.unsupported_bridge_edges(), scale_(SUPPORT_MATERIAL_MARGIN), SUPPORT_SURFACES_OFFSET_PARAMETERS)) }, { "unsupported_bridge_edges", "orange", 0.5f } },
|
||||||
|
{ { union_ex(contact_polygons) }, { "contact_polygons", "blue", 0.5f } },
|
||||||
|
{ { union_ex(bridges) }, { "bridges", "red", "black", "", scaled<coord_t>(0.1f), 0.5f } } });
|
||||||
|
#endif /* SLIC3R_DEBUG */
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<Polygons> PrintObjectSupportMaterial::buildplate_covered(const PrintObject &object) const
|
std::vector<Polygons> PrintObjectSupportMaterial::buildplate_covered(const PrintObject &object) const
|
||||||
@ -1558,8 +1557,7 @@ static inline std::tuple<Polygons, Polygons, Polygons, float> detect_overhangs(
|
|||||||
|
|
||||||
if (object_config.dont_support_bridges)
|
if (object_config.dont_support_bridges)
|
||||||
//FIXME Expensive, potentially not precise enough. Misses gap fill extrusions, which bridge.
|
//FIXME Expensive, potentially not precise enough. Misses gap fill extrusions, which bridge.
|
||||||
SupportMaterialInternal::remove_bridges_from_contacts(
|
remove_bridges_from_contacts(print_config, lower_layer, *layerm, fw, diff_polygons);
|
||||||
print_config, lower_layer, lower_layer_polygons, *layerm, fw, diff_polygons);
|
|
||||||
|
|
||||||
if (diff_polygons.empty())
|
if (diff_polygons.empty())
|
||||||
continue;
|
continue;
|
||||||
@ -3246,6 +3244,10 @@ static Polylines draw_perimeters(const ExPolygon &expoly, double clip_length)
|
|||||||
for (size_t i = 0; i <= expoly.holes.size(); ++ i) {
|
for (size_t i = 0; i <= expoly.holes.size(); ++ i) {
|
||||||
Polyline pl(i == 0 ? expoly.contour.points : expoly.holes[i - 1].points);
|
Polyline pl(i == 0 ? expoly.contour.points : expoly.holes[i - 1].points);
|
||||||
pl.points.emplace_back(pl.points.front());
|
pl.points.emplace_back(pl.points.front());
|
||||||
|
if (i > 0)
|
||||||
|
// It is a hole, reverse it.
|
||||||
|
pl.reverse();
|
||||||
|
// so that all contours are CCW oriented.
|
||||||
pl.clip_end(clip_length);
|
pl.clip_end(clip_length);
|
||||||
polylines.emplace_back(std::move(pl));
|
polylines.emplace_back(std::move(pl));
|
||||||
}
|
}
|
||||||
@ -3351,13 +3353,17 @@ static inline void tree_supports_generate_paths(
|
|||||||
const double anchor_length = spacing * 6.;
|
const double anchor_length = spacing * 6.;
|
||||||
ClipperLib_Z::Paths anchor_candidates;
|
ClipperLib_Z::Paths anchor_candidates;
|
||||||
for (ExPolygon& expoly : closing_ex(polygons, float(SCALED_EPSILON), float(SCALED_EPSILON + 0.5 * flow.scaled_width()))) {
|
for (ExPolygon& expoly : closing_ex(polygons, float(SCALED_EPSILON), float(SCALED_EPSILON + 0.5 * flow.scaled_width()))) {
|
||||||
|
std::unique_ptr<ExtrusionEntityCollection> eec;
|
||||||
double area = expoly.area();
|
double area = expoly.area();
|
||||||
if (area > sqr(scaled<double>(5.))) {
|
if (area > sqr(scaled<double>(5.))) {
|
||||||
|
eec = std::make_unique<ExtrusionEntityCollection>();
|
||||||
|
// Don't reoder internal / external loops of the same island, always start with the internal loop.
|
||||||
|
eec->no_sort = true;
|
||||||
// Make the tree branch stable by adding another perimeter.
|
// Make the tree branch stable by adding another perimeter.
|
||||||
ExPolygons level2 = offset2_ex({ expoly }, -1.5 * flow.scaled_width(), 0.5 * flow.scaled_width());
|
ExPolygons level2 = offset2_ex({ expoly }, -1.5 * flow.scaled_width(), 0.5 * flow.scaled_width());
|
||||||
if (level2.size() == 1) {
|
if (level2.size() == 1) {
|
||||||
Polylines polylines;
|
Polylines polylines;
|
||||||
extrusion_entities_append_paths(dst, draw_perimeters(expoly, clip_length), ExtrusionRole::SupportMaterial, flow.mm3_per_mm(), flow.width(), flow.height(),
|
extrusion_entities_append_paths(eec->entities, draw_perimeters(expoly, clip_length), ExtrusionRole::SupportMaterial, flow.mm3_per_mm(), flow.width(), flow.height(),
|
||||||
// Disable reversal of the path, always start with the anchor, always print CCW.
|
// Disable reversal of the path, always start with the anchor, always print CCW.
|
||||||
false);
|
false);
|
||||||
expoly = level2.front();
|
expoly = level2.front();
|
||||||
@ -3369,20 +3375,21 @@ static inline void tree_supports_generate_paths(
|
|||||||
// The anchor candidate points are annotated with an index of the source contour or with -1 if on intersection.
|
// The anchor candidate points are annotated with an index of the source contour or with -1 if on intersection.
|
||||||
anchor_candidates.clear();
|
anchor_candidates.clear();
|
||||||
shrink_expolygon_with_contour_idx(expoly, flow.scaled_width(), DefaultJoinType, 1.2, anchor_candidates);
|
shrink_expolygon_with_contour_idx(expoly, flow.scaled_width(), DefaultJoinType, 1.2, anchor_candidates);
|
||||||
// Orient all contours CCW.
|
// Orient all contours CW.
|
||||||
for (auto &path : anchor_candidates)
|
for (auto &path : anchor_candidates)
|
||||||
if (ClipperLib_Z::Area(path) < 0)
|
if (ClipperLib_Z::Area(path) > 0)
|
||||||
std::reverse(path.begin(), path.end());
|
std::reverse(path.begin(), path.end());
|
||||||
|
|
||||||
// Draw the perimeters.
|
// Draw the perimeters.
|
||||||
Polylines polylines;
|
Polylines polylines;
|
||||||
polylines.reserve(expoly.holes.size() + 1);
|
polylines.reserve(expoly.holes.size() + 1);
|
||||||
for (size_t idx_loop = 0; idx_loop <= expoly.holes.size(); ++ idx_loop) {
|
for (size_t idx_loop = 0; idx_loop < expoly.num_contours(); ++ idx_loop) {
|
||||||
// Open the loop with a seam.
|
// Open the loop with a seam.
|
||||||
const Polygon &loop = idx_loop == 0 ? expoly.contour : expoly.holes[idx_loop - 1];
|
const Polygon &loop = expoly.contour_or_hole(idx_loop);
|
||||||
Polyline pl(loop.points);
|
Polyline pl(loop.points);
|
||||||
// Orient all contours CCW.
|
// Orient all contours CW, because the anchor will be added to the end of polyline while we want to start a loop with the anchor.
|
||||||
if (loop.area() < 0)
|
if (idx_loop == 0)
|
||||||
|
// It is an outer contour.
|
||||||
pl.reverse();
|
pl.reverse();
|
||||||
pl.points.emplace_back(pl.points.front());
|
pl.points.emplace_back(pl.points.front());
|
||||||
pl.clip_end(clip_length);
|
pl.clip_end(clip_length);
|
||||||
@ -3421,7 +3428,7 @@ static inline void tree_supports_generate_paths(
|
|||||||
}
|
}
|
||||||
if (d2min < sqr(flow.scaled_width() * 3.)) {
|
if (d2min < sqr(flow.scaled_width() * 3.)) {
|
||||||
// Try to cut an anchor from the closest_contour.
|
// Try to cut an anchor from the closest_contour.
|
||||||
// Both closest_contour and pl are CCW oriented.
|
// Both closest_contour and pl are CW oriented.
|
||||||
pl.points.emplace_back(closest_point.cast<coord_t>());
|
pl.points.emplace_back(closest_point.cast<coord_t>());
|
||||||
const ClipperLib_Z::Path &path = *closest_contour;
|
const ClipperLib_Z::Path &path = *closest_contour;
|
||||||
double remaining_length = anchor_length - (seam_pt - closest_point).norm();
|
double remaining_length = anchor_length - (seam_pt - closest_point).norm();
|
||||||
@ -3460,9 +3467,15 @@ static inline void tree_supports_generate_paths(
|
|||||||
pl.reverse();
|
pl.reverse();
|
||||||
polylines.emplace_back(std::move(pl));
|
polylines.emplace_back(std::move(pl));
|
||||||
}
|
}
|
||||||
extrusion_entities_append_paths(dst, polylines, ExtrusionRole::SupportMaterial, flow.mm3_per_mm(), flow.width(), flow.height(),
|
|
||||||
|
ExtrusionEntitiesPtr &out = eec ? eec->entities : dst;
|
||||||
|
extrusion_entities_append_paths(out, std::move(polylines), ExtrusionRole::SupportMaterial, flow.mm3_per_mm(), flow.width(), flow.height(),
|
||||||
// Disable reversal of the path, always start with the anchor, always print CCW.
|
// Disable reversal of the path, always start with the anchor, always print CCW.
|
||||||
false);
|
false);
|
||||||
|
if (eec) {
|
||||||
|
std::reverse(eec->entities.begin(), eec->entities.end());
|
||||||
|
dst.emplace_back(eec.release());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -147,6 +147,15 @@ struct SupportParameters {
|
|||||||
bool with_sheath;
|
bool with_sheath;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// Remove bridges from support contact areas.
|
||||||
|
// To be called if PrintObjectConfig::dont_support_bridges.
|
||||||
|
void remove_bridges_from_contacts(
|
||||||
|
const PrintConfig &print_config,
|
||||||
|
const Layer &lower_layer,
|
||||||
|
const LayerRegion &layerm,
|
||||||
|
float fw,
|
||||||
|
Polygons &contact_polygons);
|
||||||
|
|
||||||
// Generate raft layers, also expand the 1st support layer
|
// Generate raft layers, also expand the 1st support layer
|
||||||
// in case there is no raft layer to improve support adhesion.
|
// in case there is no raft layer to improve support adhesion.
|
||||||
SupportGeneratorLayersPtr generate_raft_base(
|
SupportGeneratorLayersPtr generate_raft_base(
|
||||||
|
@ -659,7 +659,10 @@ std::tuple<ObjectPart, float> build_object_part_from_slice(const size_t &slice_i
|
|||||||
if (params.brim_type == BrimType::btOuterAndInner || params.brim_type == BrimType::btOuterOnly) {
|
if (params.brim_type == BrimType::btOuterAndInner || params.brim_type == BrimType::btOuterOnly) {
|
||||||
Polygon brim_hole = slice_poly.contour;
|
Polygon brim_hole = slice_poly.contour;
|
||||||
brim_hole.reverse();
|
brim_hole.reverse();
|
||||||
brim.push_back(ExPolygon{expand(slice_poly.contour, scale_(params.brim_width)).front(), brim_hole});
|
Polygons c = expand(slice_poly.contour, scale_(params.brim_width)); // For very small polygons, the expand may result in empty vector, even thought the input is correct.
|
||||||
|
if (!c.empty()) {
|
||||||
|
brim.push_back(ExPolygon{c.front(), brim_hole});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (params.brim_type == BrimType::btOuterAndInner || params.brim_type == BrimType::btInnerOnly) {
|
if (params.brim_type == BrimType::btOuterAndInner || params.brim_type == BrimType::btInnerOnly) {
|
||||||
Polygons brim_contours = slice_poly.holes;
|
Polygons brim_contours = slice_poly.holes;
|
||||||
@ -951,7 +954,7 @@ std::tuple<SupportPoints, PartialObjects> check_stability(const PrintObject *po,
|
|||||||
float unchecked_dist = params.min_distance_between_support_points + 1.0f;
|
float unchecked_dist = params.min_distance_between_support_points + 1.0f;
|
||||||
|
|
||||||
for (const ExtrusionLine &line : current_slice_ext_perims_lines) {
|
for (const ExtrusionLine &line : current_slice_ext_perims_lines) {
|
||||||
if ((unchecked_dist + line.len < params.min_distance_between_support_points && line.curled_up_height < 0.3f) ||
|
if ((unchecked_dist + line.len < params.min_distance_between_support_points && line.curled_up_height < params.curling_tolerance_limit) ||
|
||||||
line.len < EPSILON) {
|
line.len < EPSILON) {
|
||||||
unchecked_dist += line.len;
|
unchecked_dist += line.len;
|
||||||
} else {
|
} else {
|
||||||
@ -1074,14 +1077,14 @@ void estimate_supports_malformations(SupportLayerPtrs &layers, float flow_width,
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (const ExtrusionLine &line : current_layer_lines) {
|
for (const ExtrusionLine &line : current_layer_lines) {
|
||||||
if (line.curled_up_height > 0.3f) {
|
if (line.curled_up_height > params.curling_tolerance_limit) {
|
||||||
l->malformed_lines.push_back(Line{Point::new_scale(line.a), Point::new_scale(line.b)});
|
l->malformed_lines.push_back(Line{Point::new_scale(line.a), Point::new_scale(line.b)});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG_FILES
|
#ifdef DEBUG_FILES
|
||||||
for (const ExtrusionLine &line : current_layer_lines) {
|
for (const ExtrusionLine &line : current_layer_lines) {
|
||||||
if (line.curled_up_height > 0.3f) {
|
if (line.curled_up_height > params.curling_tolerance_limit) {
|
||||||
Vec3f color = value_to_rgbf(-EPSILON, l->height * params.max_curled_height_factor, line.curled_up_height);
|
Vec3f color = value_to_rgbf(-EPSILON, l->height * params.max_curled_height_factor, line.curled_up_height);
|
||||||
fprintf(debug_file, "v %f %f %f %f %f %f\n", line.b[0], line.b[1], l->print_z, color[0], color[1], color[2]);
|
fprintf(debug_file, "v %f %f %f %f %f %f\n", line.b[0], line.b[1], l->print_z, color[0], color[1], color[2]);
|
||||||
}
|
}
|
||||||
@ -1147,14 +1150,14 @@ void estimate_malformations(LayerPtrs &layers, const Params ¶ms)
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (const ExtrusionLine &line : current_layer_lines) {
|
for (const ExtrusionLine &line : current_layer_lines) {
|
||||||
if (line.curled_up_height > 0.3f) {
|
if (line.curled_up_height > params.curling_tolerance_limit) {
|
||||||
l->malformed_lines.push_back(Line{Point::new_scale(line.a), Point::new_scale(line.b)});
|
l->malformed_lines.push_back(Line{Point::new_scale(line.a), Point::new_scale(line.b)});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG_FILES
|
#ifdef DEBUG_FILES
|
||||||
for (const ExtrusionLine &line : current_layer_lines) {
|
for (const ExtrusionLine &line : current_layer_lines) {
|
||||||
if (line.curled_up_height > 0.3f) {
|
if (line.curled_up_height > params.curling_tolerance_limit) {
|
||||||
Vec3f color = value_to_rgbf(-EPSILON, l->height * params.max_curled_height_factor, line.curled_up_height);
|
Vec3f color = value_to_rgbf(-EPSILON, l->height * params.max_curled_height_factor, line.curled_up_height);
|
||||||
fprintf(debug_file, "v %f %f %f %f %f %f\n", line.b[0], line.b[1], l->print_z, color[0], color[1], color[2]);
|
fprintf(debug_file, "v %f %f %f %f %f %f\n", line.b[0], line.b[1], l->print_z, color[0], color[1], color[2]);
|
||||||
}
|
}
|
||||||
@ -1182,7 +1185,8 @@ std::vector<std::pair<SupportPointCause, bool>> gather_issues(const SupportPoint
|
|||||||
std::sort(partial_objects.begin(), partial_objects.end(),
|
std::sort(partial_objects.begin(), partial_objects.end(),
|
||||||
[](const PartialObject &left, const PartialObject &right) { return left.volume > right.volume; });
|
[](const PartialObject &left, const PartialObject &right) { return left.volume > right.volume; });
|
||||||
|
|
||||||
float max_volume_part = partial_objects.front().volume;
|
// Object may have zero extrusions and thus no partial objects. (e.g. very tiny object)
|
||||||
|
float max_volume_part = partial_objects.empty() ? 0.0f : partial_objects.front().volume;
|
||||||
for (const PartialObject &p : partial_objects) {
|
for (const PartialObject &p : partial_objects) {
|
||||||
if (p.volume > max_volume_part / 200.0f && !p.connected_to_bed) {
|
if (p.volume > max_volume_part / 200.0f && !p.connected_to_bed) {
|
||||||
result.emplace_back(SupportPointCause::UnstableFloatingPart, true);
|
result.emplace_back(SupportPointCause::UnstableFloatingPart, true);
|
||||||
|
@ -44,6 +44,7 @@ struct Params
|
|||||||
|
|
||||||
const std::pair<float,float> malformation_distance_factors = std::pair<float, float> { 0.5, 1.1 };
|
const std::pair<float,float> malformation_distance_factors = std::pair<float, float> { 0.5, 1.1 };
|
||||||
const float max_curled_height_factor = 10.0f;
|
const float max_curled_height_factor = 10.0f;
|
||||||
|
const float curling_tolerance_limit = 0.1f;
|
||||||
|
|
||||||
const float min_distance_between_support_points = 3.0f; //mm
|
const float min_distance_between_support_points = 3.0f; //mm
|
||||||
const float support_points_interface_radius = 1.5f; // mm
|
const float support_points_interface_radius = 1.5f; // mm
|
||||||
|
@ -191,6 +191,26 @@ std::optional<std::string> get_current_thread_name()
|
|||||||
|
|
||||||
#endif // _WIN32
|
#endif // _WIN32
|
||||||
|
|
||||||
|
// To be called at the start of the application to save the current thread ID as the main (UI) thread ID.
|
||||||
|
static boost::thread::id g_main_thread_id;
|
||||||
|
|
||||||
|
void save_main_thread_id()
|
||||||
|
{
|
||||||
|
g_main_thread_id = boost::this_thread::get_id();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Retrieve the cached main (UI) thread ID.
|
||||||
|
boost::thread::id get_main_thread_id()
|
||||||
|
{
|
||||||
|
return g_main_thread_id;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Checks whether the main (UI) thread is active.
|
||||||
|
bool is_main_thread_active()
|
||||||
|
{
|
||||||
|
return get_main_thread_id() == boost::this_thread::get_id();
|
||||||
|
}
|
||||||
|
|
||||||
// Spawn (n - 1) worker threads on Intel TBB thread pool and name them by an index and a system thread ID.
|
// Spawn (n - 1) worker threads on Intel TBB thread pool and name them by an index and a system thread ID.
|
||||||
// Also it sets locale of the worker threads to "C" for the G-code generator to produce "." as a decimal separator.
|
// Also it sets locale of the worker threads to "C" for the G-code generator to produce "." as a decimal separator.
|
||||||
void name_tbb_thread_pool_threads_set_locale()
|
void name_tbb_thread_pool_threads_set_locale()
|
||||||
|
@ -29,6 +29,13 @@ inline bool set_thread_name(boost::thread &thread, const std::string &thread_nam
|
|||||||
bool set_current_thread_name(const char *thread_name);
|
bool set_current_thread_name(const char *thread_name);
|
||||||
inline bool set_current_thread_name(const std::string &thread_name) { return set_current_thread_name(thread_name.c_str()); }
|
inline bool set_current_thread_name(const std::string &thread_name) { return set_current_thread_name(thread_name.c_str()); }
|
||||||
|
|
||||||
|
// To be called at the start of the application to save the current thread ID as the main (UI) thread ID.
|
||||||
|
void save_main_thread_id();
|
||||||
|
// Retrieve the cached main (UI) thread ID.
|
||||||
|
boost::thread::id get_main_thread_id();
|
||||||
|
// Checks whether the main (UI) thread is active.
|
||||||
|
bool is_main_thread_active();
|
||||||
|
|
||||||
// OSX specific: Set Quality of Service to "user initiated", so that the threads will be scheduled to high performance
|
// OSX specific: Set Quality of Service to "user initiated", so that the threads will be scheduled to high performance
|
||||||
// cores if available.
|
// cores if available.
|
||||||
void set_current_thread_qos();
|
void set_current_thread_qos();
|
||||||
|
@ -42,7 +42,7 @@ TreeSupportMeshGroupSettings::TreeSupportMeshGroupSettings(const PrintObject &pr
|
|||||||
// const std::vector<unsigned int> printing_extruders = print_object.object_extruders();
|
// const std::vector<unsigned int> printing_extruders = print_object.object_extruders();
|
||||||
|
|
||||||
// Support must be enabled and set to Tree style.
|
// Support must be enabled and set to Tree style.
|
||||||
assert(config.support_material);
|
assert(config.support_material || config.support_material_enforce_layers > 0);
|
||||||
assert(config.support_material_style == smsTree || config.support_material_style == smsOrganic);
|
assert(config.support_material_style == smsTree || config.support_material_style == smsOrganic);
|
||||||
|
|
||||||
// Calculate maximum external perimeter width over all printing regions, taking into account the default layer height.
|
// Calculate maximum external perimeter width over all printing regions, taking into account the default layer height.
|
||||||
@ -505,7 +505,7 @@ void TreeModelVolumes::calculateCollision(const coord_t radius, const LayerIndex
|
|||||||
// 1) Calculate offsets of collision areas in parallel.
|
// 1) Calculate offsets of collision areas in parallel.
|
||||||
std::vector<Polygons> collision_areas_offsetted(max_required_layer + 1 - min_layer_bottom);
|
std::vector<Polygons> collision_areas_offsetted(max_required_layer + 1 - min_layer_bottom);
|
||||||
tbb::parallel_for(tbb::blocked_range<LayerIndex>(min_layer_bottom, max_required_layer + 1),
|
tbb::parallel_for(tbb::blocked_range<LayerIndex>(min_layer_bottom, max_required_layer + 1),
|
||||||
[&outlines, &machine_border = m_machine_border, offset_value = radius + xy_distance, min_layer_bottom, &collision_areas_offsetted, &throw_on_cancel]
|
[&outlines, &machine_border = std::as_const(m_machine_border), offset_value = radius + xy_distance, min_layer_bottom, &collision_areas_offsetted, &throw_on_cancel]
|
||||||
(const tbb::blocked_range<LayerIndex> &range) {
|
(const tbb::blocked_range<LayerIndex> &range) {
|
||||||
for (LayerIndex layer_idx = range.begin(); layer_idx != range.end(); ++ layer_idx) {
|
for (LayerIndex layer_idx = range.begin(); layer_idx != range.end(); ++ layer_idx) {
|
||||||
Polygons collision_areas = machine_border;
|
Polygons collision_areas = machine_border;
|
||||||
@ -520,14 +520,54 @@ void TreeModelVolumes::calculateCollision(const coord_t radius, const LayerIndex
|
|||||||
// 2) Sum over top / bottom ranges.
|
// 2) Sum over top / bottom ranges.
|
||||||
const bool last = outline_idx == layer_outline_indices.size();
|
const bool last = outline_idx == layer_outline_indices.size();
|
||||||
tbb::parallel_for(tbb::blocked_range<LayerIndex>(min_layer_last + 1, max_layer_idx + 1),
|
tbb::parallel_for(tbb::blocked_range<LayerIndex>(min_layer_last + 1, max_layer_idx + 1),
|
||||||
[&collision_areas_offsetted, &anti_overhang = m_anti_overhang, min_layer_bottom, radius, z_distance_bottom_layers, z_distance_top_layers, min_resolution = m_min_resolution, &data, min_layer_last, last, &throw_on_cancel]
|
[&collision_areas_offsetted, &outlines, &machine_border = m_machine_border, &anti_overhang = m_anti_overhang, min_layer_bottom, radius,
|
||||||
|
xy_distance, z_distance_bottom_layers, z_distance_top_layers, min_resolution = m_min_resolution, &data, min_layer_last, last, &throw_on_cancel]
|
||||||
(const tbb::blocked_range<LayerIndex>& range) {
|
(const tbb::blocked_range<LayerIndex>& range) {
|
||||||
for (LayerIndex layer_idx = range.begin(); layer_idx != range.end(); ++layer_idx) {
|
for (LayerIndex layer_idx = range.begin(); layer_idx != range.end(); ++layer_idx) {
|
||||||
Polygons collisions;
|
Polygons collisions;
|
||||||
for (int i = -z_distance_bottom_layers; i <= z_distance_top_layers; ++ i) {
|
for (int i = -z_distance_bottom_layers; i <= z_distance_top_layers; ++ i) {
|
||||||
int j = layer_idx + i - min_layer_bottom;
|
int j = layer_idx + i - min_layer_bottom;
|
||||||
if (j >= 0 && j < int(collision_areas_offsetted.size()))
|
if (j >= 0 && j < int(collision_areas_offsetted.size()) && i <= 0)
|
||||||
append(collisions, collision_areas_offsetted[j]);
|
append(collisions, collision_areas_offsetted[j]);
|
||||||
|
else if (j >= 0 && layer_idx + i < int(outlines.size()) && i > 0) {
|
||||||
|
Polygons collision_areas_original = machine_border;
|
||||||
|
append(collision_areas_original, outlines[layer_idx + i]);
|
||||||
|
|
||||||
|
// If just the collision (including the xy distance) of the layers above is accumulated, it leads to the
|
||||||
|
// following issue:
|
||||||
|
// Example: assuming the z distance is 2 layer
|
||||||
|
// + = xy_distance
|
||||||
|
// - = model
|
||||||
|
// o = overhang of the area two layers above that should result in tips on this layer
|
||||||
|
//
|
||||||
|
// +-----+
|
||||||
|
// +-----+
|
||||||
|
// +-----+
|
||||||
|
// o +-----+
|
||||||
|
// If just the collision above is accumulated the overhang will get overwritten by the xy_distance of the
|
||||||
|
// layer below the overhang...
|
||||||
|
//
|
||||||
|
// This only causes issues if the overhang area is thinner than xy_distance
|
||||||
|
// Just accumulating areas of the model above without the xy distance is also problematic, as then support
|
||||||
|
// may get closer to the model (on the diagonal downwards) than the user intended. Example (s = support):
|
||||||
|
// +-----+
|
||||||
|
// +-----+
|
||||||
|
// +-----+
|
||||||
|
// s+-----+
|
||||||
|
|
||||||
|
// technically the calculation below is off by one layer, as the actual distance between plastic one layer
|
||||||
|
// down is 0 not layer height, as this layer is filled with said plastic. But otherwise a part of the
|
||||||
|
// overhang that is expected to be supported is overwritten by the remaining part of the xy distance of the
|
||||||
|
// layer below the to be supported area.
|
||||||
|
coord_t required_range_x =
|
||||||
|
(xy_distance - ((i - (z_distance_top_layers == 1 ? 0.5 : 0)) * xy_distance / z_distance_top_layers));
|
||||||
|
// the conditional -0.5 ensures that plastic can never touch on the diagonal
|
||||||
|
// downward when the z_distance_top_layers = 1. It is assumed to be better to
|
||||||
|
// not support an overhang<90 degree than to risk fusing to it.
|
||||||
|
|
||||||
|
collision_areas_original = offset(union_ex(collision_areas_original), radius + required_range_x, ClipperLib::jtMiter, 1.2);
|
||||||
|
append(collisions, collision_areas_original);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
collisions = last && layer_idx < int(anti_overhang.size()) ? union_(collisions, offset(union_ex(anti_overhang[layer_idx]), radius, ClipperLib::jtMiter, 1.2)) : union_(collisions);
|
collisions = last && layer_idx < int(anti_overhang.size()) ? union_(collisions, offset(union_ex(anti_overhang[layer_idx]), radius, ClipperLib::jtMiter, 1.2)) : union_(collisions);
|
||||||
auto &dst = data[layer_idx - (min_layer_last + 1)];
|
auto &dst = data[layer_idx - (min_layer_last + 1)];
|
||||||
@ -644,7 +684,8 @@ void TreeModelVolumes::calculateAvoidance(const std::vector<RadiusLayerPair> &ke
|
|||||||
BOOST_LOG_TRIVIAL(debug) << "Calculation requested for value already calculated?";
|
BOOST_LOG_TRIVIAL(debug) << "Calculation requested for value already calculated?";
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (! task.holefree() || task.radius < m_increase_until_radius + m_current_min_xy_dist_delta)
|
if ((task.to_model ? to_model : to_build_plate) &&
|
||||||
|
(! task.holefree() || task.radius < m_increase_until_radius + m_current_min_xy_dist_delta))
|
||||||
avoidance_tasks.emplace_back(task);
|
avoidance_tasks.emplace_back(task);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -154,7 +154,7 @@ static std::vector<std::pair<TreeSupportSettings, std::vector<size_t>>> group_me
|
|||||||
const PrintObjectConfig &object_config = print_object.config();
|
const PrintObjectConfig &object_config = print_object.config();
|
||||||
#endif // NDEBUG
|
#endif // NDEBUG
|
||||||
// Support must be enabled and set to Tree style.
|
// Support must be enabled and set to Tree style.
|
||||||
assert(object_config.support_material);
|
assert(object_config.support_material || object_config.support_material_enforce_layers > 0);
|
||||||
assert(object_config.support_material_style == smsTree || object_config.support_material_style == smsOrganic);
|
assert(object_config.support_material_style == smsTree || object_config.support_material_style == smsOrganic);
|
||||||
|
|
||||||
bool found_existing_group = false;
|
bool found_existing_group = false;
|
||||||
@ -226,8 +226,9 @@ void tree_supports_show_error(std::string_view message, bool critical)
|
|||||||
{
|
{
|
||||||
std::vector<Polygons> out(print_object.layer_count(), Polygons{});
|
std::vector<Polygons> out(print_object.layer_count(), Polygons{});
|
||||||
|
|
||||||
|
const PrintConfig &print_config = print_object.print()->config();
|
||||||
const PrintObjectConfig &config = print_object.config();
|
const PrintObjectConfig &config = print_object.config();
|
||||||
const bool support_auto = config.support_material_auto.value;
|
const bool support_auto = config.support_material.value && config.support_material_auto.value;
|
||||||
const int support_enforce_layers = config.support_material_enforce_layers.value;
|
const int support_enforce_layers = config.support_material_enforce_layers.value;
|
||||||
std::vector<Polygons> enforcers_layers{ print_object.slice_support_enforcers() };
|
std::vector<Polygons> enforcers_layers{ print_object.slice_support_enforcers() };
|
||||||
std::vector<Polygons> blockers_layers{ print_object.slice_support_blockers() };
|
std::vector<Polygons> blockers_layers{ print_object.slice_support_blockers() };
|
||||||
@ -240,8 +241,10 @@ void tree_supports_show_error(std::string_view message, bool critical)
|
|||||||
//FIXME this is a fudge constant!
|
//FIXME this is a fudge constant!
|
||||||
auto enforcer_overhang_offset = scaled<double>(config.support_tree_tip_diameter.value);
|
auto enforcer_overhang_offset = scaled<double>(config.support_tree_tip_diameter.value);
|
||||||
|
|
||||||
tbb::parallel_for(tbb::blocked_range<LayerIndex>(1, out.size()),
|
size_t num_overhang_layers = support_auto ? out.size() : std::max(size_t(support_enforce_layers), enforcers_layers.size());
|
||||||
[&print_object, &enforcers_layers, &blockers_layers, support_auto, support_enforce_layers, support_threshold_auto, tan_threshold, enforcer_overhang_offset, &throw_on_cancel, &out]
|
tbb::parallel_for(tbb::blocked_range<LayerIndex>(1, num_overhang_layers),
|
||||||
|
[&print_object, &config, &print_config, &enforcers_layers, &blockers_layers,
|
||||||
|
support_auto, support_enforce_layers, support_threshold_auto, tan_threshold, enforcer_overhang_offset, &throw_on_cancel, &out]
|
||||||
(const tbb::blocked_range<LayerIndex> &range) {
|
(const tbb::blocked_range<LayerIndex> &range) {
|
||||||
for (LayerIndex layer_id = range.begin(); layer_id < range.end(); ++ layer_id) {
|
for (LayerIndex layer_id = range.begin(); layer_id < range.end(); ++ layer_id) {
|
||||||
const Layer ¤t_layer = *print_object.get_layer(layer_id);
|
const Layer ¤t_layer = *print_object.get_layer(layer_id);
|
||||||
@ -274,6 +277,11 @@ void tree_supports_show_error(std::string_view message, bool critical)
|
|||||||
}
|
}
|
||||||
if (! (enforced_layer || blockers_layers.empty() || blockers_layers[layer_id].empty()))
|
if (! (enforced_layer || blockers_layers.empty() || blockers_layers[layer_id].empty()))
|
||||||
overhangs = diff(overhangs, blockers_layers[layer_id], ApplySafetyOffset::Yes);
|
overhangs = diff(overhangs, blockers_layers[layer_id], ApplySafetyOffset::Yes);
|
||||||
|
if (config.dont_support_bridges) {
|
||||||
|
for (const LayerRegion *layerm : current_layer.regions())
|
||||||
|
remove_bridges_from_contacts(print_config, lower_layer, *layerm,
|
||||||
|
float(layerm->flow(frExternalPerimeter).scaled_width()), overhangs);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
//check_self_intersections(overhangs, "generate_overhangs1");
|
//check_self_intersections(overhangs, "generate_overhangs1");
|
||||||
if (! enforcers_layers.empty() && ! enforcers_layers[layer_id].empty()) {
|
if (! enforcers_layers.empty() && ! enforcers_layers[layer_id].empty()) {
|
||||||
@ -488,15 +496,15 @@ static std::optional<std::pair<Point, size_t>> polyline_sample_next_point_at_dis
|
|||||||
Vec2d xf = p0f - foot_pt;
|
Vec2d xf = p0f - foot_pt;
|
||||||
// Squared distance of "start_pt" from the ray (p0, p1).
|
// Squared distance of "start_pt" from the ray (p0, p1).
|
||||||
double l2_from_line = xf.squaredNorm();
|
double l2_from_line = xf.squaredNorm();
|
||||||
double det = dist2 - l2_from_line;
|
// Squared distance of an intersection point of a circle with center at the foot point.
|
||||||
|
if (double l2_intersection = dist2 - l2_from_line;
|
||||||
if (det > - SCALED_EPSILON) {
|
l2_intersection > - SCALED_EPSILON) {
|
||||||
// The ray (p0, p1) touches or intersects a circle centered at "start_pt" with radius "dist".
|
// The ray (p0, p1) touches or intersects a circle centered at "start_pt" with radius "dist".
|
||||||
// Distance of the circle intersection point from the foot point.
|
// Distance of the circle intersection point from the foot point.
|
||||||
double dist_circle_intersection = std::sqrt(std::max(0., det));
|
l2_intersection = std::max(l2_intersection, 0.);
|
||||||
if ((v - foot_pt).cast<double>().norm() > dist_circle_intersection) {
|
if ((v - foot_pt).cast<double>().squaredNorm() >= l2_intersection) {
|
||||||
// Intersection of the circle with the segment (p0, p1) is on the right side (close to p1) from the foot point.
|
// Intersection of the circle with the segment (p0, p1) is on the right side (close to p1) from the foot point.
|
||||||
Point p = p0 + (foot_pt + v * (dist_circle_intersection / sqrt(l2v))).cast<coord_t>();
|
Point p = p0 + (foot_pt + v * sqrt(l2_intersection / l2v)).cast<coord_t>();
|
||||||
validate_range(p);
|
validate_range(p);
|
||||||
return std::pair<Point, size_t>{ p, i - 1 };
|
return std::pair<Point, size_t>{ p, i - 1 };
|
||||||
}
|
}
|
||||||
@ -908,7 +916,7 @@ static void generate_initial_areas(
|
|||||||
//FIXME Vojtech: This is not sufficient for support enforcers to work.
|
//FIXME Vojtech: This is not sufficient for support enforcers to work.
|
||||||
//FIXME There is no account for the support overhang angle.
|
//FIXME There is no account for the support overhang angle.
|
||||||
//FIXME There is no account for the width of the collision regions.
|
//FIXME There is no account for the width of the collision regions.
|
||||||
const coord_t extra_outset = std::max(coord_t(0), mesh_config.min_radius - mesh_config.support_line_width) + (min_xy_dist ? mesh_config.support_line_width / 2 : 0)
|
const coord_t extra_outset = std::max(coord_t(0), mesh_config.min_radius - mesh_config.support_line_width / 2) + (min_xy_dist ? mesh_config.support_line_width / 2 : 0)
|
||||||
//FIXME this is a heuristic value for support enforcers to work.
|
//FIXME this is a heuristic value for support enforcers to work.
|
||||||
// + 10 * mesh_config.support_line_width;
|
// + 10 * mesh_config.support_line_width;
|
||||||
;
|
;
|
||||||
@ -923,7 +931,9 @@ static void generate_initial_areas(
|
|||||||
// does not turn valid in double the amount of layers a slope of support angle would take to travel xy_distance, nothing reasonable will come from it.
|
// does not turn valid in double the amount of layers a slope of support angle would take to travel xy_distance, nothing reasonable will come from it.
|
||||||
// The 2*z_distance_delta is only a catch for when the support angle is very high.
|
// The 2*z_distance_delta is only a catch for when the support angle is very high.
|
||||||
// Used only if not min_xy_dist.
|
// Used only if not min_xy_dist.
|
||||||
const coord_t max_overhang_insert_lag = std::max<coord_t>(round_up_divide(mesh_config.xy_distance, max_overhang_speed / 2), 2 * mesh_config.z_distance_top_layers);
|
const coord_t max_overhang_insert_lag = mesh_config.z_distance_top_layers > 0 ?
|
||||||
|
std::max<coord_t>(round_up_divide(mesh_config.xy_distance, max_overhang_speed / 2), 2 * mesh_config.z_distance_top_layers) :
|
||||||
|
0;
|
||||||
|
|
||||||
//FIXME
|
//FIXME
|
||||||
size_t num_support_layers = print_object.layer_count();
|
size_t num_support_layers = print_object.layer_count();
|
||||||
@ -1069,9 +1079,8 @@ static void generate_initial_areas(
|
|||||||
Polygons overhang_regular;
|
Polygons overhang_regular;
|
||||||
{
|
{
|
||||||
const Polygons &overhang_raw = overhangs[layer_idx + z_distance_delta];
|
const Polygons &overhang_raw = overhangs[layer_idx + z_distance_delta];
|
||||||
overhang_regular = mesh_group_settings.support_offset == 0 ?
|
// When support_offset = 0 safe_offset_inc will only be the difference between overhang_raw and relevant_forbidden, that has to be calculated anyway.
|
||||||
overhang_raw :
|
overhang_regular = safe_offset_inc(overhang_raw, mesh_group_settings.support_offset, relevant_forbidden, mesh_config.min_radius * 1.75 + mesh_config.xy_min_distance, 0, 1);
|
||||||
safe_offset_inc(overhang_raw, mesh_group_settings.support_offset, relevant_forbidden, mesh_config.min_radius * 1.75 + mesh_config.xy_min_distance, 0, 1);
|
|
||||||
//check_self_intersections(overhang_regular, "overhang_regular1");
|
//check_self_intersections(overhang_regular, "overhang_regular1");
|
||||||
|
|
||||||
// offset ensures that areas that could be supported by a part of a support line, are not considered unsupported overhang
|
// offset ensures that areas that could be supported by a part of a support line, are not considered unsupported overhang
|
||||||
@ -2497,8 +2506,10 @@ static void create_nodes_from_area(
|
|||||||
// Point is chosen based on an inaccurate estimate where the branches will split into two, but every point inside the influence area would produce a valid result.
|
// Point is chosen based on an inaccurate estimate where the branches will split into two, but every point inside the influence area would produce a valid result.
|
||||||
{
|
{
|
||||||
SupportElements *layer_above = move_bounds.size() > 1 ? &move_bounds[1] : nullptr;
|
SupportElements *layer_above = move_bounds.size() > 1 ? &move_bounds[1] : nullptr;
|
||||||
for (SupportElement &elem : *layer_above)
|
if (layer_above) {
|
||||||
elem.state.marked = false;
|
for (SupportElement &elem : *layer_above)
|
||||||
|
elem.state.marked = false;
|
||||||
|
}
|
||||||
for (SupportElement &init : move_bounds.front()) {
|
for (SupportElement &init : move_bounds.front()) {
|
||||||
init.state.result_on_layer = move_inside_if_outside(init.influence_area, init.state.next_position);
|
init.state.result_on_layer = move_inside_if_outside(init.influence_area, init.state.next_position);
|
||||||
// Also set the parent nodes, as these will be required for the first iteration of the loop below and mark the parent nodes.
|
// Also set the parent nodes, as these will be required for the first iteration of the loop below and mark the parent nodes.
|
||||||
@ -2931,7 +2942,11 @@ static void finalize_interface_and_support_areas(
|
|||||||
|
|
||||||
std::function<void()> throw_on_cancel)
|
std::function<void()> throw_on_cancel)
|
||||||
{
|
{
|
||||||
InterfacePreference interface_pref = config.interface_preference; // InterfacePreference::SupportLinesOverwriteInterface;
|
assert(std::all_of(bottom_contacts.begin(), bottom_contacts.end(), [](auto *p) { return p == nullptr; }));
|
||||||
|
// assert(std::all_of(top_contacts.begin(), top_contacts.end(), [](auto* p) { return p == nullptr; }));
|
||||||
|
assert(std::all_of(intermediate_layers.begin(), intermediate_layers.end(), [](auto* p) { return p == nullptr; }));
|
||||||
|
|
||||||
|
InterfacePreference interface_pref = config.interface_preference; // InterfacePreference::InterfaceAreaOverwritesSupport;
|
||||||
|
|
||||||
#ifdef SLIC3R_TREESUPPORTS_PROGRESS
|
#ifdef SLIC3R_TREESUPPORTS_PROGRESS
|
||||||
double progress_total = TREE_PROGRESS_PRECALC_AVO + TREE_PROGRESS_PRECALC_COLL + TREE_PROGRESS_GENERATE_NODES + TREE_PROGRESS_AREA_CALC + TREE_PROGRESS_GENERATE_BRANCH_AREAS + TREE_PROGRESS_SMOOTH_BRANCH_AREAS;
|
double progress_total = TREE_PROGRESS_PRECALC_AVO + TREE_PROGRESS_PRECALC_COLL + TREE_PROGRESS_GENERATE_NODES + TREE_PROGRESS_AREA_CALC + TREE_PROGRESS_GENERATE_BRANCH_AREAS + TREE_PROGRESS_SMOOTH_BRANCH_AREAS;
|
||||||
@ -2942,29 +2957,41 @@ static void finalize_interface_and_support_areas(
|
|||||||
tbb::parallel_for(tbb::blocked_range<size_t>(0, support_layer_storage.size()),
|
tbb::parallel_for(tbb::blocked_range<size_t>(0, support_layer_storage.size()),
|
||||||
[&](const tbb::blocked_range<size_t> &range) {
|
[&](const tbb::blocked_range<size_t> &range) {
|
||||||
for (size_t layer_idx = range.begin(); layer_idx < range.end(); ++ layer_idx) {
|
for (size_t layer_idx = range.begin(); layer_idx < range.end(); ++ layer_idx) {
|
||||||
// Most of the time in this function is this union call. Can take 300+ ms when a lot of areas are to be unioned.
|
|
||||||
support_layer_storage[layer_idx] = smooth_outward(union_(support_layer_storage[layer_idx]), config.support_line_width); //FIXME was .smooth(50);
|
|
||||||
//smooth_outward(closing(std::move(bottom), closing_distance + minimum_island_radius, closing_distance, SUPPORT_SURFACES_OFFSET_PARAMETERS), smoothing_distance) :
|
|
||||||
|
|
||||||
// simplify a bit, to ensure the output does not contain outrageous amounts of vertices. Should not be necessary, just a precaution.
|
|
||||||
support_layer_storage[layer_idx] = polygons_simplify(support_layer_storage[layer_idx], std::min(scaled<double>(0.03), double(config.resolution)));
|
|
||||||
// Subtract support lines of the branches from the roof
|
// Subtract support lines of the branches from the roof
|
||||||
SupportGeneratorLayer*& support_roof = top_contacts[layer_idx];
|
SupportGeneratorLayer *support_roof = top_contacts[layer_idx];
|
||||||
if (! support_roof_storage[layer_idx].empty() || support_roof != nullptr) {
|
Polygons support_roof_polygons;
|
||||||
if (support_roof == nullptr) {
|
|
||||||
support_roof = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::TopContact, print_object.slicing_parameters(), layer_idx);
|
|
||||||
support_roof->polygons = union_(support_roof_storage[layer_idx]);
|
|
||||||
} else
|
|
||||||
support_roof->polygons = union_(support_roof->polygons, support_roof_storage[layer_idx]);
|
|
||||||
|
|
||||||
if (! support_roof->polygons.empty() &&
|
if (Polygons &src = support_roof_storage[layer_idx]; ! src.empty()) {
|
||||||
area(intersection(support_layer_storage[layer_idx], support_roof->polygons)) > tiny_area_threshold) {
|
if (support_roof != nullptr && ! support_roof->polygons.empty()) {
|
||||||
|
support_roof_polygons = union_(src, support_roof->polygons);
|
||||||
|
support_roof->polygons.clear();
|
||||||
|
} else
|
||||||
|
support_roof_polygons = std::move(src);
|
||||||
|
} else if (support_roof != nullptr) {
|
||||||
|
support_roof_polygons = std::move(support_roof->polygons);
|
||||||
|
support_roof->polygons.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(intermediate_layers[layer_idx] == nullptr);
|
||||||
|
Polygons base_layer_polygons = std::move(support_layer_storage[layer_idx]);
|
||||||
|
|
||||||
|
if (! base_layer_polygons.empty()) {
|
||||||
|
// Most of the time in this function is this union call. Can take 300+ ms when a lot of areas are to be unioned.
|
||||||
|
base_layer_polygons = smooth_outward(union_(base_layer_polygons), config.support_line_width); //FIXME was .smooth(50);
|
||||||
|
//smooth_outward(closing(std::move(bottom), closing_distance + minimum_island_radius, closing_distance, SUPPORT_SURFACES_OFFSET_PARAMETERS), smoothing_distance) :
|
||||||
|
// simplify a bit, to ensure the output does not contain outrageous amounts of vertices. Should not be necessary, just a precaution.
|
||||||
|
base_layer_polygons = polygons_simplify(base_layer_polygons, std::min(scaled<double>(0.03), double(config.resolution)));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (! support_roof_polygons.empty() && ! base_layer_polygons.empty()) {
|
||||||
|
// if (area(intersection(base_layer_polygons, support_roof_polygons)) > tiny_area_threshold)
|
||||||
|
{
|
||||||
switch (interface_pref) {
|
switch (interface_pref) {
|
||||||
case InterfacePreference::InterfaceAreaOverwritesSupport:
|
case InterfacePreference::InterfaceAreaOverwritesSupport:
|
||||||
support_layer_storage[layer_idx] = diff(support_layer_storage[layer_idx], support_roof->polygons);
|
base_layer_polygons = diff(base_layer_polygons, support_roof_polygons);
|
||||||
break;
|
break;
|
||||||
case InterfacePreference::SupportAreaOverwritesInterface:
|
case InterfacePreference::SupportAreaOverwritesInterface:
|
||||||
support_roof->polygons = diff(support_roof->polygons, support_layer_storage[layer_idx]);
|
support_roof_polygons = diff(support_roof_polygons, base_layer_polygons);
|
||||||
break;
|
break;
|
||||||
//FIXME
|
//FIXME
|
||||||
#if 1
|
#if 1
|
||||||
@ -2979,14 +3006,14 @@ static void finalize_interface_and_support_areas(
|
|||||||
Polygons interface_lines = offset(to_polylines(
|
Polygons interface_lines = offset(to_polylines(
|
||||||
generate_support_infill_lines(support_roof->polygons, true, layer_idx, config.support_roof_line_distance)),
|
generate_support_infill_lines(support_roof->polygons, true, layer_idx, config.support_roof_line_distance)),
|
||||||
config.support_roof_line_width / 2);
|
config.support_roof_line_width / 2);
|
||||||
support_layer_storage[layer_idx] = diff(support_layer_storage[layer_idx], interface_lines);
|
base_layer_polygons = diff(base_layer_polygons, interface_lines);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case InterfacePreference::SupportLinesOverwriteInterface:
|
case InterfacePreference::SupportLinesOverwriteInterface:
|
||||||
{
|
{
|
||||||
// Hatch the support roof interfaces, offset them by their line width and subtract them from support base.
|
// Hatch the support roof interfaces, offset them by their line width and subtract them from support base.
|
||||||
Polygons tree_lines = union_(offset(to_polylines(
|
Polygons tree_lines = union_(offset(to_polylines(
|
||||||
generate_support_infill_lines(support_layer_storage[layer_idx], false, layer_idx, config.support_line_distance, true)),
|
generate_support_infill_lines(base_layer_polygons, false, layer_idx, config.support_line_distance, true)),
|
||||||
config.support_line_width / 2));
|
config.support_line_width / 2));
|
||||||
// do not draw roof where the tree is. I prefer it this way as otherwise the roof may cut of a branch from its support below.
|
// do not draw roof where the tree is. I prefer it this way as otherwise the roof may cut of a branch from its support below.
|
||||||
support_roof->polygons = diff(support_roof->polygons, tree_lines);
|
support_roof->polygons = diff(support_roof->polygons, tree_lines);
|
||||||
@ -3000,10 +3027,10 @@ static void finalize_interface_and_support_areas(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Subtract support floors from the support area and add them to the support floor instead.
|
// Subtract support floors from the support area and add them to the support floor instead.
|
||||||
if (config.support_bottom_layers > 0 && !support_layer_storage[layer_idx].empty()) {
|
if (config.support_bottom_layers > 0 && ! base_layer_polygons.empty()) {
|
||||||
SupportGeneratorLayer*& support_bottom = bottom_contacts[layer_idx];
|
SupportGeneratorLayer*& support_bottom = bottom_contacts[layer_idx];
|
||||||
Polygons layer_outset = diff_clipped(
|
Polygons layer_outset = diff_clipped(
|
||||||
config.support_bottom_offset > 0 ? offset(support_layer_storage[layer_idx], config.support_bottom_offset, jtMiter, 1.2) : support_layer_storage[layer_idx],
|
config.support_bottom_offset > 0 ? offset(base_layer_polygons, config.support_bottom_offset, jtMiter, 1.2) : base_layer_polygons,
|
||||||
volumes.getCollision(0, layer_idx, false));
|
volumes.getCollision(0, layer_idx, false));
|
||||||
Polygons floor_layer;
|
Polygons floor_layer;
|
||||||
size_t layers_below = 0;
|
size_t layers_below = 0;
|
||||||
@ -3021,15 +3048,18 @@ static void finalize_interface_and_support_areas(
|
|||||||
if (support_bottom == nullptr)
|
if (support_bottom == nullptr)
|
||||||
support_bottom = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::BottomContact, print_object.slicing_parameters(), layer_idx);
|
support_bottom = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::BottomContact, print_object.slicing_parameters(), layer_idx);
|
||||||
support_bottom->polygons = union_(floor_layer, support_bottom->polygons);
|
support_bottom->polygons = union_(floor_layer, support_bottom->polygons);
|
||||||
support_layer_storage[layer_idx] = diff_clipped(support_layer_storage[layer_idx], offset(support_bottom->polygons, scaled<float>(0.01), jtMiter, 1.2)); // Subtract the support floor from the normal support.
|
base_layer_polygons = diff_clipped(base_layer_polygons, offset(support_bottom->polygons, scaled<float>(0.01), jtMiter, 1.2)); // Subtract the support floor from the normal support.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! support_layer_storage[layer_idx].empty()) {
|
if (! support_roof_polygons.empty()) {
|
||||||
SupportGeneratorLayer *&l = intermediate_layers[layer_idx];
|
if (support_roof == nullptr)
|
||||||
if (l == nullptr)
|
support_roof = top_contacts[layer_idx] = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::TopContact, print_object.slicing_parameters(), layer_idx);
|
||||||
l = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::Base, print_object.slicing_parameters(), layer_idx);
|
support_roof->polygons = union_(support_roof_polygons);
|
||||||
append(l->polygons, union_(support_layer_storage[layer_idx]));
|
}
|
||||||
|
if (! base_layer_polygons.empty()) {
|
||||||
|
SupportGeneratorLayer *base_layer = intermediate_layers[layer_idx] = &layer_allocate(layer_storage, layer_storage_mutex, SupporLayerType::Base, print_object.slicing_parameters(), layer_idx);
|
||||||
|
base_layer->polygons = union_(base_layer_polygons);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef SLIC3R_TREESUPPORTS_PROGRESS
|
#ifdef SLIC3R_TREESUPPORTS_PROGRESS
|
||||||
@ -3913,25 +3943,15 @@ static void slice_branches(
|
|||||||
params.closing_radius = float(print_object.config().slice_closing_radius.value);
|
params.closing_radius = float(print_object.config().slice_closing_radius.value);
|
||||||
params.mode = MeshSlicingParams::SlicingMode::Positive;
|
params.mode = MeshSlicingParams::SlicingMode::Positive;
|
||||||
std::vector<ExPolygons> slices = slice_mesh_ex(cummulative_mesh, slice_z, params, throw_on_cancel);
|
std::vector<ExPolygons> slices = slice_mesh_ex(cummulative_mesh, slice_z, params, throw_on_cancel);
|
||||||
for (size_t layer_idx = 0; layer_idx < slice_z.size(); ++ layer_idx)
|
|
||||||
if (! slices[layer_idx].empty()) {
|
|
||||||
SupportGeneratorLayer *&l = intermediate_layers[layer_idx];
|
|
||||||
if (l == nullptr)
|
|
||||||
l = &layer_allocate(layer_storage, SupporLayerType::Base, slicing_params, layer_idx);
|
|
||||||
append(l->polygons, to_polygons(std::move(slices[layer_idx])));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Trim the slices.
|
// Trim the slices.
|
||||||
tbb::parallel_for(tbb::blocked_range<size_t>(0, intermediate_layers.size()),
|
std::vector<Polygons> support_layer_storage(move_bounds.size());
|
||||||
|
tbb::parallel_for(tbb::blocked_range<size_t>(0, slices.size()),
|
||||||
[&](const tbb::blocked_range<size_t> &range) {
|
[&](const tbb::blocked_range<size_t> &range) {
|
||||||
for (size_t layer_idx = range.begin(); layer_idx < range.end(); ++ layer_idx)
|
for (size_t layer_idx = range.begin(); layer_idx < range.end(); ++layer_idx)
|
||||||
if (SupportGeneratorLayer *layer = intermediate_layers[layer_idx]; layer) {
|
if (ExPolygons &src = slices[layer_idx]; ! src.empty())
|
||||||
Polygons &poly = intermediate_layers[layer_idx]->polygons;
|
support_layer_storage[layer_idx] = diff_clipped(to_polygons(std::move(src)), volumes.getCollision(0, layer_idx, true));
|
||||||
poly = diff_clipped(poly, volumes.getCollision(0, layer_idx, true));
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
std::vector<Polygons> support_layer_storage(move_bounds.size());
|
|
||||||
std::vector<Polygons> support_roof_storage(move_bounds.size());
|
std::vector<Polygons> support_roof_storage(move_bounds.size());
|
||||||
finalize_interface_and_support_areas(print_object, volumes, config, overhangs, support_layer_storage, support_roof_storage,
|
finalize_interface_and_support_areas(print_object, volumes, config, overhangs, support_layer_storage, support_roof_storage,
|
||||||
bottom_contacts, top_contacts, intermediate_layers, layer_storage, throw_on_cancel);
|
bottom_contacts, top_contacts, intermediate_layers, layer_storage, throw_on_cancel);
|
||||||
|
@ -310,7 +310,8 @@ struct TreeSupportSettings
|
|||||||
// interface_preference = interface_map.at(mesh_group_settings.get<std::string>("support_interface_priority"));
|
// interface_preference = interface_map.at(mesh_group_settings.get<std::string>("support_interface_priority"));
|
||||||
//FIXME this was the default
|
//FIXME this was the default
|
||||||
// interface_preference = InterfacePreference::SupportLinesOverwriteInterface;
|
// interface_preference = InterfacePreference::SupportLinesOverwriteInterface;
|
||||||
interface_preference = InterfacePreference::SupportAreaOverwritesInterface;
|
//interface_preference = InterfacePreference::SupportAreaOverwritesInterface;
|
||||||
|
interface_preference = InterfacePreference::InterfaceAreaOverwritesSupport;
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -386,7 +386,9 @@ void GLVolume::render()
|
|||||||
if (shader == nullptr)
|
if (shader == nullptr)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (this->is_left_handed())
|
const bool is_left_handed = this->is_left_handed();
|
||||||
|
|
||||||
|
if (is_left_handed)
|
||||||
glsafe(::glFrontFace(GL_CW));
|
glsafe(::glFrontFace(GL_CW));
|
||||||
glsafe(::glCullFace(GL_BACK));
|
glsafe(::glCullFace(GL_BACK));
|
||||||
|
|
||||||
@ -395,7 +397,7 @@ void GLVolume::render()
|
|||||||
else
|
else
|
||||||
model.render(this->tverts_range);
|
model.render(this->tverts_range);
|
||||||
|
|
||||||
if (this->is_left_handed())
|
if (is_left_handed)
|
||||||
glsafe(::glFrontFace(GL_CCW));
|
glsafe(::glFrontFace(GL_CCW));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -793,6 +795,7 @@ void GLVolumeCollection::render(GLVolumeCollection::ERenderType type, bool disab
|
|||||||
glsafe(::glDisable(GL_CULL_FACE));
|
glsafe(::glDisable(GL_CULL_FACE));
|
||||||
|
|
||||||
for (GLVolumeWithIdAndZ& volume : to_render) {
|
for (GLVolumeWithIdAndZ& volume : to_render) {
|
||||||
|
const Transform3d& world_matrix = volume.first->world_matrix();
|
||||||
volume.first->set_render_color(true);
|
volume.first->set_render_color(true);
|
||||||
|
|
||||||
// render sinking contours of non-hovered volumes
|
// render sinking contours of non-hovered volumes
|
||||||
@ -811,17 +814,21 @@ void GLVolumeCollection::render(GLVolumeCollection::ERenderType type, bool disab
|
|||||||
|
|
||||||
shader->set_uniform("z_range", m_z_range);
|
shader->set_uniform("z_range", m_z_range);
|
||||||
shader->set_uniform("clipping_plane", m_clipping_plane);
|
shader->set_uniform("clipping_plane", m_clipping_plane);
|
||||||
|
shader->set_uniform("use_color_clip_plane", m_use_color_clip_plane);
|
||||||
|
shader->set_uniform("color_clip_plane", m_color_clip_plane);
|
||||||
|
shader->set_uniform("uniform_color_clip_plane_1", m_color_clip_plane_colors[0]);
|
||||||
|
shader->set_uniform("uniform_color_clip_plane_2", m_color_clip_plane_colors[1]);
|
||||||
shader->set_uniform("print_volume.type", static_cast<int>(m_print_volume.type));
|
shader->set_uniform("print_volume.type", static_cast<int>(m_print_volume.type));
|
||||||
shader->set_uniform("print_volume.xy_data", m_print_volume.data);
|
shader->set_uniform("print_volume.xy_data", m_print_volume.data);
|
||||||
shader->set_uniform("print_volume.z_data", m_print_volume.zs);
|
shader->set_uniform("print_volume.z_data", m_print_volume.zs);
|
||||||
shader->set_uniform("volume_world_matrix", volume.first->world_matrix());
|
shader->set_uniform("volume_world_matrix", world_matrix);
|
||||||
shader->set_uniform("slope.actived", m_slope.active && !volume.first->is_modifier && !volume.first->is_wipe_tower);
|
shader->set_uniform("slope.actived", m_slope.active && !volume.first->is_modifier && !volume.first->is_wipe_tower);
|
||||||
shader->set_uniform("slope.volume_world_normal_matrix", static_cast<Matrix3f>(volume.first->world_matrix().matrix().block(0, 0, 3, 3).inverse().transpose().cast<float>()));
|
shader->set_uniform("slope.volume_world_normal_matrix", static_cast<Matrix3f>(world_matrix.matrix().block(0, 0, 3, 3).inverse().transpose().cast<float>()));
|
||||||
shader->set_uniform("slope.normal_z", m_slope.normal_z);
|
shader->set_uniform("slope.normal_z", m_slope.normal_z);
|
||||||
|
|
||||||
#if ENABLE_ENVIRONMENT_MAP
|
#if ENABLE_ENVIRONMENT_MAP
|
||||||
unsigned int environment_texture_id = GUI::wxGetApp().plater()->get_environment_texture_id();
|
unsigned int environment_texture_id = GUI::wxGetApp().plater()->get_environment_texture_id();
|
||||||
bool use_environment_texture = environment_texture_id > 0 && GUI::wxGetApp().app_config->get("use_environment_map") == "1";
|
bool use_environment_texture = environment_texture_id > 0 && GUI::wxGetApp().app_config->get_bool("use_environment_map");
|
||||||
shader->set_uniform("use_environment_tex", use_environment_texture);
|
shader->set_uniform("use_environment_tex", use_environment_texture);
|
||||||
if (use_environment_texture)
|
if (use_environment_texture)
|
||||||
glsafe(::glBindTexture(GL_TEXTURE_2D, environment_texture_id));
|
glsafe(::glBindTexture(GL_TEXTURE_2D, environment_texture_id));
|
||||||
@ -829,7 +836,7 @@ void GLVolumeCollection::render(GLVolumeCollection::ERenderType type, bool disab
|
|||||||
glcheck();
|
glcheck();
|
||||||
|
|
||||||
volume.first->model.set_color(volume.first->render_color);
|
volume.first->model.set_color(volume.first->render_color);
|
||||||
const Transform3d model_matrix = volume.first->world_matrix();
|
const Transform3d model_matrix = world_matrix;
|
||||||
shader->set_uniform("view_model_matrix", view_matrix * model_matrix);
|
shader->set_uniform("view_model_matrix", view_matrix * model_matrix);
|
||||||
shader->set_uniform("projection_matrix", projection_matrix);
|
shader->set_uniform("projection_matrix", projection_matrix);
|
||||||
const Matrix3d view_normal_matrix = view_matrix.matrix().block(0, 0, 3, 3) * model_matrix.matrix().block(0, 0, 3, 3).inverse().transpose();
|
const Matrix3d view_normal_matrix = view_matrix.matrix().block(0, 0, 3, 3) * model_matrix.matrix().block(0, 0, 3, 3).inverse().transpose();
|
||||||
@ -866,7 +873,7 @@ void GLVolumeCollection::render(GLVolumeCollection::ERenderType type, bool disab
|
|||||||
shader->stop_using();
|
shader->stop_using();
|
||||||
if (edges_shader != nullptr) {
|
if (edges_shader != nullptr) {
|
||||||
edges_shader->start_using();
|
edges_shader->start_using();
|
||||||
if (m_show_non_manifold_edges && GUI::wxGetApp().app_config->get("non_manifold_edges") == "1") {
|
if (m_show_non_manifold_edges && GUI::wxGetApp().app_config->get_bool("non_manifold_edges")) {
|
||||||
for (GLVolumeWithIdAndZ& volume : to_render) {
|
for (GLVolumeWithIdAndZ& volume : to_render) {
|
||||||
volume.first->render_non_manifold_edges();
|
volume.first->render_non_manifold_edges();
|
||||||
}
|
}
|
||||||
|