Commit e6861f78 authored by Lars Kruse's avatar Lars Kruse

for engrave: skip the top layer (no penetration, yet)

parent 3ccab5bf
...@@ -177,7 +177,7 @@ class ProcessStrategyEngraving(pycam.Plugins.PluginBase): ...@@ -177,7 +177,7 @@ class ProcessStrategyEngraving(pycam.Plugins.PluginBase):
step_width=(tool_radius / 4.0), step_width=(tool_radius / 4.0),
milling_style=process["parameters"]["milling_style"], milling_style=process["parameters"]["milling_style"],
pocketing_type=process["parameters"]["pocketing_type"], pocketing_type=process["parameters"]["pocketing_type"],
callback=progress.update) skip_first_layer=True, callback=progress.update)
progress.finish() progress.finish()
return path_generator, motion_grid return path_generator, motion_grid
...@@ -400,7 +400,7 @@ def _get_sorted_polygons(models, callback=None): ...@@ -400,7 +400,7 @@ def _get_sorted_polygons(models, callback=None):
def get_lines_grid(models, (low, high), layer_distance, line_distance=None, def get_lines_grid(models, (low, high), layer_distance, line_distance=None,
step_width=None, milling_style=MILLING_STYLE_CONVENTIONAL, step_width=None, milling_style=MILLING_STYLE_CONVENTIONAL,
start_position=START_Z, pocketing_type=POCKETING_TYPE_NONE, start_position=START_Z, pocketing_type=POCKETING_TYPE_NONE,
callback=None): skip_first_layer=False, callback=None):
# the lower limit is never below the model # the lower limit is never below the model
polygons = _get_sorted_polygons(models, callback=callback) polygons = _get_sorted_polygons(models, callback=callback)
if polygons: if polygons:
...@@ -433,6 +433,9 @@ def get_lines_grid(models, (low, high), layer_distance, line_distance=None, ...@@ -433,6 +433,9 @@ def get_lines_grid(models, (low, high), layer_distance, line_distance=None,
reverse=bool(start_position & START_Z)) reverse=bool(start_position & START_Z))
# turn the generator into a list - otherwise the slicing fails # turn the generator into a list - otherwise the slicing fails
layers = list(layers) layers = list(layers)
# engrave ignores the top layer
if skip_first_layer and (len(layers) > 1):
layers = layers[1:]
last_z = None last_z = None
if layers: if layers:
# the upper layers are used for PushCutter operations # the upper layers are used for PushCutter operations
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment