chiark / gitweb /
Add an option to print the perimeter before/after infill
authorYouness Alaoui <kakaroto@kakaroto.homelinux.net>
Thu, 28 May 2015 18:36:11 +0000 (14:36 -0400)
committerYouness Alaoui <kakaroto@kakaroto.homelinux.net>
Thu, 28 May 2015 18:36:11 +0000 (14:36 -0400)
Cura/util/profile.py
Cura/util/sliceEngine.py

index ef9d454b5ccbdf4cd9cd8d2eed74bf01c6cd5b7b..9466f1ee3e1f96d3823ea442ef9cdae071dfb7f5 100644 (file)
@@ -180,6 +180,7 @@ setting('wall_thickness',            0.8, float, 'basic',    _('Quality')).setRa
 setting('retraction_enable',        True, bool,  'basic',    _('Quality')).setExpertSubCategory(_('Retraction')).setLabel(_("Enable retraction"), _("Retract the filament when the nozzle is moving over a none-printed area. Details about the retraction can be configured in the advanced tab."))
 setting('solid_layer_thickness',     0.6, float, 'basic',    _('Fill')).setRange(0).setLabel(_("Bottom/Top thickness (mm)"), _("This controls the thickness of the bottom and top layers, the amount of solid layers put down is calculated by the layer thickness and this value.\nHaving this value a multiple of the layer thickness makes sense. And keep it near your wall thickness to make an evenly strong part."))
 setting('fill_density',               20, float, 'basic',    _('Fill')).setExpertSubCategory(_('Infill')).setRange(0, 100).setLabel(_("Fill Density (%)"), _("This controls how densely filled the insides of your print will be. For a solid part use 100%, for an empty part use 0%. A value around 20% is usually enough.\nThis will not affect the outside of the print and only adjusts how strong the part becomes."))
+setting('perimeter_before_infill',               True, bool, 'basic',    _('Fill')).setLabel(_("Perimeters before Infill"), _("This controls whether the perimeters should be printed before or after the infill. Printing the perimeter after the infill may improve the quality of prints with very low layer heights, while printing the perimeters before the infill will give better results for layer height above 0.1mm"))
 setting('nozzle_size',               0.4, float, 'advanced', _('Machine')).setRange(0.1,10).setLabel(_("Nozzle size (mm)"), _("The nozzle size is very important, this is used to calculate the line width of the infill, and used to calculate the amount of outside wall lines and thickness for the wall thickness you entered in the print settings."))
 setting('print_speed',                50, float, 'basic',    _('Speed and Temperature')).setRange(1).setLabel(_("Print speed (mm/s)"), _("Speed at which printing happens. A well adjusted 3D printer can reach high speeds. However, for high quality prints slower speeds are required. Printing speed depends on a lot of factors. You will be experimenting with optimal settings for this."))
 setting('print_temperature',         210, int,   'basic',    _('Speed and Temperature')).setRange(0,340).setLabel(_("Printing temperature (C)"), _("Temperature used for printing. Set at 0 to pre-heat yourself.\nFor PLA 205C is recommended.\nFor ABS and HIPS 240C is recommended."))
index ccf90a5143fea8dbe48bd8511c35576b9bcd3808..5d434cf8f9e7fc5ad9a48c3da2651f7fdb1d9294 100644 (file)
@@ -566,6 +566,10 @@ class Engine(object):
                        settings['upSkinCount'] = 10000
                else:
                        settings['sparseInfillLineDistance'] = int(100 * profile.calculateEdgeWidth() * 1000 / profile.getProfileSettingFloat('fill_density'))
+               if profile.getProfileSetting('perimeter_before_infill') == 'True':
+                       settings['perimeterBeforeInfill'] = 1
+               else:
+                       settings['perimeterBeforeInfill'] = 0
                if profile.getProfileSetting('platform_adhesion') == 'Brim':
                        settings['skirtDistance'] = 0
                        settings['skirtLineCount'] = int(profile.getProfileSettingFloat('brim_line_count'))