From a7a7df8ebdb47cc93f40e1af470eda2ab141277b Mon Sep 17 00:00:00 2001 From: daid Date: Sat, 17 May 2014 07:20:56 +0200 Subject: [PATCH] Add simplemode setting, which only follows the polygons with the center of the nozzle. Gives great control on what and how anything is printed, but removes a lot of features. --- Cura/util/gcodeInterpreter.py | 2 ++ Cura/util/profile.py | 7 ++++--- Cura/util/sliceEngine.py | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Cura/util/gcodeInterpreter.py b/Cura/util/gcodeInterpreter.py index e7407a92..b187ea31 100644 --- a/Cura/util/gcodeInterpreter.py +++ b/Cura/util/gcodeInterpreter.py @@ -20,6 +20,8 @@ def gcodePath(newType, pathType, layerThickness, startPoint): """ if layerThickness <= 0.0: layerThickness = 0.01 + if profile.getProfileSetting('spiralize') == 'True': + layerThickness = profile.getProfileSettingFloat('layer_height') return {'type': newType, 'pathType': pathType, 'layerThickness': layerThickness, diff --git a/Cura/util/profile.py b/Cura/util/profile.py index 1e689e01..328387e6 100644 --- a/Cura/util/profile.py +++ b/Cura/util/profile.py @@ -225,7 +225,8 @@ setting('support_angle', 60, float, 'expert', _('Support')).setRange(0,90).setLa setting('support_fill_rate', 15, int, 'expert', _('Support')).setRange(0,100).setLabel(_("Fill amount (%)"), _("Amount of infill structure in the support material, less material gives weaker support which is easier to remove. 15% seems to be a good average.")) setting('support_xy_distance', 0.7, float, 'expert', _('Support')).setRange(0,10).setLabel(_("Distance X/Y (mm)"), _("Distance of the support material from the print, in the X/Y directions.\n0.7mm gives a nice distance from the print so the support does not stick to the print.")) setting('support_z_distance', 0.15, float, 'expert', _('Support')).setRange(0,10).setLabel(_("Distance Z (mm)"), _("Distance from the top/bottom of the support to the print. A small gap here makes it easier to remove the support but makes the print a bit uglier.\n0.15mm gives a good seperation of the support material.")) -setting('spiralize', False, bool, 'expert', 'Spiralize').setLabel(_("Spiralize the outer contour"), _("Spiralize is smoothing out the Z move of the outer edge. This will create a steady Z increase over the whole print. This feature turns a solid object into a single walled print with a solid bottom.\nThis feature used to be called Joris in older versions.")) +setting('spiralize', False, bool, 'expert', 'Black Magic').setLabel(_("Spiralize the outer contour"), _("Spiralize is smoothing out the Z move of the outer edge. This will create a steady Z increase over the whole print. This feature turns a solid object into a single walled print with a solid bottom.\nThis feature used to be called Joris in older versions.")) +setting('simple_mode', False, bool, 'expert', 'Black Magic').setLabel(_("Only follow mesh surface"), _("Only follow the mesh surfaces of the 3D model, do not do anything else. No infill, no top/bottom, nothing.")) #setting('bridge_speed', 100, int, 'expert', 'Bridge').setRange(0,100).setLabel(_("Bridge speed (%)"), _("Speed at which layers with bridges are printed, compared to normal printing speed.")) setting('brim_line_count', 20, int, 'expert', _('Brim')).setRange(1,100).setLabel(_("Brim line amount"), _("The amount of lines used for a brim, more lines means a larger brim which sticks better, but this also makes your effective print area smaller.")) setting('raft_margin', 5.0, float, 'expert', _('Raft')).setRange(0).setLabel(_("Extra margin (mm)"), _("If the raft is enabled, this is the extra raft area around the object which is also rafted. Increasing this margin will create a stronger raft while using more material and leaving less area for your print.")) @@ -1020,7 +1021,7 @@ def calculateEdgeWidth(): wallThickness = getProfileSettingFloat('wall_thickness') nozzleSize = getProfileSettingFloat('nozzle_size') - if getProfileSetting('spiralize') == 'True': + if getProfileSetting('spiralize') == 'True' or getProfileSetting('simple_mode') == 'True': return wallThickness if wallThickness < 0.01: @@ -1045,7 +1046,7 @@ def calculateLineCount(): return 0 if wallThickness < nozzleSize: return 1 - if getProfileSetting('spiralize') == 'True': + if getProfileSetting('spiralize') == 'True' or getProfileSetting('simple_mode') == 'True': return 1 lineCount = int(wallThickness / (nozzleSize - 0.0001)) diff --git a/Cura/util/sliceEngine.py b/Cura/util/sliceEngine.py index 9b8956e5..baa4fd47 100644 --- a/Cura/util/sliceEngine.py +++ b/Cura/util/sliceEngine.py @@ -522,7 +522,7 @@ class Engine(object): settings['raftInterfaceThickness'] = int(profile.getProfileSettingFloat('raft_interface_thickness') * 1000) settings['raftInterfaceLinewidth'] = int(profile.getProfileSettingFloat('raft_interface_linewidth') * 1000) settings['raftInterfaceLineSpacing'] = int(profile.getProfileSettingFloat('raft_interface_linewidth') * 1000 * 2.0) - settings['raftAirGap'] = int(profile.getProfileSettingFloat('raft_airgap') * 1000) + settings['raftAirGapLayer0'] = int(profile.getProfileSettingFloat('raft_airgap') * 1000) settings['raftBaseSpeed'] = int(profile.getProfileSettingFloat('bottom_layer_speed')) settings['raftFanSpeed'] = 100 settings['raftSurfaceThickness'] = settings['raftInterfaceThickness'] -- 2.30.2